[jboss-user] [EJB3] - Exposing an EJB through multiple views

Lars Åslin do-not-reply at jboss.com
Fri Sep 7 14:16:42 EDT 2012


Lars Åslin [https://community.jboss.org/people/aslin] created the discussion

"Exposing an EJB through multiple views"

To view the discussion, visit: https://community.jboss.org/message/758605#758605

--------------------------------------------------------------
Hi,

I'm trying to expose an EJB through both a local business interface and a JAX-RS interface, but are getting the following error:

ERROR [org.jboss.msc.service.fail] (MSC service thread 1-7) MSC00001: Failed to start service jboss.deployment.unit."finance.war".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.unit."finance.war".PARSE: Failed to process phase PARSE of deployment "finance.war"
          at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:119) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
          at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
          at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.6.0_24]
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.6.0_24]
          at java.lang.Thread.run(Thread.java:679) [rt.jar:1.6.0_24]
Caused by: java.lang.IllegalArgumentException: JBAS011046: A component named 'FileServiceImpl' is already defined in this module
          at org.jboss.as.ee.component.EEModuleDescription.addComponent(EEModuleDescription.java:137)
          at org.jboss.as.ejb3.deployment.processors.EJBComponentDescriptionFactory.addComponent(EJBComponentDescriptionFactory.java:60)
          at org.jboss.as.ejb3.deployment.processors.SessionBeanComponentDescriptionFactory.processSessionBeans(SessionBeanComponentDescriptionFactory.java:157)
          at org.jboss.as.ejb3.deployment.processors.SessionBeanComponentDescriptionFactory.processAnnotations(SessionBeanComponentDescriptionFactory.java:86)
          at org.jboss.as.ejb3.deployment.processors.AnnotatedEJBComponentDescriptionDeploymentUnitProcessor.processAnnotations(AnnotatedEJBComponentDescriptionDeploymentUnitProcessor.java:58)
          at org.jboss.as.ejb3.deployment.processors.AbstractDeploymentUnitProcessor.deploy(AbstractDeploymentUnitProcessor.java:81)
          at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:113) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
          ... 5 more


<code>
public interface FileService {
     ...
}

public interface FileServiceLocalBusiness extends FileService {
     ...
}

@Path("file")
@Consumes({ "application/json" })
@Produces({ "application/json" })
public interface FileServiceWs extends FileService {
     ...
}
</code>
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/758605#758605]

Start a new discussion in EJB3 at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2029]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120907/da8959b3/attachment.html 


More information about the jboss-user mailing list