01-09-2013 08:31 AM
import javax.annotation.PostConstruct;
import javax.ejb.Singleton;
import javax.ejb.Startup;
import javax.inject.Inject;
import org.activiti.engine.IdentityService;
import org.activiti.engine.ProcessEngine;
import org.activiti.engine.identity.User;
import de.mettenmeier.util.DebugConsole;
@Startup
@Singleton
public class TestBean {
@Inject
private ProcessEngine processEngine;
@Inject
private IdentityService identityService;
@PostConstruct
protected void init() {
DebugConsole.out("This is the Engine with the name : "+ processEngine.getName(), 9);
DebugConsole.out(processEngine.VERSION, 9);
//IdentityService identityService = processEngine.getIdentityService();
User u = identityService.createUserQuery().userId("kermit")
.singleResult();
System.out.println(u.getId());
}
}
13:05:07,329 INFO [stdout] (MSC service thread 1-8) This is the Engine with the name : default
13:05:07,330 INFO [stdout] (MSC service thread 1-8) 5.9
13:05:07,354 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-8) MSC00001: Failed to start service jboss.deployment.unit."MBSActivitiProjekt.war".component.TestBean.START: org.jboss.msc.service.StartException in service jboss.deployment.unit."MBSActivitiProjekt.war".component.TestBean.START: Failed to start service
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1767) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [rt.jar:1.7.0_07]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [rt.jar:1.7.0_07]
at java.lang.Thread.run(Unknown Source) [rt.jar:1.7.0_07]
Caused by: java.lang.IllegalStateException: JBAS011048: Failed to construct component instance
at org.jboss.as.ee.component.BasicComponent.constructComponentInstance(BasicComponent.java:163)
at org.jboss.as.ee.component.BasicComponent.createInstance(BasicComponent.java:85)
at org.jboss.as.ejb3.component.singleton.SingletonComponent.getComponentInstance(SingletonComponent.java:116)
at org.jboss.as.ejb3.component.singleton.SingletonComponent.start(SingletonComponent.java:130)
at org.jboss.as.ee.component.ComponentStartService.start(ComponentStartService.java:44)
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]
… 3 more
Caused by: javax.ejb.EJBException: java.lang.NullPointerException
at org.jboss.as.ejb3.tx.CMTTxInterceptor.handleExceptionInOurTx(CMTTxInterceptor.java:166)
at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInOurTx(CMTTxInterceptor.java:230)
at org.jboss.as.ejb3.tx.CMTTxInterceptor.requiresNew(CMTTxInterceptor.java:333)
at org.jboss.as.ejb3.tx.SingletonLifecycleCMTTxInterceptor.processInvocation(SingletonLifecycleCMTTxInterceptor.java:56)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.CurrentInvocationContextInterceptor.processInvocation(CurrentInvocationContextInterceptor.java:41)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.TCCLInterceptor.processInvocation(TCCLInterceptor.java:45)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.BasicComponent.constructComponentInstance(BasicComponent.java:161)
… 9 more
Caused by: java.lang.NullPointerException
at TestBean.init(TestBean.java:31) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_07]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [rt.jar:1.7.0_07]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [rt.jar:1.7.0_07]
at java.lang.reflect.Method.invoke(Unknown Source) [rt.jar:1.7.0_07]
at org.jboss.as.ee.component.ManagedReferenceLifecycleMethodInterceptorFactory$ManagedReferenceLifecycleMethodInterceptor.processInvocation(ManagedReferenceLifecycleMethodInterceptorFactory.java:130)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.WeavedInterceptor.processInvocation(WeavedInterceptor.java:53) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.weld.injection.WeldInjectionInterceptor.processInvocation(WeldInjectionInterceptor.java:73)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.ManagedReferenceInterceptorFactory$ManagedReferenceInterceptor.processInvocation(ManagedReferenceInterceptorFactory.java:95)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.WeavedInterceptor.processInvocation(WeavedInterceptor.java:53) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.NamespaceContextInterceptor.processInvocation(NamespaceContextInterceptor.java:50)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInOurTx(CMTTxInterceptor.java:228)
… 18 more
13:05:07,572 INFO [org.jboss.as.server] (DeploymentScanner-threads - 2) JBAS015870: Deploy of deployment "MBSActivitiProjekt.war" was rolled back with failure message {"JBAS014671: Failed services" => {"jboss.deployment.unit.\"MBSActivitiProjekt.war\".component.TestBean.START" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"MBSActivitiProjekt.war\".component.TestBean.START: Failed to start service"}}
13:05:07,575 INFO [org.jboss.as.controller] (DeploymentScanner-threads - 2) JBAS014774: Service status report
JBAS014777: Services which failed to start: service jboss.deployment.unit."MBSActivitiProjekt.war".component.TestBean.START: org.jboss.msc.service.StartException in service jboss.deployment.unit."MBSActivitiProjekt.war".component.TestBean.START: Failed to start service
13:05:07,587 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) {"JBAS014653: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-2" => {"JBAS014671: Failed services" => {"jboss.deployment.unit.\"MBSActivitiProjekt.war\".component.TestBean.START" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"MBSActivitiProjekt.war\".component.TestBean.START: Failed to start service"}}}}
13:05:07,601 INFO [org.jboss.weld.deployer] (MSC service thread 1-1) JBAS016009: Stopping weld service for deployment MBSActivitiProjekt.war
13:05:07,603 INFO [org.activiti.engine.impl.jobexecutor.JobExecutor] (MSC service thread 1-1) Shutting down the JobExecutor[org.activiti.engine.impl.jobexecutor.DefaultJobExecutor].
13:05:07,604 INFO [org.activiti.engine.impl.jobexecutor.AcquireJobsRunnable] (Thread-70) JobExecutor[org.activiti.engine.impl.jobexecutor.DefaultJobExecutor] stopped job acquisition
13:05:07,605 INFO [org.activiti.cdi.impl.ActivitiExtension] (MSC service thread 1-1) Shutting down activiti-cdi
01-10-2013 03:02 AM
01-10-2013 04:53 AM
01-10-2013 04:55 AM
01-11-2013 02:28 AM
nearly the same.And the differences are?
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.