Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Two Java VMs running

  • 04-06-2005 6:26pm
    #1
    Registered Users, Registered Users 2 Posts: 6,315 ✭✭✭


    I think I have two JVMs running on my laptop. I have two Java.exe files in my process list. Could this be why my laptop is running so slow?

    Also what's the deal with this?
    Exception in thread "main" java.lang.NoClassDefFoundError: javax/comm/CommPortId
    entifier
            at sms.SMSAgent.open(SMSAgent.java:48)
            at sms.SMSAgent.<init>(SMSAgent.java:34)
            at sms.Main.<init>(Main.java:32)
            at sms.Main.main(Main.java:52)
    


Comments

  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    Right now, yes, each seperate Java application will open a new JRE instance to run. The entire JRE. Thankfully, some bods at SUn have seen the folly in this, and are currently working on whats called "Barcelona"; basically a linking and sharing architecture to allow different apps run in the same VM.

    As for the error, it looks like the javax.comm.CommPortIdentifier class is missing, or not included in the CLASSPATH.


  • Registered Users, Registered Users 2 Posts: 6,315 ✭✭✭ballooba


    Cheers Aidan,

    That error doesn't come up when I run it in NetBeans.

    This is the first time I have ever tired to run a JAR I have made from the command line.

    I just ran what was in the dist folder. Am I missing something?


  • Registered Users, Registered Users 2 Posts: 6,315 ✭✭✭ballooba


    I'm running it like this btw:
    java -jar JamboIn.jar


  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    Find where the javax.comm package is ([location]), and run it as

    java -jar -cp .:[location] JamboIn.jar


  • Registered Users, Registered Users 2 Posts: 6,315 ✭✭✭ballooba


    The javax.com also has a DLL attached to it and a javax.properties file.

    These are in the bin folder. Does this matter?

    The above did not work anyway.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 6,315 ✭✭✭ballooba


    Just to let you know i found a solution to this.

    For executable jars the classpath is ignored. They are "closed" units.

    Had to drop the -jar switch and use:

    java -cp .;C:\j2ee\environment\j2sdk1.4.2_05\jre\lib\comm.jar;JamboIn.jar sms.Main


  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    Hmm. I didn't know that. Thanks for the tip. Sorry I wasn't more help.


  • Registered Users, Registered Users 2 Posts: 6,315 ✭✭✭ballooba


    Thanks for trying to help anyway. Much appreciated.


Advertisement