-
1. Re: Starting a stand alone java application in Jboss as7
wdfink Feb 29, 2012 2:17 AM (in response to sgandhi)You might have the idea to modify jboss scripts,
but I recommend to write a wrapper script that start your java application and the JBoss in that order you need.
-
2. Re: Starting a stand alone java application in Jboss as7
sgandhi Feb 29, 2012 7:11 PM (in response to wdfink)Hi Wolf ,
Thanks for the response...I tried writing a shell script (./myscript.sh) containg ./standalone.sh and my script for eg (./pms_start.sh) ,
./standalone.sh &
./pms_start.sh &
My pms_start.sh just has just this : "java com.XXX.XXX.sampleProg"
and when i start myscript.sh both the jboss server and my application (standalone application) starts in a different JVM....But I want my standalone application to start in the same JVM which JBOSS uses...Is there any entry in Jboss deployment descriptor which i can use to acheive this ?
My intention is to start a standalone program and not an web or enterprise application...My stand alone program will run until it is terminated...and Iam using Jboss as 7....
Any help would be greatly appreciated...
Thanks,
SG
-
3. Re: Starting a stand alone java application in Jboss as7
rs2715 Mar 1, 2012 1:49 AM (in response to sgandhi)Check standalone.conf
-
4. Re: Starting a stand alone java application in Jboss as7
wdfink Mar 1, 2012 1:51 AM (in response to sgandhi)No, you can't start a Java standalone application in the same VM as JBoss. JBoss is an application server. (i.e. no IO or GUI allowed)
You might redesingn your application and deploy it as a timer driven SLSB to do some jobs periodicaly.
-
5. Re: Starting a stand alone java application in Jboss as7
wdfink Mar 1, 2012 2:06 AM (in response to rs2715)Hi rs2715,
There is no way to start a standalone programm in the same JVM, Java contains no JVM start option to start two Main classes.
standalone.conf allow only to set some VM options, or start a new JVM.