Problem with Roles and Authentication
by Aurynn Shaw
I don't know what I've done wrong. :)
I inherited an app, that used to be running on JBoss2.4.10 and
Tomcat3, and I'm trying to get it running on Jboss4.0.4, and
Tomcat5.5.20.
So far, this has gone fairly well. Everything starts up semi-normally.
However, I can't log in. At all. Using a debugger, I traced to the
very spot it checks for validity and found that the Principal objects
aren't being populated with the Role information from the user data
store.
I have tried LDAP (the original), Postgres, and finally just a basic
memory store, trying to find out why it's not loading my roles.
My OS and JDK are CentOS Linux 4.4 and JDK 1.5.0_11. I'm running
packages from jpackage.org.
Tomcat is set to use JBossSecurityMgrRealm, so my changes have been
going into login-config.xml
Thanks,
Aurynn
19Â years, 1Â month
[JBoss Seam] - Re: Issue with Seam and Tomcat 6 during tomcat startup
by lle
hi Michael,
Did you have your jndi configured correctly?
This is what I got in my log file of a successful Seam + Tomcat 5.5:
2007.03.09 14:29:08,808 INFO [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.LocalOnlyContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
| 2007.03.09 14:29:08,808 INFO [DatasourceConnectionProvider] Using datasource: java:/hibernateDatasource-mysql
| 2007.03.09 14:29:08,808 INFO [SettingsFactory] RDBMS: MySQL, version: 5.0.22-community-nt
| 2007.03.09 14:29:08,808 INFO [SettingsFactory] JDBC driver: MySQL-AB JDBC Driver, version: mysql-connector-java-3.1.13 ( $Date: 2005-11-17 15:53:48 +0100 (Thu, 17 Nov 2005) $, $Revision$ )
| 2007.03.09 14:29:08,808 INFO [Dialect] Using dialect: org.hibernate.dialect.MySQLDialect
| 2007.03.09 14:29:08,824 INFO [TransactionFactoryFactory] Transaction strategy: org.hibernate.transaction.JTATransactionFactory
| 2007.03.09 14:29:08,824 INFO [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.LocalOnlyContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
| 2007.03.09 14:29:08,824 INFO [TransactionManagerLookupFactory] instantiating TransactionManagerLookup: org.hibernate.transaction.JBossTransactionManagerLookup
| 2007.03.09 14:29:08,824 INFO [TransactionManagerLookupFactory] instantiated TransactionManagerLookup
| 2007.03.09 14:29:08,824 INFO [TransactionManagerLookupFactory] instantiating TransactionManagerLookup: org.hibernate.transaction.JBossTransactionManagerLookup
| 2007.03.09 14:29:08,824 INFO [TransactionManagerLookupFactory] instantiated TransactionManagerLookup
>From your exception, it seems that your JNDI doesn't get set up correctly.
You need to have the jndi.properties under your WEB-INF/lib directory. The file should contain these lines:
java.naming.factory.initial org.jnp.interfaces.LocalOnlyContextFactory
| java.naming.factory.url.pkgs org.jboss.naming:org.jnp.interfaces
If that doesn't help, turn on your seam debug level and full debug log file.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4026800#4026800
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4026800
19Â years, 1Â month
[JBoss Seam] - Re: Issue with Seam and Tomcat 6 during tomcat startup
by mlh496
Hey there,
The problem I've hit deploying a Seam app to Tomcat deals with the datasource. Here is a sample of the error trail that I get:
16:27:52,083 ERROR [NamingHelper] Could not obtain initial context
| javax.naming.NamingException: Local server is not initialized
| 16:27:52,098 FATAL [DatasourceConnectionProvider] Could not find datasource: java:/comp/env/omegaDatasource
| javax.naming.NamingException: Local server is not initialized
| 16:27:52,098 ERROR [[/omega]] Exception sending context initialized event to listener instance of class org.jboss.seam.servlet.SeamListener
| javax.persistence.PersistenceException: org.hibernate.HibernateException: Could not find datasource
| Caused by: org.hibernate.HibernateException: Could not find datasource
| at org.hibernate.connection.DatasourceConnectionProvider.configure(DatasourceConnectionProvider.java:56)
| Caused by: javax.naming.NamingException: Local server is not initialized
| at org.jnp.interfaces.LocalOnlyContextFactory.getInitialContext(LocalOnlyContextFactory.java:45)
Does this look familiar to the errors you encountered?
Thanks for the link; I'll give that a try.
-Michael
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4026791#4026791
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4026791
19Â years, 1Â month