How To Remote debugging using JBuilder

Hi everyone,

I read on wm-advantage that you can connect your local EDI (JBuilder or eclipse) to the Integration Server using the remote debugger so that you can add breakpoints and stuff into your java code.

My first problem is that in order to setup this option you need to connect to the IS debug port. How do I setup this port or how can I find which is my debug port?

Is there anyone who already setup the JBuilder remote debugger to the IS, who is willing to help me and maybe has an installation manual he wants to share?

I also used following wmUsers post to help me: [url=“wmusers.com”]wmusers.com

I’m running IS 6.0.1 and JBuilder 8.0 Enterprise

Thanx a lot
Bart

The post you linked to contained the following:

Hi Mark,

Thanks for the quick answer.

But, I want to know how you can set that debug port yourself.
I have no idea of how to setup a debug port on the Integration Server or which number is my debug port, is there any way to find this out?
My admin port is 5635, so what is my debug port then?

I asked the guy who is in charge of the Integration server, and he never heard of a debug port.

Plus, I did everything that was in that post, but when restarting the IS, he says he’s missing the library “libjdwp.so”. Do you know how to solve this? Please note that I don’t have access to the \usr\j2se\jre\ directory.

Highest regards,
Bart

Bart,

The debug port is the port specified on the command line from Mark’s quote. In the example it is 8125; however you can specify any port number that isn’t already in use on your machine. You just need to remember the port number so that you can provide it within your IDE’s debugger.

It looks like you’re running a 1.2.x version of the VM (Solaris perhaps)? The JPDA libraries and jars are not included with these VMs. If so you can go to [url=“Oracle Java Technologies | Oracle”]Oracle Java Technologies | Oracle and get the libraries and jars.

Ed

Bart,

You add parameters to the Integration Server’s JVM by editing the server.bat or server.sh scripts found in the Integration Server\bin folder.

The changes shown in my quote above are for the server.bat file. If your are using Unix, you will need slightly different syntax to set or to use the environment variables JAVA_RUN, JAVA_EXE and JAVA_MEMSET. Your friendly Unix sysadmin can help if this is not something you are familiar with.

Mark

Hi Eduardo and Mark,

Indeed I am running solaris and your right again, these libraries and jars are not included in the VM’s. So thanks for the link I’ll try to install it.

I modified the server.sh like this (if I remember correctly):

JAVA_RUN=&{JAVA_EXE} -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,address=5636,suspend=n ${JAVA_MEMSET}

The last time I tried this, it wasn’t working because of the missing “libjdwp.so” library. So when I install the JPDA libraries and jars it should be working.

Sadly enough, I already lost too much time on this, so I don’t know when I will get this all working, but when it works I’ll be sure to post it here.

Thanx a lot for both your help
Bart

Hi All,
Iam using webMethods Integration server on Sun solaris
I’m running IS 6.0.1 and JBuilder 9.0 Enterprise

while using the said entries in server.sh file on solaris

JAVA_RUN=“${JAVA_DIR}/${JAVA_EXE} -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,address=8125,suspend=n ${JAVA_MEMSET}”

I am facing the problem as below,

While starting Integration server Iam getting this error in nohup.out…

“Error occurred during initialization of VM
Could not find -Xrun library: libjdwp.so”

Please help.
With Regards,
Vineet

Vineet,

What version VM are you using? This message is commonly seen when the debug libraries are not present for the VM. Old 1.2.x VMs have this issue, while the newer versions include the libraries by default.

Ed

Hi Eduardo,

Thanks for the reply.
We are using JDK1.3 and Iam also able to find libjdwp.so.

After including the said file in server.sh (CLASSPATH attribute) and starting the server , Iam now getting the following error.

“FATAL ERROR in native method: No transports initialized”

As stated above, Iam using the following entry in server.sh

JAVA_RUN="${JAVA_DIR}/${JAVA_EXE} -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,address=8125,suspend=n ${JAVA_MEMSET}

Please help,
Regards,
Vineet

Hi Eduardo,

In fact the complete error message was :

“Transport dt_socket failed to initialize, rc = 509.
FATAL ERROR in native method: No transports initialized”

Regards,
Vineet

I think it is because the runtime can’t find the JPDA libraries dt_shmem.dll or dt_socket.dll. Please check to be sure they are in a directory that is on your PATH.

Hi ALL,
I am able to resolve the problem with following entry in server.sh file.

JDPA_ARGS=-Xdebug
JDWP_ARGS=-Xrunjdwp:transport=dt_socket,server=y,address=9999,suspend=n

and then finally exporting both variables.

Thanks to all,
Vineet