Hi Georgi,

That's the way I started as well :) For me the debugger app was really more intuitive as well,

BTW another way to build in a place where you want is to use configure like this:

./configure --prefix=/home/user/yaws

The book is in front of me :). Sending messages to process and see
what they return on the spot
to any piece of code seems like a really cool thing, but for a newbie
like me following the whole
thing with a break point is a little more Eclipsish like for a start.
Even though it would
probably not last since messages are send asynchronously and many
things can be happening.
I guess if I get to the main control loop in the server I can see
that... anyway lots of things
to poke around with.

Thanks for the hand.
George


--steve

On Fri, Feb 17, 2012 at 3:13 PM, George
Stoianov<gstoyanoff@gmail.com> wrote:
On 02/17/2012 08:42 PM, Steve Vinoski wrote:

On Fri, Feb 17, 2012 at 1:52 PM, George Stoianov<gstoyanoff@gmail.com>
wrote:

Hi guys,

I just cloned the git repo and I am trying to run the websocket example
and I get this

=ERROR REPORT==== 17-Feb-2012::19:47:38 ===
Error in process<0.103.0> with exit value:
{undef,[{basic_echo_callback,handle_message,[{text,<<16
bytes>>}]},{lists,map,2},{yaws_websockets,loop,4}]}

Typically when you see an "undef" error like this, it means that the
module or function in question doesn't exist or hasn't been loaded.

If you're running yaws -i, try hitting enter and you should see an
Erlang shell prompt. At that prompt type

code:which(basic_echo_callback).

and hit enter. Make sure you include the period at the end. If that
module is available, it will tell you its file system pathname. But if
it's not found, you'll get the response non_existing.

It looks like the rebar build isn't compiling this module, which we'll
have to fix. If you want to compile it by hand, you can go into the
examples/src directory and type

erlc -I../../include -o ../../ebin *.erl

and get both modules built. Their compiled beam files will go into the
top-level ebin directory. Things should then work better.

--steve

Thanks Steve,

I noticed right after I send my email that ebin did not contain that
file so
I compiled it, moved it and restarted, bingo it works.
Could not figure out what I have to change to rebar.config to make it
compile the example.

Thanks for the prompt response and for working on Yaws. I am new at
Erlang,
but from all the things I have read I like it and yaws is really nice
for the moment I only serve small stuff like photos etc.. but I
would like
to learn more about how it works under the hood. Is there a way I can
specify a flag so all artifacts are build with debug_info and I can
look at
things with the debugger??

Thanks,
George

------------------------------------------------------------------------------

Virtualization& Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Erlyaws-list mailing list
Erlyaws-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/erlyaws-list




------------------------------

Message: 2
Date: Fri, 17 Feb 2012 22:35:47 +0100
From: George Stoianov <gstoyanoff@gmail.com>
Subject: Re: [Erlyaws-list] Problem running
websockets_example_endpoint.yaws
To: erlyaws-list@lists.sourceforge.net
Message-ID: <4F3EC833.9080209@gmail.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

On 02/17/2012 10:00 PM, Steve Vinoski wrote:
On Fri, Feb 17, 2012 at 3:56 PM, George Stoianov<gstoyanoff@gmail.com> wrote:
On 02/17/2012 09:42 PM, Steve Vinoski wrote:
Glad to hear it's working.

The easiest way to build everything with debug might be to use make,
since there you can just say

make debug

which basically adds -Ddebug +debug_info to the Erlang compiler (and
also builds the C code with -g). To be able to run make, you first
have to

autoconf
./configure
make debug
Is there a specific version of autoconf that is better suited to the yaws
autoconf scripts.
Here is my setup:

gs@flipper:~/git-repos/yaws$ autoconf
The program 'autoconf' can be found in the following packages:
* autoconf
* autoconf2.13
Ask your administrator to install one of them
gs@flipper:~/git-repos/yaws$ uname -a
Linux flipper 3.0.0-16-generic #28-Ubuntu SMP Fri Jan 27 17:44:39 UTC 2012
x86_64 x86_64 x86_64 GNU/Linux
Well, autoconf 2.13 is pretty old. I use 2.68, but there are even
newer ones out there. I think the minimum we can deal with is 2.61.

But if you just git pull again, pick up my new changes, and then you
can change no_debug_info to debug_info you should be all set. No need
for autoconf after all.

--steve

Yes I tried with autoconf, configure and make debug which works of
course the only problem is
things are target for places where I have no permissions to, and frankly
do not want to chase
around files outside of my home at this stage... so in this case your
rebar support for building
a local install for poking is perfect (maybe make local debug would have
worked??)

Thanks,
George


-------------------------------------
Mail.bg: Безплатен e-mail адрес. Най-добрите характеристики на българския пазар - 20 GB пощенска кутия, 1 GB прикрепен файл, безплатен POP3, мобилна версия, SMS известяване и други.
НОВИНИ ОТ RADAR.BG
ТЕХНОЛОГИИ» За последното тримесечие на 2011-та Amazon станаха втория по гол... АВТО» Ferrari с рекордни продажби през 2011. Показва нов "екстрем... ЛАЙФСТАЙЛ» Вихра за Иван: Иска да плаща минимална издръжка ЛЮБОПИТНО» Порно на живо влуди Щатите
17 February 2012г. 22:30 17 February 2012г. 21:30 18 February 2012г. 13:30 17 February 2012г. 21:30