[JBoss Tools (users)] - Re: Deploying Seam (Servers and Runtimes)
by redbird
Thanks. Unfortunately I can't get that to work. I've tried that, using the deploy only server and runtime, but when I try and deploy it, nothing happens. Nothing gets copied over. The project seems to build fine. Just doesn't get copied.
I'm sure it's something simple I'm overlooking. I'll try and describe what I'm doing. I created a new Seam Web Project, which created 4 separate project folders. One folder is the main folder, then the ear, ejb, and test folder. Under the main folder, I right-clicked and opened Properties. I then selected the deploy only server and deploy only runtime. The deploy only server was created to point to the deployment directory of my local jboss installation.
I then did a "Run as"/"Run on Server" on the main project. But nothing gets copied over. I checked the deployment directory on the local disk, and nothing new is there. I've double-checked the directory to make sure it is actually the deployment directory.
I know it's something silly, but I just can't seem to see what it is. Any help would be appreciated. Thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4143196#4143196
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4143196
18 years, 2 months
[JBoss Messaging] - Re: Message delivery delay > 30 sec sometimes
by clebert.suconic@jboss.com
"bodrin" wrote : Ok, this sounds logical, but the problem is that there is nothing killed and no connection is lost. Except if someone else tries to consume messages from my queue, but always rejects them and then I receive them.
| Because I always receive the message I sent, but once it is immediate and other time is with a delay.
|
| Is there a way to track which client is with
|
| | client 4sg1e4f-7tkxjl-feskzgma-1-feskzh69-d, jmsClientID=a-8tgzksef-1-amgzksef-ljxkt7-f4e1gs4
| |
|
| .. to extract this info somehow from the connection object or some jboss specific way at the client side ?
The first part is org.jboss.jms.client.container.JMSClientVMIdentifier.instance
The second part, inside the JBossConnection, you will find a JBossRemote.Client. That ID will be one of the IDs inside Remote. (The invoker inside the remote object).
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4143193#4143193
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4143193
18 years, 2 months
[Security & JAAS/JBoss] - Migration from tomcat 6.0.14 to JBoss 4.2.2
by manoz82
Hi All
In my company we are currently developing a web application using apache tomcat 6.0.14 web server.
We are considering a migration to JBoss AS 4.2.2.
We have a user database and a security realm defined in application.war/META-INF/context.xml :
| <Realm className="org.apache.catalina.realm.DataSourceRealm" debug="99"
| dataSourceName="jdbc/dbserver"
| localDataSource="true"
| userTable="user"
| digest="SHA-512"
| userNameCol="user_name"
| userCredCol="password"
| userRoleTable="user_role"
| roleNameCol="role"/>
|
Is there a way to use this configuration on JBoss ?
I have already read that the context.xml should be placed in the WEB-INF folder instead, but that doesn't seem to help
when I try logging in I get the following exception:
|
| Exception performing authentication
| javax.naming.NamingException: No naming context bound to this class loader
| at org.apache.naming.ContextBindings.getClassLoader(ContextBindings.java:326)
| at org.apache.catalina.realm.DataSourceRealm.open(DataSourceRealm.java:395)
| at org.apache.catalina.realm.DataSourceRealm.authenticate(DataSourceRealm.java:283)
| at org.apache.catalina.authenticator.FormAuthenticator.authenticate(FormAuthenticator.java:257)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:416)
| at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:562)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
| 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:262)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
| at java.lang.Thread.run(Unknown Source)
|
|
Any ideas?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4143190#4143190
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4143190
18 years, 2 months
[Persistence, JBoss/CMP, Hibernate, Database] - Re: IllegalArgumentException( argument type mismatch) when u
by peter_zat
After poking at this a bit more, I think I sort of understand what was going on (though I don't really know why) and have a resolution which I am mostly confident in (but some reassurance would be nice!)
It appears to be a problem with the way Hibernate uses the JBoss cache. Hibernate is storing a CacheEntry in the clustered JBoss TreeCache for each entity instance. This CacheEntry seems to store an array of property values, the order of which is determined by some metadata, presumably gathered by introspection of the entity's class. When pulling data out of the cache, it again uses this metadata to put those values back into the correct entity properties.
The assumption seems to be that in two different JVMs this metadata about the entity is constructed identically; i.e. the properties are listed in the same order. If the second JVM for some reason has the properties in a different order, then when reconstructing an entity from a CacheEntry, it tries to stuff values into the wrong properties.
I turned on the hibernate.cache.use_structured_entries setting and now instead of a CacheEntry that uses an array with an assumed order, it uses a StructuredCacheEntry (I think) which seems to use Map semantics (i.e. key=value) and now my 2nd JVM gets the values in their correct properties.
Does anyone with deeper understanding of Hibernate and/or JBoss cache have any thoughts on this? Is this is a good workaround?
I think this may be a bug in Hibernate and I'll go file an issue in their Jira.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4143180#4143180
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4143180
18 years, 2 months
[Persistence, JBoss/CMP, Hibernate, Database] - Re: Referenced datasource not found with JBoss 5.0 (Beta4)
by depryf
Here is the full stack trace. This happens after the EJB deployment (which is fine), then Tomcat deploys the WAR and our Servlet entry point is being executed; it tries to access our database (Oralce) and the exception happens:
| javax.ejb.EJBException: com.imsweb.seerdms.shared.exception.SeerInvalidStateException: Unable to get connection.
| at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:63)
| at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:83)
| at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:193)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:64)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.tx.NullInterceptor.invoke(NullInterceptor.java:42)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.security.Ejb3AuthenticationInterceptorv2.invoke(Ejb3AuthenticationInterceptorv2.java:166)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:249)
| at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:214)
| at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:86)
| at $Proxy109.getDbColumnInfo(Unknown Source)
| at com.imsweb.seerdms.shared.util.PropertyMappingsUtils.initialize(PropertyMappingsUtils.java:139)
| at com.imsweb.seerdms.shared.util.PropertyMappingsUtils.initialize(PropertyMappingsUtils.java:111)
| at com.imsweb.seerdms.web.shared.configuration.ConfigurationServlet.init(ConfigurationServlet.java:158)
| at javax.servlet.GenericServlet.init(GenericServlet.java:212)
| 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:4072)
| at org.apache.catalina.core.StandardContext.start(StandardContext.java:4377)
| at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
| at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
| at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
| 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.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:297)
| at org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
| at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
| at org.apache.catalina.core.StandardContext.init(StandardContext.java:5357)
| at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:346)
| at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:142)
| at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:347)
| at org.jboss.web.deployers.WebModule.startModule(WebModule.java:89)
| at org.jboss.web.deployers.WebModule.start(WebModule.java:67)
| 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:184)
| at $Proxy5.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:327)
| at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:255)
| at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1309)
| at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:734)
| at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:862)
| at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:784)
| at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:622)
| at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:411)
| at org.jboss.system.ServiceController.doChange(ServiceController.java:659)
| at org.jboss.system.ServiceController.start(ServiceController.java:431)
| at org.jboss.system.deployers.ServiceDeployer.start(ServiceDeployer.java:150)
| at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:108)
| at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:46)
| at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:65)
| 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.doInstallParentFirst(DeployersImpl.java:853)
| at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:874)
| at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:906)
| at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:794)
| at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:327)
| at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1309)
| at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:734)
| at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:862)
| at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:784)
| at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:622)
| at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:411)
| at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:498)
| at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:506)
| at org.jboss.system.server.profileservice.ProfileServiceBootstrap.loadProfile(ProfileServiceBootstrap.java:246)
| at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:131)
| at org.jboss.bootstrap.AbstractServerImpl.start(AbstractServerImpl.java:408)
| at org.jboss.Main.boot(Main.java:208)
| at org.jboss.Main$1.run(Main.java:534)
| at java.lang.Thread.run(Thread.java:619)
| Caused by: com.imsweb.seerdms.shared.exception.SeerInvalidStateException: Unable to get connection.
| at com.imsweb.seerdms.app.shared.dao.hibernate.HibernateCommonDataDAO.getDbColumnInfo(HibernateCommonDataDAO.java:125)
| at com.imsweb.seerdms.app.shared.buslogic.CommonDataApiSessionBean.getDbColumnInfo(CommonDataApiSessionBean.java:143)
| 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.aop.joinpoint.MethodInvocation.invokeTarget(MethodInvocation.java:121)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:110)
| at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
| at com.imsweb.seerdms.app.shared.buslogic.SessionInterceptor.aroundInvoke(SessionInterceptor.java:45)
| at sun.reflect.GeneratedMethodAccessor96.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
| at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
| ... 93 more
| Caused by: javax.naming.NameNotFoundException: app-specific not bound
| at org.jnp.server.NamingServer.getBinding(NamingServer.java:542)
| at org.jnp.server.NamingServer.getBinding(NamingServer.java:550)
| at org.jnp.server.NamingServer.getObject(NamingServer.java:556)
| at org.jnp.server.NamingServer.lookup(NamingServer.java:267)
| at org.jnp.server.NamingServer.lookup(NamingServer.java:270)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:669)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:776)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:629)
| at javax.naming.InitialContext.lookup(InitialContext.java:392)
| at com.imsweb.seerdms.shared.api.ServiceLocator.lookup(ServiceLocator.java:631)
| at com.imsweb.seerdms.shared.api.ServiceLocator.getConnection(ServiceLocator.java:597)
| at com.imsweb.seerdms.app.shared.dao.hibernate.HibernateCommonDataDAO.getDbColumnInfo(HibernateCommonDataDAO.java:97)
| ... 113 more
|
Here is our datasource file:
| <datasources>
| <local-tx-datasource>
| <jndi-name>app/datasource</jndi-name>
| <connection-url>jdbc:oracle:thin:@some.address:1521:app</connection-url>
| <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>
| <user-name>***</user-name>
| <password>***</password>
| <min-pool-size>5</min-pool-size>
| <max-pool-size>100</max-pool-size>
| <blocking-timeout-millis>60000</blocking-timeout-millis>
| <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
| </local-tx-datasource>
| </datasources>
|
This is the code that provides the connection, the first method is actually throwing a NamingException that is catch by some other code, but this is the root of the problem:
| public Connection getConnection() throws NamingException, SQLException {
| DataSource dataSource = (DataSource)lookup(DataSource.class, "java:comp/env/app-specific/datasource");
|
| return dataSource.getConnection();
| }
|
| protected Object lookup(Class<?> clazz, String name) throws NamingException {
|
| //- Obtain a cached initial context
| InitialContext context = new InitialContext();
|
| try {
| Object objRef = context.lookup(name);
| return PortableRemoteObject.narrow(objRef, clazz);
| }
| finally {
| context.close();
| }
| }
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4143173#4143173
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4143173
18 years, 2 months