tag:blogger.com,1999:blog-5839700538451430522.post9130738437618293685..comments2024-01-22T10:45:22.952-06:00Comments on Rick Wagner's Blog: Solve your Java runtime mysteries easily with BytemanRickhttp://www.blogger.com/profile/13428944430725185873noreply@blogger.comBlogger7125tag:blogger.com,1999:blog-5839700538451430522.post-53269602848715387992011-08-29T00:42:12.997-05:002011-08-29T00:42:12.997-05:00I think best part of it is you doesn't requir...I think best part of it is you doesn't require to alter your code. Byteman looks quite promising for <a href="http://javarevisited.blogspot.com/2011/07/java-debugging-tutorial-example-tips.html" rel="nofollow">java debugging</a>.enum in javahttp://javarevisited.blogspot.com/2011/08/enum-in-java-example-tutorial.htmlnoreply@blogger.comtag:blogger.com,1999:blog-5839700538451430522.post-88715306035978880712010-11-05T03:03:24.631-05:002010-11-05T03:03:24.631-05:00Well, you can use BTrace to break your app (intent...Well, you can use BTrace to break your app (intentionally or not) as well. Just run it in unsafe mode and knock yourself out :)Enthusiasthttps://www.blogger.com/profile/07800148689847158802noreply@blogger.comtag:blogger.com,1999:blog-5839700538451430522.post-74857314124292301472010-10-22T04:25:04.933-05:002010-10-22T04:25:04.933-05:00Byteman is not a 'lite' version of btrace....Byteman is not a 'lite' version of btrace. On the contrary, it can do everything btrace does and more. btrace code is essentially read only as it is provide to allow tracing of applications or JVM operation. Byteman supports injection of trace code too but it also allows you to call code with side effects. You can call any method which is in scope at the injection point and you can update state rather than just read it.<br /><br />This allows Byteman to 'break' code which is very useful for testing. For example, you can force a method to return early with a synthetic result or to throw a checked exception. This was the primary design goal of Byteman -- comparing it to btrace is rather inappropriate since it is a different tool for a different purpose.<br /><br />Also, the comment about btrace not using an agent is actually a misnomer. btrace has always used a javaagent just like byteman. You can explicitly install the btrace agent on the command line just like Byteman does. However, btrace also allows you to use the VirtualMachine class in the com.sun.tool.attach package to attach to a running JVM and install the agent dynamically. Byteman does not currently provide this option since it ties you down to the Sun/OpenJDK VM (note that Byteman also works on IBM's JDK).Andrew Dinnhttps://www.blogger.com/profile/05800566216491514191noreply@blogger.comtag:blogger.com,1999:blog-5839700538451430522.post-17268998637452825882010-10-13T05:48:36.089-05:002010-10-13T05:48:36.089-05:00Sounds like a lite version of Btrace.
VisualVM wi...Sounds like a lite version of Btrace.<br /><br />VisualVM with the Btrace plugin (that lets you edit the script right there) is quite a valuable tool.<br /><br />And, of course, if it's Java6 you don't need an agent.Emilian Boldhttps://www.blogger.com/profile/10960978131273810766noreply@blogger.comtag:blogger.com,1999:blog-5839700538451430522.post-43934709584621352072010-10-11T21:40:49.648-05:002010-10-11T21:40:49.648-05:00Thanks for sharing information about Byteman using...Thanks for sharing information about Byteman using awesome real world story telling mechanism. Cool. Use of murder OO code is perfect. Ofcourse the sample text script for ByteMan is so neat to explain end to end flow and steps to incorporate it into real world scenario. <br /><br />Also both the comments added here responding to your blog post are supplying good information of two tools. RHQ GUI and BTrace.Phoenix2lifehttp://Phoenix2life.blogspot.comnoreply@blogger.comtag:blogger.com,1999:blog-5839700538451430522.post-34929761422588952442010-10-11T19:58:06.582-05:002010-10-11T19:58:06.582-05:00Byteman does sound interesting. I've done a b...Byteman does sound interesting. I've done a bit with a related tool named <a href="http://kenai.com/projects/btrace/pages/UserGuide" rel="nofollow">BTrace</a>. One really cool thing about BTrace is that you can use it in a limited way to trace a running app <i>without</i> starting a java agent.<br /><br />--MattAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-5839700538451430522.post-39272787866272090302010-10-11T07:35:19.157-05:002010-10-11T07:35:19.157-05:00Byteman is a great runtime debug/analysis tool tha...Byteman is a great runtime debug/analysis tool that is easy to set up and start up. This article is very good - short and sweet - illustrating how easy it is to use. (BTW: I like the suspect-murder theme :)<br /><br />I, myself, love Byteman so much I <a href="http://management-platform.blogspot.com/2010/01/byteman-plugin-revisited.html" rel="nofollow">wrote a blog</a> showing an RHQ plugin I developed that allows Byteman to be managed through the <a href="http://www.rhq-project.org" rel="nofollow">RHQ</a> GUI - you can upload rules to the Byteman agent, remove rules, etc.John Mazzhttps://www.blogger.com/profile/11415685873835789040noreply@blogger.com