I have followed instructions from 'Mega Creating mega Plugins with java'.pdf but I am not able to debug.
I am attempting to setup my workspace for debugging. I have setup my debugging options in Mega, and use the same port in Eclipse to debug. As shown in my image, the remote VM>connection is refused.
Solved! Go to Solution.
This error is not specific to the MEGA software.
It is related to the communication between MEGA Desktop and Eclipse on this machine --> network or configuration issue.
I let you check the various forums available on the subject.
After performing netsta /a, I see that Mega is not listening on the port - looks like the JVM is not even started inside Mega. I tried another port - but its the same!
I changed it back to 1044 - but i still dont see it listed under ports that are being listened to - I can find out all ports that are being listened to by doing a netstat /a
Sorry, I hadn't got the whole problem. The thing is that you're using Eclipse on your computer and you want it to use the debug with MEGA which is installed on the VM, right ?
If so, it's an unusual configuration. We usally install Eclipse and MEGA on the same so we can use the debug easilly. I must admit that don't know if you can use the debug in your configuration.
I hope someone can help you with it, but I can't. Sorry !
Good luck with this.
So if you set it like on the following picture, with 1044 as address in Debugging option :
Then in Eclipse > Debug > Debug Configurations > Remotable Java Application > New
You create your new configuration for debugging, linked to your Java plugin. In the settings of this configuraton, you set 1044 as the port, and it should work.
Then, when you want to use the debug, you must have Java running in MEGA (it's not by default).
I hope it helps.
You say I shld have Java running in mega - how do I do that? If its just the first check box from below image (Java Debugging option), I have it running!
Or is there something else I need to do? I am thinking that Mega JVM needs to be started, but how do I achieve that?
Thanks again for all the help! I totally kudo and apprciate it!
As a new intern, I'm not sure to know the official way to start the JVM, but I know one that works perfectly.
In MEGA :
File > Export > XPDL ( last option ). Then, there's a window appearing, but you can cancel it, because this option starts the JVM, and that just what you need.
It's a strange way to start it, but it works and for the moment I don't know another one.
No problem about the help, that's the purpose of this forum 😉