[EJB 3.0] - Problem in injecting simple env entries in EJB
by plethora
Hi ,
I am trying to inject environment entries as below and I get the error "[ResourceHandler] Not injecting duration, no matching enc injector".
ejb-jar.xml
<ejb-name>TimerEjb</ejb-name>
gov.gsa.ejb.test.MyTimerBeanRemote
<ejb-class>gov.gsa.ejb.test.MyTimerBean</ejb-class>
<session-type>Stateless</session-type>
<env-entry>
Initial Duration
<env-entry-name>gov.gsa.ejb.test.MyTimerBean/duration</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>300000</env-entry-value>
<injection-target>
<injection-target-class>gov.gsa.ejb.test.MyTimerBean</injection-target-class>
<injection-target-name>duration</injection-target-name>
</injection-target>
</env-entry>
SESSION BEAN
============
public class MyTimerBean implements MyTimerBeanRemote{
private SessionContext context;
@Resource String duration ;
According to EJB3-CORE spec , the environment entry should get injected.
Appreciate your reply.
Thanks,
Plethora
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4191408#4191408
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4191408
17 years, 7 months
[Installation, Configuration & DEPLOYMENT] - java.lang.NoClassDefFoundError: net/sf/hibernate/HibernateEx
by ilangocal
Hi
I am trying to deploy an EAR file that has a Message Bean, a Stateless Session Bean and 3 servlets.
Any suggestions on why I am getting this error: Thanks in advance
14:57:49,441 INFO [SessionSpecContainer] Starting jboss.j2ee:ear=DexCenterQueueing2.ear,jar=DexCenterQueueing2-ejb.jar,name=QueueingEntityFacade,service=EJB3
14:57:49,451 INFO [EJBContainer] STARTED EJB: ejb.QueueingEntityFacade ejbName: QueueingEntityFacade
14:57:49,456 WARN [SessionSpecContainer] Populating JBoss-specific annotation metadata manually until done by deployers: jboss.j2ee:ear=DexCenterQueueing2.ear,jar=DexCenterQueueing2-ejb.jar,name=QueueingEntityFacade,service=EJB3
14:57:49,675 INFO [TomcatDeployment] deploy, ctxPath=/DexCenterQueueing2-war, vfsUrl=DexCenterQueueing2.ear/DexCenterQueueing2-war.war
14:57:50,019 ERROR [[/DexCenterQueueing2-war]] StandardWrapper.Throwable
java.lang.NoClassDefFoundError: net/sf/hibernate/HibernateException
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:169)
at au.edu.qut.yawl.engine.interfce.InterfaceB_EnvironmentBasedServer.init(InterfaceB_EnvironmentBasedServer.java:52)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1048)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:950)
at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4099)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4398)
at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:352)
at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:140)
at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:459)
at org.jboss.web.deployers.WebModule.startModule(WebModule.java:118)
at org.jboss.web.deployers.WebModule.start(WebModule.java:96)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:206)
at $Proxy35.start(Unknown Source)
at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:42)
at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:37)
at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:286)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1598)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1062)
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.ServiceController.doChange(ServiceController.java:672)
at org.jboss.system.ServiceController.start(ServiceController.java:444)
at org.jboss.system.deployers.ServiceDeployer.start(ServiceDeployer.java:146)
at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:104)
at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:45)
at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)
at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:169)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1285)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1003)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1024)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1056)
at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:944)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1598)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1062)
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:627)
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:541)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:290)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:221)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
at java.lang.Thread.run(Thread.java:619)
14:57:50,421 ERROR [[/DexCenterQueueing2-war]] Servlet /DexCenterQueueing2-war threw load() exception
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4191406#4191406
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4191406
17 years, 7 months
[JBoss jBPM] - Error Saving ProcessInstance using AssignmentHandler
by johnhurtchan
Hi,
My code does a token.signal(). Then saves does a successful JbpmContext.save(ProcessInstance).
But, when I add a AssignmentHandler for a Task in the Next Node, where I try to set the ActorID, I get a hibernate exception below...
object references an unsaved transient instance - save the transient instance before flushing: org.jbpm.graph.exe.Token
My code looks like this...
public class AssignmentHandler extends BaseHandler implements AssignmentHandler
| {
| public void assign(Assignable assignable, ExecutionContext executionContext)
| {
| ContextInstance contextInstance = (ContextInstance)(executionContext.getProcessInstance()).getContextInstance();
| TaskInstance task = executionContext.getTaskInstance();
| task.setActorId(123);
| }
| }
What do I need to do to fix it? I tried to modify that code above to try to save the TaskInstance that I modified the ActorID, but still get the same error...
public class AssignmentHandler extends BaseHandler implements AssignmentHandler
| {
| public void assign(Assignable assignable, ExecutionContext executionContext)
| {
| ContextInstance contextInstance = (ContextInstance)(executionContext.getProcessInstance()).getContextInstance();
| TaskInstance task = executionContext.getTaskInstance();
| JbpmContext jbpmContext = Config.jbpmConfiguration.createJbpmContext();
| TaskInstance myTask = jbpmContext.getTaskInstanceForUpdate(task.getId());
| myTask.setActorId(user.getName());
| jbpmContext.save(myTask);
| jbpmContext.close();
| }
| }
Help!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4191404#4191404
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4191404
17 years, 7 months
[Tomcat, HTTPD, Servlets & JSP] - httpd error : Failed opening socket to jboss server
by aarai
We have separate Apache and Jboss boxes. I keep getting the error below:
ajp_service::jk_ajp_common.c (1796): processing worker1 with 2 retries
[Fri Nov 21 13:04:40 2008][11877:5472] [debug] jk_open_socket::jk_connect.c (335): socket TCP_NODELAY set to On
[Fri Nov 21 13:04:40 2008][11877:5472] [debug] jk_open_socket::jk_connect.c (433): trying to connect socket 11 to 10.x.x.x.x:38009
[Fri Nov 21 13:04:40 2008][11877:5472] [info] jk_open_socket::jk_connect.c (451): connect to 10.x.x.x.x:38009 failed (errno=13)
[Fri Nov 21 13:04:40 2008][11877:5472] [info] ajp_connect_to_endpoint::jk_ajp_common.c (876): Failed opening socket to (10.x.x.x.x:38009) (errno=13)
[Fri Nov 21 13:04:40 2008][11877:5472] [info] ajp_send_request::jk_ajp_common.c (1273): (worker1) error connecting to the backend server (errno=13)
____________-
My worker.properties file is :
# Define list of workers that will be used
# for mapping requests
#worker.list=loadbalancer,status
worker.list=worker1
# Define Node1
# modify the host as your host IP or DNS name.
worker.worker1.port=38009
worker.worker1.host=10.x.x.x
worker.worker1.type=ajp13
#worker.node1.lbfactor=1
#worker.node1.cachesize=10
I have checked the port 38009 of jboss and it is running. I can even telnet from the apache server to the jboss server on port 38009
telnet 10.x.x.x 38009
Trying 10.x.x.x...
Connected to XXX.company.com (10.x.x.x).
Escape character is '^]'.
I apologize for double post, I think this is the right forum for this post, could admins please delete the post here:
http://www.jboss.com/index.html?module=bb&op=viewtopic&t=146094
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4191384#4191384
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4191384
17 years, 7 months