[JBoss Web Development] - i encountered an issue when i trying to start up jboss, can someone help me?
by champin hwang
champin hwang [https://community.jboss.org/people/champin0904] created the discussion
"i encountered an issue when i trying to start up jboss, can someone help me?"
To view the discussion, visit: https://community.jboss.org/message/646613#646613
--------------------------------------------------------------
14:39:39,234 ERROR [AbstractKernelController] Error installing to Real: name=vfsfile:/D:/PCE_Dev/Project/Runtime/jboss51/server/PCE/deploy/jca-jboss-beans.xml state=PreReal mode=Manual requiredState=Real
org.jboss.deployers.spi.DeploymentException: Error deploying: vfsfile:/D:/PCE_Dev/Project/Runtime/jboss51/server/PCE/deploy/jca-jboss-beans.xml
at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataFactoryVisitor.deploy(BeanMetaDataFactoryVisitor.java:136)
at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployerWithInput.deploy(AbstractRealDeployerWithInput.java:125)
at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployerWithInput.internalDeploy(AbstractRealDeployerWithInput.java:102)
at org.jboss.deployers.spi.deployer.helpers.AbstractComponentDeployer.internalDeploy(AbstractComponentDeployer.java:78)
at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)
at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:171)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1439)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1157)
at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1098)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:781)
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:702)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
at org.jboss.system.server.profileservice.repository.ProfileDeployAction.install(ProfileDeployAction.java:70)
at org.jboss.system.server.profileservice.repository.AbstractProfileAction.install(AbstractProfileAction.java:53)
at org.jboss.system.server.profileservice.repository.AbstractProfileService.install(AbstractProfileService.java:361)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
at org.jboss.system.server.profileservice.repository.AbstractProfileService.activateProfile(AbstractProfileService.java:306)
at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:271)
at org.jboss.bootstrap.AbstractServerImpl.start(AbstractServerImpl.java:461)
at org.jboss.Main.boot(Main.java:221)
at org.jboss.Main$1.run(Main.java:556)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.IllegalArgumentException: Exception loading class for ScopeKey addition.
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataFactoryVisitor.addBeanComponent(BeanMetaDataFactoryVisitor.java:67)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataFactoryVisitor.deploy(BeanMetaDataFactoryVisitor.java:126)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.jboss.resource.work.JBossWorkManager from BaseClassLoader@8c7c7f{VFSClassLoaderPolicy@141ab78{name=vfsfile:/D:/PCE_Dev/Project/Runtime/jboss51/server/PCE/deploy/jca-jboss-beans.xml domain=ClassLoaderDomain@278e83{name=DefaultDomain parentPolicy=BEFORE parent=org.jboss.bootstrap.NoAnnotationURLClassLoader@cd2c3c} roots=[MemoryContextHandler@6325283[path= context=vfsmemory://4sh1w1y-uscbyo-gxcu36y3-1-gxcu60ui-1q real=vfsmemory://4sh1w1y-uscbyo-gxcu36y3-1-gxcu60ui-1q]] delegates=null exported=[] <IMPORT-ALL>NON_EMPTY}}
at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataFactoryVisitor.addBeanComponent(BeanMetaDataFactoryVisitor.java:63)
... 35 more
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/646613#646613]
Start a new discussion in JBoss Web Development at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 1 month
[JBoss AS 7 Development] - Logging with slf4j in 7.1.0.Final
by Dan D
Dan D [https://community.jboss.org/people/norad_2] created the discussion
"Logging with slf4j in 7.1.0.Final"
To view the discussion, visit: https://community.jboss.org/message/718928#718928
--------------------------------------------------------------
Hi All,
In 7.1.0.CR1b I could include my own slf4j-api/slf4j12 and log4j.xml and have my application not use the JBoss logging modules.
I did this for the following reasons:
1. JBoss logging seems to be based on java.util.logging, which has no support for Message Diagnostic Context, which I use heavily
2. JBoss logging currently has no support for JMS Appenders like org.apache.log4j.net.JMSAppender
Based on what I see in this JIRA, and what I am seeing since I upgraded from CR1b to Final, it seems like JBoss logging has been forced onto us.
https://issues.jboss.org/browse/AS7-1389 https://issues.jboss.org/browse/AS7-1389
"Log API dependencies should be included automatically in deployments"
The JIRA mentions being able to exclude the logging dependencies if I want to bring in my own.
I created a jboss-deployment-structure file
Now when I try to startup JBoss, I get warnings and errors and JBoss does not startup
00:30:07,297 WARN org.jboss.modules org.jboss.modules https://community.jboss.org/message/718928#718928#718928/MSC service thread 1-3 Logging with slf4j in 7.1.0.Final Failed to define class org.slf4j.Logger in Module "deployment.project.ear:main" from Service Module Loader: java.lang.LinkageError: loader constraint violation: loader (instance of org/jboss/modules/ModuleClassLoader) previously initiated loading for a different type with name "org/slf4j/Logger"
00:30:07,308 ERROR org.jboss.msc.service.fail org.jboss.msc.service.fail https://community.jboss.org/message/718928#718928#718928/MSC service thread 1-3 Logging with slf4j in 7.1.0.Final MSC00001: Failed to start service jboss.deployment.subunit."project.ear"."project-services.jar".POST_MODULE: org.jboss.msc.service.StartException in service jboss.deployment.subunit."project.ear"."project-services.jar".POST_MODULE: Failed to process phase POST_MODULE of subdeployment "project-services.jar" of deployment "project.ear"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:119) jboss-as-server-7.1.0.Final.jar:7.1.0.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$Worker.runTask(ThreadPoolExecutor.java:886) https://community.jboss.org/message/718928#718928#718928/rt.jar:1.6.0_29 Logging with slf4j in 7.1.0.Final
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) https://community.jboss.org/message/718928#718928#718928/rt.jar:1.6.0_29 Logging with slf4j in 7.1.0.Final
at java.lang.Thread.run(Thread.java:662) https://community.jboss.org/message/718928#718928#718928/rt.jar:1.6.0_29 Logging with slf4j in 7.1.0.Final
Caused by: java.lang.RuntimeException: Error getting reflective information for class com.example.project.package.api.remote.AbstractServiceLocator with ClassLoader ModuleClassLoader for Module "deployment.project.ear:main" from Service Module Loader
at org.jboss.as.server.deployment.reflect.DeploymentReflectionIndex.getClassIndex(DeploymentReflectionIndex.java:70) jboss-as-server-7.1.0.Final.jar:7.1.0.Final
at org.jboss.as.ee.metadata.MethodAnnotationAggregator.runtimeAnnotationInformation(MethodAnnotationAggregator.java:58)
at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.handleAnnotations(InterceptorAnnotationProcessor.java:70)
at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.processComponentConfig(InterceptorAnnotationProcessor.java:117)
at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.deploy(InterceptorAnnotationProcessor.java:54)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:113) jboss-as-server-7.1.0.Final.jar:7.1.0.Final
... 5 more
Caused by: java.lang.NoClassDefFoundError: org/slf4j/Logger
at java.lang.Class.getDeclaredMethods0(Native Method) https://community.jboss.org/message/718928#718928#718928/rt.jar:1.6.0_29 Logging with slf4j in 7.1.0.Final
at java.lang.Class.privateGetDeclaredMethods(Class.java:2427) https://community.jboss.org/message/718928#718928#718928/rt.jar:1.6.0_29 Logging with slf4j in 7.1.0.Final
at java.lang.Class.getDeclaredMethods(Class.java:1791) https://community.jboss.org/message/718928#718928#718928/rt.jar:1.6.0_29 Logging with slf4j in 7.1.0.Final
at org.jboss.as.server.deployment.reflect.ClassReflectionIndex.(ClassReflectionIndex.java:65) jboss-as-server-7.1.0.Final.jar:7.1.0.Final
at org.jboss.as.server.deployment.reflect.DeploymentReflectionIndex.getClassIndex(DeploymentReflectionIndex.java:66) jboss-as-server-7.1.0.Final.jar:7.1.0.Final
... 10 more
Caused by: java.lang.ClassNotFoundException: org.slf4j.Logger from [Module "deployment.project.ear:main" from Service Module Loader]
at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:423)
at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
... 15 more
I have the necessary slf4j jars included in my ear, and this is all working fine in CR1b.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/718928#718928]
Start a new discussion in JBoss AS 7 Development at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 1 month
[JBoss AS 7 Development] - Does JBoss AS7 support runtime annotation processing for Metamodel using javax.persistence.metamodel.EntityType?
by Veer Muchandi
Veer Muchandi [https://community.jboss.org/people/v_m] created the discussion
"Does JBoss AS7 support runtime annotation processing for Metamodel using javax.persistence.metamodel.EntityType?"
To view the discussion, visit: https://community.jboss.org/message/718919#718919
--------------------------------------------------------------
I am trying to use runtime annotation processing by using javax.persistence.metamodel.EntityType as given in the http://docs.oracle.com/javaee/6/tutorial/doc/gjiup.html http://docs.oracle.com/javaee/6/tutorial/doc/gjiup.html
h3. Using Metamodel Classes
Metamodel classes that correspond to entity classes are of the following type:
javax.persistence.metamodel.EntityType<T>
Metamodel classes are typically generated by annotation processors either at development time or at runtime. Developers of applications that use Criteria queries may generate static metamodel classes by using the persistence provider’s annotation processor or may obtain the metamodel class by either calling the getModel method on the query root object or first obtaining an instance of the Metamodel interface and then passing the entity type to the instance’s entity method.
The following code snippet shows how to obtain the Pet entity’s metamodel class by calling Root<T>.getModel:
EntityManager em = ...; CriteriaBuilder cb = em.getCriteriaBuilder(); CriteriaQuery cq = cb.createQuery(Pet.class); Root<Pet> pet = cq.from(Pet.class); EntityType<Pet> Pet_ = pet.getModel();
The following code snippet shows how to obtain the Pet entity’s metamodel class by first obtaining a metamodel instance by using EntityManager.getMetamodel and then calling entity on the metamodel instance:
EntityManager em = ...; Metamodel m = em.getMetamodel(); EntityType<Pet> Pet_ = m.entity(Pet.class);
When I try to deploy this code into JBoss, there are no errors. But at run time I get the following errors. name, itemBrand, itemCategory and itemSubCategory below are the attributes of my entity (like the Pet class above).
org.jboss.resteasy.spi.UnhandledException: java.lang.Error: Unresolved compilation problems:
name cannot be resolved or is not a field
itemBrand cannot be resolved or is not a field
itemCategory cannot be resolved or is not a field
itemSubCategory cannot be resolved or is not a field
org.jboss.resteasy.core.SynchronousDispatcher.unwrapException(SynchronousDispatcher.java:345)
org.jboss.resteasy.core.SynchronousDispatcher.unwrapException(SynchronousDispatcher.java:341)
org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:321)
org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:214)
org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:190)
org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:534)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:496)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:119)
org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)
javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
org.jboss.weld.servlet.ConversationPropagationFilter.doFilter(ConversationPropagationFilter.java:67)
The jboss documentation does not talk about runtime metamodel generation. See the link here. http://docs.jboss.org/hibernate/jpamodelgen/1.0/reference/en-US/html_single/ http://docs.jboss.org/hibernate/jpamodelgen/1.0/reference/en-US/html_single/
Please help
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/718919#718919]
Start a new discussion in JBoss AS 7 Development at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 1 month
[JBoss Web Services Development] - HTTP Client Certificate authentication for JbossWS Native client
by spyhunter99
spyhunter99 [https://community.jboss.org/people/spyhunter99] created the discussion
"HTTP Client Certificate authentication for JbossWS Native client"
To view the discussion, visit: https://community.jboss.org/message/718868#718868
--------------------------------------------------------------
I have a situation in which my web service client (running in a jsp) needs to be able to dynamically change authentication parameters for accessing a partical service based off of some administrative settings. (I need help with B)
Scenario A: HTTP Basic username/password
Status: It works great, all I need to do is to pass along the username and password from the form login via the context provider object
Scenario B: Multihop with HTTPS with client certificates
User's Browser (with a user cert) to Jboss web client (in a jsp. server has it's own server cert) which then calls the web service, using the server cert as a client-cert.
Status: doesn't work and I'm not sure what I'm missing.
The overal goal is to provide some level of impresonation from the end user, through the web interface, to the web service. I'm doing this by passing along some custom headers (not that's beyond the point right now). So the question really is, what do I need to specify programmatically to setup the web service client in the jsp, in order to setup the SSL connection with client certs.
Ideally, I'd like to just steal the settings from the container, that way configuration is similified.
I've pretty sure I've done this in the past with a console app and jbossws. All I did was specificy the location of the key store via the environment properties (javax.net.ssl ...). Which leaves me a bit puzzled why it wouldn't be picked up from the stack.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/718868#718868]
Start a new discussion in JBoss Web Services Development at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 1 month
[JBoss AS 7 Development] - Problems deploying and starting webapp on JBoss AS 7.1.0.Final
by thomas3mt
thomas3mt [https://community.jboss.org/people/thomas3mt] created the discussion
"Problems deploying and starting webapp on JBoss AS 7.1.0.Final"
To view the discussion, visit: https://community.jboss.org/message/718760#718760
--------------------------------------------------------------
Hi,
I have problems deploying a webapp on 7.1.0.Final. The application deploys without any problems on 7.1.0.CR1
The app uses mysql + eclipselink. Those modules are installed and confirmed trough console / log loaded ok.
When i add the application to the server it deploys ok. When i try to add the app to server group it just handgs (in the web console).
>From command-line console i can see that the dependencies are sorted out, the perisistence unit is found, and that it looks "fine".
Last message i see is;
[Server:server-one] 16:07:59,233 DEBUG [org.jboss.as.ejb3.deployment.processors.EjbClientContextSetupProcessor] (MSC service thread 1-4) Deployment unit deployment "****.war" doesn't have any explicit EJB client context configured. Falling back on the default service jboss.ejb3.ejbClientContext.default EJB client context service
[Server:server-one] 16:07:59,235 DEBUG [org.jboss.as.ejb3.deployment.processors.EjbClientContextSetupProcessor] (MSC service thread 1-4) Registering EJB client context org.jboss.ejb.client.EJBClientContext@42b36022 for classloader ModuleClassLoader for Module "deployment.****.war:main" from Service Module Loader
[Server:server-one] 16:07:59,312 DEBUG [org.jboss.as.ee] (MSC service thread 1-3) Configuring component class: javax.servlet.jsp.jstl.tlv.PermittedTaglibsTLV named javax.servlet.jsp.jstl.tlv.PermittedTaglibsTLV
[Server:server-one] 16:07:59,426 DEBUG [org.jboss.as.ee] (MSC service thread 1-3) Configuring component class: org.apache.catalina.servlets.DefaultServlet named org.apache.catalina.servlets.DefaultServlet
[Server:server-one] 16:07:59,430 DEBUG [org.jboss.as.ee] (MSC service thread 1-3) Configuring component class: javax.faces.webapp.FacetTag named javax.faces.webapp.FacetTag
[Server:server-one] 16:07:59,433 DEBUG [org.jboss.as.ee] (MSC service thread 1-3) Configuring component class: com.sun.faces.config.ConfigureListener named com.sun.faces.config.ConfigureListener
[Server:server-one] 16:07:59,436 DEBUG [org.jboss.as.ee] (MSC service thread 1-3) Configuring component class: ***** named *****
[Server:server-one] 16:07:59,437 DEBUG [org.jboss.as.ee] (MSC service thread 1-3) Configuring component class: javax.servlet.jsp.jstl.tlv.ScriptFreeTLV named javax.servlet.jsp.jstl.tlv.ScriptFreeTLV
[Server:server-one] 16:07:59,440 DEBUG [org.jboss.as.ee] (MSC service thread 1-3) Configuring component class: org.apache.jasper.servlet.JspServlet named org.apache.jasper.servlet.JspServlet
(**** is anonymized webapp package)
When i press "ctrl-c" to break/quit the "./domain.sh" process it hangs for a very long time / i have to kill it forcefully.. It seems that "hornetq" is something that is waiting / hanging. But im not sure..
I really need some pinpoints on where to continue looking. Thanks.
br
Thomas
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/718760#718760]
Start a new discussion in JBoss AS 7 Development at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 1 month