• 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
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

Exception deploying datasource for Hibernate

 
Ranch Hand
Posts: 42
2
Mac Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The Wildfly 10 quickstart for hibernate5 throws an exception relating to the datasource. hibernate5 deploys, but an error message is displayed when the app tries to submit information to the database. I think it's related to the another app that I'm trying to build. I copied some of the information from from the quickstart hibernate5 to my application which is called WebApp. I see the string WebApp in the exception for the hibernate5 app. I commented out the datasource information from WebApp. Then I did a clean on the project and tried to run the app again, but I still have the same problem.

Then I tried another suggestion. I went into the standalone.xml filed and deleted the <deployment> tag as recommended here: http://stackoverflow.com/questions/28509729/wildfly-duplicateserviceexception

Does anyone know why this is happening, and how I can fix it? I'll include the pom file for both apps, and the standalone.xml just in case that's useful. Thanks.

console output when I run start hibernate5



hibernate5-quickstart-ds.xml


hibernate-ds.xml this is the file I use in WebApp


hibernate5 pom


WebApp pom


standalone.xml
 
Brian Jones Jr.
Ranch Hand
Posts: 42
2
Mac Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I deleted WebApp, and it still doesn't work. The exception looks a little different. Now it's throwing a org.jboss.msc.service.DuplicateServiceException. There's no reference to WebApp anymore in the stacktrace. I'm posting the new stack trace and the persistence.xml for the hibernate5 app. I think it might be related to the persistence.xml and the datasource file now.

I was rereading the comments in the *-ds.xml file, and it say's that the file has been deprecated in wildfly.
 
Brian Jones Jr.
Ranch Hand
Posts: 42
2
Mac Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I deleted WebApp, and it still doesn't work. The exception looks a little different. Now it's throwing a org.jboss.msc.service.DuplicateServiceException. There's no reference to WebApp anymore in the stacktrace. I'm posting the new stack trace and the persistence.xml for the hibernate5 app. I think it might be related to the persistence.xml and the datasource file now.

I was rereading the comments in the wildfly logs, and it said that the *-ds.xml file are deprecated. Here is the output from the wildfly logs. I'm am also getting the same results when I run a backup copy of the hibernate5 quickstart from the CLI. I replaced the standalone.xml with the original version.

 
Brian Jones Jr.
Ranch Hand
Posts: 42
2
Mac Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
persistence.xml

 
What's gotten into you? Could it be this tiny ad?
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic