[GLASSFISH-15722] mq scripts to work on windows Created: 27/Jan/11  Updated: 02/Dec/11

Status: Reopened
Project: glassfish
Component/s: jms
Affects Version/s: 4.0
Fix Version/s: None

Type: Improvement Priority: Minor
Reporter: sonialiu Assignee: Jill Sato
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

windows



 Description   

I got the following error when running ha/mq test on windows (BTW, we are using cygwin on window to run HA test).

[testng] INFO: Command Executed at agent machine agent2: sh cygwin-wrapper C:/ha/glassfish3/mq/bin/imqdbmgr recreate tbl -Dimq.brokerid=stclusterinstance103 -Dimq.cluster.url=file:C:/ha/file_repository/mq-test-properties/cluster.properties
[testng] Output :
[testng] Jan 27, 2011 2:49:32 PM com.sun.dft.glassfish.utils.Utility logCommandOutput
[testng] SEVERE: C:/ha/glassfish3/mq/bin/../etc/imqenv.conf: line 41: $'\r': command not found
[testng] C:/ha/glassfish3/mq/bin/../etc/imqenv.conf: line 45: $'\r': command not found
[testng] C:/ha/glassfish3/mq/bin/../etc/imqenv.conf: line 49: $'\r': command not found
[testng] java.lang.NoClassDefFoundError: com/sun/messaging/jmq/jmsserver/persist/jdbc/DBTool
[testng] Caused by: java.lang.ClassNotFoundException: com.sun.messaging.jmq.jmsserver.persist.jdbc.DBTool
[testng] at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
[testng] at java.security.AccessController.doPrivileged(Native Method)
[testng] at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
[testng] at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
[testng] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
[testng] at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
[testng] Could not find the main class: com.sun.messaging.jmq.jmsserver.persist.jdbc.DBTool. Program will exit.
[testng] Exception in thread "main"

I checked the imqenv.conf, the line 41, 45, 49 which the error complained are blank lines. I checked with Amy, she thinks we should put "#" in front of those lines.



 Comments   
Comment by sonialiu [ 27/Jan/11 ]

All other mq commands like imqcmd, imqbrokerd... also failed with the similar error. This affected the ha/mq test run on windows. We have to have a fix for this.

Comment by Satish Kumar [ 27/Jan/11 ]

Requesting Amy to have a look at this issue...

Comment by amyk [ 28/Jan/11 ]

Sonia, it looks like you were using the script version of MQ commands which might be there for platform independent packaging. On Windows, please use the .exe version

reasign to Jill to decide if the script version of MQ commands on Windows should doc or change packaging

Comment by Jill Sato [ 28/Jan/11 ]

It is documented that on windows, you need to use the imq*.exe's. The scripts are for unix systems. Closing issue.

Comment by Jill Sato [ 28/Jan/11 ]

Not a bug.
Must uses mq*.exe exeutables on windows.

Comment by kumara [ 28/Jan/11 ]

Most of the other glassfish scripts work on both Windows (with MKS or Cygwin) and Unix. It is best to have consistent behavior in all scripts included with GlassFish. I would recommend reopening and converting this to an enhancement for the next release.

Comment by Jill Sato [ 28/Jan/11 ]

Snjezana said a couple of scripts works on windows, but not all.
We can try to convert mq scripts to work on windows. Will reopen for next release.
Strange that it would require a shell on win.

Comment by Jill Sato [ 28/Jan/11 ]

reopen for next release

Comment by Snjezana Sevo-Zenzerovic [ 28/Jan/11 ]

See issue GLASSFISH-6974 for more information on the overall Cygwin support status of GlassFish scripts.





Generated at Tue Mar 31 12:08:43 UTC 2015 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.