[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

RubyJWDP was Re: FreeRide

Richard Kilmer

10/3/2003 3:51:00 AM


On Thursday, October 2, 2003, at 11:32 PM, Harry Ohlsen wrote:

> Richard Kilmer wrote:
>
>> I've gotten a bit distracted with a couple of Ruby projects ...
>> specifically implementing the Java Debug Wire Protocol in Ruby (
>> http://rubyforge.org/projects... cvs only right now)
>
> Interesting. What are your plans for this? Is the idea to be able to
> script execution of Java programs?
>

You will be able to script the debugging of Java programs. You can do
stuff like freeze the JVM, set breakpoints, walk variable values, set
them, resume the vm, etc...all from Ruby.

As an interesting test I froze all threads running on 60 JVMs (across
60 servers) in a multiagent system. It froze all 60 in under a second.
I then resumed all threads 10 minutes later and the system just went
along not knowing it had "lost time" so to speak.

Chad Fowler and I working on this...he is working on the higher level
API...I just implemented the low-level wire protocol. Its interesting
because I actually wrote a set of classes to be able to describe the
protocol (packets, data types, etc) then wrote a generator that uses
those metadata objects to generate the ruby implementation (complete
with rdoc!). The result is a 500 line generator (which is kinda hairy
code) that generates the low level packets which is over 5000 lines of
code.

-rich


1 Answer

Harry Ohlsen

10/3/2003 4:11:00 AM

0

Richard Kilmer wrote:

> You will be able to script the debugging of Java programs. You can do
> stuff like freeze the JVM, set breakpoints, walk variable values, set
> them, resume the vm, etc...all from Ruby.

Sounds pretty cool. I could see this being very handy for doing stress testing and for helping to track down horrible timing bugs.

> As an interesting test I froze all threads running on 60 JVMs (across 60
> servers) in a multiagent system. It froze all 60 in under a second. I
> then resumed all threads 10 minutes later and the system just went along
> not knowing it had "lost time" so to speak.

Cute.

> Chad Fowler and I working on this...he is working on the higher level
> API...I just implemented the low-level wire protocol. Its interesting
> because I actually wrote a set of classes to be able to describe the
> protocol (packets, data types, etc) then wrote a generator that uses
> those metadata objects to generate the ruby implementation (complete
> with rdoc!). The result is a 500 line generator (which is kinda hairy
> code) that generates the low level packets which is over 5000 lines of
> code.

Another chapter for "Code Generation in Action" :-).

It also sounds like another good way to ease Java people into playing with Ruby.

I look forward to seeing the first release.

H.