[EJB/JBoss] - Re: Can someone look at this application? help understanding
by rickcr
"jaikiran" wrote : Which version of JBoss and Java do you use? Please post the entire exception stacktrace and the console logs when you deploy your application with the following annotation in the servlet:
|
| @EJB(mappedName="user-administration/UserServiceBean/local")
| | private UserService userService;
| |
|
That's the odd thing is that there really aren't any Exceptions other the null pointer that occurs because "userService" is never initialized. It's as if the annotation is being totally being ignored in the servlet, yet for the ejb jar obviously the annotations are picked up. I'm not convinced something isn't wrong with my set up though. Maybe someone could try the actual ear in their deployment? I put it out here.. http://dl-client.getdropbox.com/u/86998/user-administration.ear (after it deploys try http://localhost:8080/lt-web/hello )
Thanks for any help. I do appreciate it.
here is some server.log info, but not sure how helpful it will be...
JBoss: 5.0.0.CR2 (build: SVNTag=JBoss_5_0_0_CR2 date=200809171046)
java -version:
java version "1.5.0_16"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_16-b06-284)
Java HotSpot(TM) Client VM (build 1.5.0_16-133, mixed mode, sharing)
| JBoss Bootstrap Environment
|
| JBOSS_HOME: /Users/rick/java/jboss
|
| JAVA: /Users/rick/java/java/bin/java
|
| JAVA_OPTS: -Dprogram.name=run.sh -Xms128m -Xmx512m -XX:MaxPermSize=256m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000
|
| CLASSPATH: /Users/rick/java/jboss/bin/run.jar
|
| =========================================================================
|
| 10:03:55,325 INFO [ServerImpl] Starting JBoss (Microcontainer)...
| 10:03:55,326 INFO [ServerImpl] Release ID: JBoss [Morpheus] 5.0.0.CR2 (build: SVNTag=JBoss_5_0_0_CR2 date=200809171046)
| 10:03:55,332 INFO [ServerImpl] Home Dir: /Users/rick/java/jboss-5.0.0.CR2
| 10:03:55,332 INFO [ServerImpl] Home URL: file:/Users/rick/java/jboss-5.0.0.CR2/
| 10:03:55,332 INFO [ServerImpl] Library URL: file:/Users/rick/java/jboss-5.0.0.CR2/lib/
| 10:03:55,333 INFO [ServerImpl] Patch URL: null
| 10:03:55,333 INFO [ServerImpl] Server Name: default
| 10:03:55,333 INFO [ServerImpl] Server Home Dir: /Users/rick/java/jboss-5.0.0.CR2/server/default
| 10:03:55,333 INFO [ServerImpl] Server Home URL: file:/Users/rick/java/jboss-5.0.0.CR2/server/default/
| 10:03:55,333 INFO [ServerImpl] Server Data Dir: /Users/rick/java/jboss-5.0.0.CR2/server/default/data
| 10:03:55,333 INFO [ServerImpl] Server Temp Dir: /Users/rick/java/jboss-5.0.0.CR2/server/default/tmp
| 10:03:55,334 INFO [ServerImpl] Server Config URL: file:/Users/rick/java/jboss-5.0.0.CR2/server/default/conf/
| 10:03:55,334 INFO [ServerImpl] Server Library URL: file:/Users/rick/java/jboss-5.0.0.CR2/server/default/lib/
| 10:03:55,334 INFO [ServerImpl] Root Deployment Filename: jboss-service.xml
| 10:03:55,789 INFO [ServerImpl] Starting Microcontainer, bootstrapURL=file:/Users/rick/java/jboss-5.0.0.CR2/server/default/conf/bootstrap.xml
| 10:03:56,430 INFO [CopyMechanism] VFS temp dir: /Users/rick/java/jboss-5.0.0.CR2/server/default/tmp
| 10:03:56,431 INFO [ZipEntryContext] VFS force nested jars copy-mode is enabled.
| 10:03:57,418 INFO [ServerInfo] Java version: 1.5.0_16,Apple Inc.
| 10:03:57,419 INFO [ServerInfo] Java VM: Java HotSpot(TM) Client VM 1.5.0_16-133,Apple Inc.
| 10:03:57,419 INFO [ServerInfo] OS-System: Mac OS X 10.5.5,i386
| 10:03:57,443 INFO [JMXKernel] Legacy JMX core initialized
|
| //THE ERROR when going to the URL
|
| 2008-10-01 10:11:10,830 DEBUG [com.arjuna.ats.arjuna.logging.arjLogger] (Thread-12) Periodic recovery - second pass <Wed, 1 Oct 2008 10:11:10>
| 2008-10-01 10:11:10,830 DEBUG [com.arjuna.ats.arjuna.logging.arjLogger] (Thread-12) AtomicActionRecoveryModule: Second pass
| 2008-10-01 10:11:10,830 DEBUG [com.arjuna.ats.txoj.logging.txojLoggerI18N] (Thread-12) [com.arjuna.ats.internal.txoj.recovery.TORecoveryModule_6] - TORecoveryModule - second pass
| 2008-10-01 10:11:10,830 DEBUG [com.arjuna.ats.jta.logging.loggerI18N] (Thread-12) [com.arjuna.ats.internal.jta.recovery.info.secondpass] Local XARecoveryModule - second pass
| 2008-10-01 10:11:25,091 INFO [STDOUT] (http-127.0.0.1-8080-1) userService = null
| 2008-10-01 10:11:25,092 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/lt-web].[SayHelloServlet]] (http-127.0.0.1-8080-1) Servlet.service() for servlet SayHelloServlet threw exception
| java.lang.NullPointerException
| at net.learntechnology.web.SayHelloServlet.doPost(SayHelloServlet.java:38)
| at net.learntechnology.web.SayHelloServlet.doGet(SayHelloServlet.java:30)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:189)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:91)
| at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:92)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
| at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:325)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:828)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:601)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
| at java.lang.Thread.run(Thread.java:613)
| 2008-10-01 10:13:10,827 DEBUG [com.arjuna.ats.arjuna.logging.arjLogger] (Thread-12) Periodic recovery - first pass <Wed, 1 Oct 2008 10:13:10>
| 2008-10-01 10:13:10,827 DEBUG [com.arjuna.ats.arjuna.logging.arjLogger] (Thread-12) StatusModule: first pass
| 2008-10-01 10:13:10,827 DEBUG [com.arjuna.ats.txoj.logging.txojLoggerI18N] (Thread-12) [com.arjuna.ats.internal.txoj.recovery.TORecoveryModule_3] - TORecoveryModule - first pass
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4179832#4179832
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4179832
17 years, 7 months
[JBossWS] - Are ports reusable/concurrent?
by jorgemoralespou_2
Hi, I'm developing an application with JBossWS, and using it as server and as client, invoking some other webservices in other servers.
Doing tunning of my app, I have found that too much time is spent every time I invoke getPort on a service, as it seems that everytime is generating the port on the fly.
2008-10-01 15:46:18,103:org.jboss.ws.core.jaxws.spi.ServiceDelegateImplCannot get port meta data for: {http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/service}SendSms|
2008-10-01 15:46:18,103:org.jboss.ws.metadata.builder.jaxws.JAXWSWebServiceMetaDataBuilderSTART: rebuildMetaData|
2008-10-01 15:46:18,103:org.jboss.ws.metadata.umdm.EndpointMetaDatasetParameterStyle: null|
2008-10-01 15:46:18,103:org.jboss.ws.metadata.umdm.EndpointMetaDataCreate new config [name=Standard Client,file=META-INF/standard-jaxws-client-config.xml]|
2008-10-01 15:46:18,103:org.jboss.ws.metadata.config.JBossWSConfigFactorygetConfig: [name=Standard Client,url=META-INF/standard-jaxws-client-config.xml]|
2008-10-01 15:46:18,103:org.jboss.ws.metadata.config.JBossWSConfigFactoryparse: file:/C:/jboss-4.2.3/core/server/som/deploy/jbossws.sar/META-INF/standard-jaxws-client-config.xml|
2008-10-01 15:46:18,181:org.jboss.ws.metadata.umdm.EndpointConfigMetaDataConfigure EndpointMetaData|
2008-10-01 15:46:18,181:org.jboss.ws.metadata.umdm.EndpointConfigMetaDataAdded 0 PRE handlers|
2008-10-01 15:46:18,181:org.jboss.ws.metadata.umdm.EndpointConfigMetaDataAdded 0 ENDPOINT handlers|
2008-10-01 15:46:18,181:org.jboss.ws.metadata.umdm.EndpointConfigMetaDataAdded 0 POST handlers|
2008-10-01 15:46:18,181:org.jboss.ws.metadata.umdm.EndpointMetaDatasetParameterStyle: WRAPPED|
2008-10-01 15:46:18,181:org.jboss.ws.metadata.umdm.EndpointMetaDataUsing default style: document|
2008-10-01 15:46:18,213:org.jboss.ws.metadata.umdm.EndpointMetaDatasetParameterStyle: WRAPPED|
2008-10-01 15:46:18,228:org.jboss.ws.metadata.umdm.EndpointMetaDatasetParameterStyle: WRAPPED|
2008-10-01 15:46:18,228:org.jboss.ws.metadata.umdm.EndpointMetaDatasetParameterStyle: WRAPPED|
2008-10-01 15:46:18,244:org.jboss.ws.metadata.builder.jaxws.JAXWSWebServiceMetaDataBuilderJAXBContext [types=[class com.hp.som.ws.parlayx21.sms.send.SendSms_Type, class com.hp.som.ws.parlayx21.sms.send.SendSmsResponse, class com.hp.som.ws.parlayx21.common.PolicyExceptionInfo, class com.hp.som.ws.parlayx21.common.ServiceExceptionInfo, class com.hp.som.ws.parlayx21.sms.send.SendSmsRingtone, class com.hp.som.ws.parlayx21.sms.send.SendSmsRingtoneResponse, class com.hp.som.ws.parlayx21.common.PolicyExceptionInfo, class com.hp.som.ws.parlayx21.common.ServiceExceptionInfo, class com.hp.som.ws.parlayx21.sms.send.SendSmsLogo, class com.hp.som.ws.parlayx21.sms.send.SendSmsLogoResponse, class com.hp.som.ws.parlayx21.common.PolicyExceptionInfo, class com.hp.som.ws.parlayx21.common.ServiceExceptionInfo, class com.hp.som.ws.parlayx21.sms.send.GetSmsDeliveryStatus, class com.hp.som.ws.parlayx21.sms.send.GetSmsDeliveryStatusResponse, class com.hp.som.ws.parlayx21.common.PolicyExceptionInfo, class com.hp.som.ws.parlayx21.common.ServiceExceptionInfo],tns=http://www.csapi...
2008-10-01 15:46:18,478:org.jboss.ws.metadata.umdm.OperationMetaDataFound best matching java method: public abstract java.lang.String com.hp.som.ws.parlayx21.sms.send.SendSms.sendSms(java.util.List,java.lang.String,com.hp.som.ws.parlayx21.common.ChargingInformation,java.lang.String,com.hp.som.ws.parlayx21.common.SimpleReference) throws com.hp.som.ws.parlayx21.common.PolicyException,com.hp.som.ws.parlayx21.common.ServiceException|
2008-10-01 15:46:18,478:org.jboss.ws.metadata.umdm.OperationMetaDataFound best matching java method: public abstract java.lang.String com.hp.som.ws.parlayx21.sms.send.SendSms.sendSmsRingtone(java.util.List,java.lang.String,com.hp.som.ws.parlayx21.common.ChargingInformation,java.lang.String,com.hp.som.ws.parlayx21.sms.common.SmsFormat,com.hp.som.ws.parlayx21.common.SimpleReference) throws com.hp.som.ws.parlayx21.common.PolicyException,com.hp.som.ws.parlayx21.common.ServiceException|
2008-10-01 15:46:18,509:org.jboss.ws.metadata.umdm.OperationMetaDataFound best matching java method: public abstract java.lang.String com.hp.som.ws.parlayx21.sms.send.SendSms.sendSmsLogo(java.util.List,java.lang.String,com.hp.som.ws.parlayx21.common.ChargingInformation,byte[],com.hp.som.ws.parlayx21.sms.common.SmsFormat,com.hp.som.ws.parlayx21.common.SimpleReference) throws com.hp.som.ws.parlayx21.common.PolicyException,com.hp.som.ws.parlayx21.common.ServiceException|
2008-10-01 15:46:18,509:org.jboss.ws.metadata.umdm.OperationMetaDataFound best matching java method: public abstract java.util.List com.hp.som.ws.parlayx21.sms.send.SendSms.getSmsDeliveryStatus(java.lang.String) throws com.hp.som.ws.parlayx21.common.PolicyException,com.hp.som.ws.parlayx21.common.ServiceException|
2008-10-01 15:46:18,509:org.jboss.ws.metadata.umdm.EndpointMetaDataUsing default encoding style: literal|
2008-10-01 15:46:18,572:org.jboss.ws.metadata.builder.jaxws.JAXWSWebServiceMetaDataBuilderEND: rebuildMetaData
ServiceMetaData:
qname={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/service}SendSms
refName=null
wsdName=null
wsdlFile=null
wsdlLocation=null
jaxrpcMapping=null
publishLocation=null
securityConfig=null
properties=null
TypesMetaData:
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}se...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}se...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}Po...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}Se...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}se...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}se...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}se...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}se...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}ge...]
[complexType={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/interface}ge...]
|
2008-10-01 15:46:18,572:org.jboss.ws.metadata.umdm.EndpointMetaDataConfigure SOAPBinding|
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.handler.HandlerResolverImplinitHandlerChain: PRE|
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.handler.HandlerResolverImplinitHandlerChain: ENDPOINT|
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.handler.HandlerResolverImplinitHandlerChain: POST|
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.handler.HandlerResolverImplgetHandlerChain: [type=PRE,info=[service={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/s...
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.handler.HandlerResolverImplgetHandlerChain: [type=POST,info=[service={http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/...
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.handler.HandlerResolverImplgetHandlerChain: [type=ENDPOINT,info=[service={http://www.csapi.org/wsdl/parlayx/sms/send/v...
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.binding.BindingImplsetHandlerChain: []|
2008-10-01 15:46:18,572:org.jboss.ws.core.jaxws.spi.ServiceDelegateImplNo port configuration for: {http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/service}SendSms|
I don`t know if this is the correct usage pattern, or I should reuse the obtained Port.
I have browse the tests and examples, but I haven`t been able to get a conclusion.
Also, requests made to obtained port, must be done with different endpoint,timeout in some requests from other, so I don`t know If I should pool obtained port for every endpoint, and use pooled instances. Also, If I have 2 concurrent requests to send to same pooled port, is it going to have any problem, or it is thread safe?
Now I'm doing a static service, and using as this:
| private String send(...params...){
| SendSmsService service = new SendSmsService(null, qname);
| SendSms stub = service.getSendSms();
| stub.getRequestContext().put(StubExt.PROPERTY_CLIENT_TIMEOUT,1000);
| stub.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, ...);
| response = stub.sendSms(...params....);
| return response;
| }
| ...
| And, the getSendSms in the port is:
| public class SendSmsService extends Service{
| ....
| public SendSms getSendSms() {
| return (SendSms)super.getPort(new QName("http://www.csapi.org/wsdl/parlayx/sms/send/v2_2/service", "SendSms"), SendSms.class);
| }
| }
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4179831#4179831
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4179831
17 years, 7 months
[Persistence, JBoss/CMP, Hibernate, Database] - Entities in clustered environment
by testrot
Hello,
I read the JBoss Application Server Clustering Guide version 5.0.0 beta to receive an impression about the failover/load balancing features provided by JBoss AS 5.0. The ultimate goal is to build a failsafe system on top of the AS.
But I'm not quite sure about the failover capabilities concerning entities. The Clustering guide says that a distributed cache can by used for entities to avoid db round trips. The entity manager injected by the AS uses this cache and so my application benefits from it. But as far as I understood I don't get any failsafe benefits. If the db server fails the whole systems fails, so the db is a single point of failure.
Is there any mechanism/system deployment to get rid of this single point of failure?
I guess using a high end database cluster would be one, but is there another solution. Perhaps using 2 separate databases and something like a replication mechanismen inside the AS which replicates entities across the 2 db instances?
Thanks for help,
Martin
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4179826#4179826
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4179826
17 years, 7 months
[JBoss jBPM] - Re: Dying processes problem
by kukeltje
"Turanyi" wrote :
| Imagine: I deploy process. Everything is ok. Process works.
|
It can't just work... process INSTANCES have to be started or signalled
"Turanyi" wrote :
| Now I stop JBoss server by ctrl+c. Server shutdown.
| Ok, this should not be a problem"Turanyi" wrote :
| After some time I start JBoss server and I see problems with deploy process from tmp...
What deploy processes from tmp? What problems?
"Turanyi" wrote :
| I look to jbossws console and I see prosess is not started. Process not respond, process is dead.
| jbossws console? Never heard of that... process not responding?if it is persistant in the database you have to signal PROCESS INSTANCES again to continue to the next state... does not happen automagically
"Turanyi" wrote :
| I have to deploy it again to use it.
| never heard of that...did you build custom code?"Turanyi" wrote :
| WTF. Is it normal?
Please no swearing... even I have never done that
You have to be way more specific for us to be able to help you
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4179823#4179823
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4179823
17 years, 7 months
[JBossWS] - Passing subclasses as parameters
by sagimann
Hi,
I've encountered an issue while trying to declare web service methods which accept subclasses. The published WSDL does not contain the sub classes even if I specify them in @XmlSeeAlso. I've read some posts about this here, and it seems that it should be supported in JBossWS 2.0.2 and higher, but I tried 2.0.2 and 3.0.3 - still the same result.
My web service code:
| import javax.jws.WebService;
| import javax.jws.WebMethod;
| import javax.jws.WebParam;
| import javax.xml.bind.annotation.XmlSeeAlso;
|
| @WebService
| @XmlSeeAlso(SubBean.class)
| public class Hello {
| @WebMethod public String testAbstractBeanArg(
| @WebParam AbstractBean bean) {
| return "abstract bean: " + bean.getClass().getName() + " " + bean.toString();
| }
| }
|
Now, I look in the published WSDL, and I only see the abstractBean declaration - no subBean declaration. This does not happen with JAXWS RI 2.1 (Metro), which properly generates the "subBean" schema.
any ideas what should I do to see the subBean schema?
thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4179822#4179822
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4179822
17 years, 7 months