Hello everybody, I'm facing some problems migrating an application from 
jboss-3.2.5 to jboss-4.0.3SP1.

First I tryed deploying it in jboss 4.

and after deploying I tryed to login into my application and I get an exception 
reading my jndi.properties.

so I had to wirte in my code this: 



  | public synchronized Object getRemoteObject( String nombre, Class clase )
  |                         throws NamingException, IOException     {
  | 
  |                 Object recurso = recursos.get( nombre );
  | 
  |                 if ( recurso == null ){
  | 
  |                         if ( ctx == null ){
  |                                 return null;
  |                         }
  | 
  | 
  |                                 if ( propsConexion == null ){
  |                                          propsConexion = new Properties();
  |                propsConexion.setProperty( "java.naming.factory.initial", 
"org.jnp.interfaces.NamingContextFactory" );
  |                propsConexion.setProperty( "java.naming.provider.url", 
"jnp://localhost:1099" );
  |                propsConexion.setProperty( "java.naming.factory.url.pkgs", 
"org.jboss.naming:org.jnp.interfaces" );
  |                                 }
  | 
  |                                 if ( propsConexion.get( 
Context.INITIAL_CONTEXT_FACTORY ) == null
  |                                                 || propsConexion.get( 
Context.PROVIDER_URL ) == null
  |  )
  |                                         throw new IllegalArgumentException(
  |                                                 "Archivo de propiedades no 
vĂ¡lido"
  |                                         );
  |                         }
  | 
  |                         Context contx = new InitialContext( propsConexion );
  |                         Object home = contx.lookup( nombre );
  |                         recurso = PortableRemoteObject.narrow( home, clase 
);
  |                         if ( recurso != null ){
  |                                 recursos.put( nombre, recurso );
  |                         }
  | 
  | 
  |                 return recurso;
  | 
  |   }
  | 
  |     
  | 


as you can notice I had to write exactly as it appears in the jndi.properties 
file.

So I was able to bypass this situation, but now, when I try to login in the 
application, I get this exception: 



  | 01:41:18,178 INFO  [RequestProcessor] Processing a 'POST' for path 
'/autenticar'
  | 01:41:19,031 ERROR [LogInterceptor] EJBException in method: public abstract 
co.com.etb.af.ejb.Servic
  | iosActivosFijos co.com.etb.af.ejb.ServiciosActivosFijosHome.create() throws 
javax.ejb.CreateExceptio
  | n,java.rmi.RemoteException:
  | javax.ejb.EJBException: Invalid invocation, check your deployment 
packaging, method=public abstract 
  | co.com.etb.af.ejb.ServiciosActivosFijos 
co.com.etb.af.ejb.ServiciosActivosFijosHome.create() throws 
  | javax.ejb.CreateException,java.rmi.RemoteException
  |         at 
org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invokeHome(StatelessSessionC
  | ontainer.java:161)
  |         at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invokeHome(CachedConnect
  | ionInterceptor.java:180)
  |         at 
org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invokeHome(StatelessSessionInst
  | anceInterceptor.java:83)
  |         at 
org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:90)
  |         at 
org.jboss.ejb.plugins.CallValidationInterceptor.invokeHome(CallValidationInterceptor.java
  | :41)
  |         at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:110)
  |         at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:335)
  |         at 
org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:146)
  |         at 
org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:130)
  |         at 
org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:121)
  |         at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invokeHome(ProxyFactoryFinderIntercep
  | tor.java:93)
  |         at 
org.jboss.ejb.SessionContainer.internalInvokeHome(SessionContainer.java:613)
  |         at org.jboss.ejb.Container.invoke(Container.java:894)
  |         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:585)
  |         at 
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
  |         at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
  |         at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
  |         at 
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:245)
  |         at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:644)
  |         at 
org.jboss.invocation.local.LocalInvoker$MBeanServerAction.invoke(LocalInvoker.java:155)
  |         at 
org.jboss.invocation.local.LocalInvoker.invoke(LocalInvoker.java:104)
  |         at 
org.jboss.invocation.InvokerInterceptor.invokeLocal(InvokerInterceptor.java:179)
  |         at 
org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:165)
  |         at 
org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:46)
  |         at 
org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:55)
  |         at 
org.jboss.proxy.ejb.HomeInterceptor.invoke(HomeInterceptor.java:169)
  |         at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:86)
  |         at $Proxy84.create(Unknown Source)
  |         at 
co.com.etb.af.cliente.modelo.DelegateActivosFijos.validarUsuario(DelegateActivosFijos.jav
  | a:89)
  |         at 
co.com.etb.af.cliente.action.AutenticarAction.execute(AutenticarAction.java:61)
  |         at 
org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:443)
  | 
  |         at 
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:265)
  |         at 
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1217)
  |         at 
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:497)
  |         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
  |         at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
  |         at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.j
  | ava:252)
  |         at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 
  |         at 
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
  |         at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.j
  | ava:202)
  |         at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 
  |         at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
  |         at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
  |         at 
org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
  |         at 
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.ja
  | va:159)
  |         at 
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
  |         at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
  |         at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
  |         at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
  |         at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
  |         at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
  |         at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11P
  | rotocol.java:744)
  |         at 
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
  |         at 
org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
  |         at java.lang.Thread.run(Thread.java:595)
  | 
  | 


The most strange is that, There's another similar application, similar because 
of its structure, that had the same problem at the begining with the 
jndi.properties. so I made the same change in the Service Locator, and it 
worked for that application.

What could the problem be? What should I do? Should I post more files 
(descriptors, packing-biuld, etc) for someone to get a better idea?

I didn't develop these two applications they were develop by a coworker that 
now doesn't work in my company. but I have the code.

Thanks a lot 



View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3937800#3937800

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3937800


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to