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

Wildfly EAR application deploy on startup problem

 
Ranch Hand
Posts: 82
Netbeans IDE Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi to all.

I have an EAR with a lot of modules and library in it.


I use wildfly 8.1.0 and eclipselink 2.5.2 as persistence provider.

Suppose i have wildfly started, then i open the console and deploy the EAR: ok!

I can access web pages, do login with JAAS , read data from DB with EJB+JPA.

Shutdown wildfly and restart it...
2015-09-16 12:40:22,913 INFO [org.jboss.as] (MSC service thread 1-5) JBAS015899: WildFly 8.1.0.Final "Kenny" starting
The server start to autodeploy my EAR
2015-09-16 12:40:25,134 INFO [org.jboss.as.server.deployment] (MSC service thread 1-15) JBAS015876: Starting deployment of "BssWebCore_ear-1.0-SNAPSHOT.ear" (runtime-name: "BssWebCore_ear-1.0-SNAPSHOT.ear")
then it deploies persistence unit, EJB and a soap web service... all ok
After that, it starts javax.ws.rs.core.Application for REST web service and I get the following error:

In my javax.ws.rs.core.Application i read the jndi to start as REST resource from a DB using an EJB.

If i disabled the EAR and re-enable it, all work fine!

Tested also on wildfly 8.2.0.Final with same results

What can be the problem?
 
Sheriff
Posts: 22783
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

There's the root of your problem. Is this EntityBase your own class? Does it have a void _persistence_set(String, Object) method?
 
daniele licitra
Ranch Hand
Posts: 82
Netbeans IDE Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Rob Spoor wrote:There's the root of your problem. Is this EntityBase your own class? Does it have a void _persistence_set(String, Object) method?



This method not exists.
EntityBase is a MappedSuperclass that it's used by other entity. The weaver add this method at runtime.
If i deploy the EAR in a running wildfly environment, the application works fine, no problem.
The problem occurs only if the application is deployed automatically at Wildfly's startup

Another hint:
during startup this message appear:
[org.jboss.as.server.deployment] JBAS015960: Class Path entry webservices-extra.jar in webservices-rt-2.3.jar does not point to a valid jar for a Class-Path reference.

If i remove from EAR the module BssStdODan_wss-1.0-SNAPSHOT.jar that contains web services and include webservices-rt-2.3.jar as dependencies, all work good.

Maybe the problem is in webservices-rt-2.3.jar? Or in eclipselink weaving?
 
daniele licitra
Ranch Hand
Posts: 82
Netbeans IDE Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Removing all dependencies to webservices-rt-2.3.jar, the problem persist.

So, does the problem may be in eclipselink weaving?
 
Rob Spoor
Sheriff
Posts: 22783
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Possibly.

Is there a reason you chose EclipseLink instead of Hibernate? The latter is the out-of-the-box JPA implementation of JBoss/WildFly, and can be included as a provided dependency in Maven because you can use the JBoss/WildFly version.
reply
    Bookmark Topic Watch Topic
  • New Topic