Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

How to use MySQL for JMS

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
I am using Jboss 4.2.3, I replaces the hsqldb-jdbc-state-service.xml with mysql-jdbc-state-service.xml and hsqldb-jdbc2-service.xml with mysql-jdbc2-service.xml.
I changed the data source to point to the datasource created for my jms messages.

However when I try to start my server, it fails to deploy the MDBs and fails with error 'Could not find the queue destination-jndi-name' and then 'javax.management.InstanceAlreadyExistsException'.

Am I doing it write or is there more to it than meets the eye?

Thanks
 
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I changed the data source to point to the datasource created for my jms messages.



I assume that this means that you created a mysql-ds.xml file which you properly configured for your database, and you modified the two ,ysql-*-service.xml files toe reference the datasource JNDI name mentioned in mysql-ds.xml. As long as you caught every occurrence of "MySqlDS" in the mysql-*-service.xml files then you should be OK.

It would help if you posted the full exception stack traces (actually, only the first one is necessary). The error names or text is usually meaningless.
 
Muddassar Shaikh
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, I create a mysql-ds.xml file and my modified my two*service.xml files to have this



where jmsDataSource is the name of my datasource in the mysql-ds.xml file.

I've attached the stack trace with this message.


Thanks for your reply,
><uddassar>
 
Peter Johnson
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This is a DEBUG log entry. It is possible that it means nothing. This entry appears to be related to downgradeservices_dev.ear. Please try running JBoss AS without that EAR deployed. If it starts up fine, and the JMS-related tables show up in the database (I think that the users table will have some entries), then you have set up MySQL and JMS properly.
 
Muddassar Shaikh
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I removed all EARs from the deploy directory and started the AS again. The tables were not created in my JMS schema. The option to create tables on startup is true in my *service.xml in jms directory.
 
Peter Johnson
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sounds like JMS is not using your database.

Please post the full console output, starting with the command you entered, for when you start JBoss AS with your JMS changes and the mysql-ds.xml file, but without your application being deployed.
 
Muddassar Shaikh
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Got it to work last month but forgot to update the forum. It was a human error in using the jndi name in the mysql-* files.
 
Farmers know to never drive a tractor near a honey locust tree. But a tiny ad is okay:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic