portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ate Douma <...@douma.nu>
Subject Re: Migration from Jetspeed2.0-M3 to Jetspeed 2.1.3
Date Tue, 01 Jul 2008 07:36:37 GMT
Fred Bonsu wrote:
> Hi Ate,
> After installing your DefaultLoginModule class, this is what I got, a 
> null point exception. Does this mean that no record of admin account the 
> db?
No, if you look at the stack trace, line 212 throwing the NPE is:

             success = ums.authenticate(this.username, password);

This means the ums (UserManager) isn't configured correctly on your portal.
My guess is, your Spring assembly isn't setup correctly/completely as it should.

Jetspeed 2.1.3 with respect to Jetspeed2.0-M3 has *many* changes to its (required) Spring
configuration.
I don't know if you properly reviewed those before upgrading to 2.1.3, but you really need
to.

My suggestion is:
- do a clean *Jetspeed* 2.0M3 installation (so, without any of your custom portal changes
yet)
- do a clean separate Jetspeed 2.1.3 installation
- carefully compare the following files from both tomcat installation:
     conf/Catalina/localhost/jetspeed.xml
     webapps/jetspeed/WEB-INF/web.xml
     webapps/jetspeed/WEB-INF/conf/jetspeed.properties
     webapps/jetspeed/WEB-INF/assembly/*.xml
     webapps/jetspeed/WEB-INF/assembly/boot/datasource.xml
   this will give you the required changes for a *default* installation
- check your custom portal *overrides* of any of the above
- merge in the changes you determined from above

One final note: be careful with adding *new* (default) features from Jetspeed 2.1.3 which
you might not want/need in 
your custom portal, like maybe additional Jetspeed servlet mappings (in web.xml) and/or related
pipelines 
(assembly/pipelines.xml). Those could open up new access paths into your portal which might
not be relevant or 
wanted/allowed in your case.

HTH,

Ate

> Here is the log:
>  
> java.lang.NullPointerException
>         at 
> org.apache.jetspeed.security.impl.DefaultLoginModule.login(DefaultLoginModule.java:212)
>         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 
> javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
>         at 
> javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
>         at 
> javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at 
> javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
>         at 
> javax.security.auth.login.LoginContext.login(LoginContext.java:579)
>         at 
> org.apache.catalina.realm.JAASRealm.authenticate(JAASRealm.java:366)
>         at 
> org.apache.catalina.authenticator.FormAuthenticator.authenticate(FormAuthenticator.java:258)
>         at 
> org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:417)
>         at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>         at 
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
>         at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
>         at 
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
>         at 
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
>         at 
> org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
>         at 
> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
>         at 
> org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
>         at 
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
>         at java.lang.Thread.run(Thread.java:595)
> 
> regards
> Beema
> ----- Original Message ----
> From: Ate Douma <ate@douma.nu>
> To: Jetspeed Developers List <jetspeed-dev@portals.apache.org>
> Cc: bonsu_f@yahoo.com
> Sent: Monday, June 30, 2008 3:42:18 PM
> Subject: Re: Migration from Jetspeed2.0-M3 to Jetspeed 2.1.3
> 
> Whatever goes wrong isn't fully logged because 
> DefaultLoginModule.login() on line 230 returns a new LoginException with
> the current exception message only.
> 
> I've attached a modified version of the DefaultLoginModule.class which 
> additionally prints the current stack trace:
> 
>   Index: 
> components/security/src/java/org/apache/jetspeed/security/impl/DefaultLoginModule.java
>   ===================================================================
>   --- 
> components/security/src/java/org/apache/jetspeed/security/impl/DefaultLoginModule.java
   
> (revision 667498)
>   +++ 
> components/security/src/java/org/apache/jetspeed/security/impl/DefaultLoginModule.java
   
> (working copy)
> 
>   @@ -227,6 +227,7 @@
>             catch (Exception ex)
>             {
>               success = false;
>   +            ex.printStackTrace();
>                 throw new LoginException(ex.getMessage());
>             }
>         }
> 
> You can extract the attached zipfile (containing only the Java5 compiled 
> modified version of this class) under your
> portal WEB-INF/classes and then try again and check your Tomcat 
> *console* output, e.g. don't run Tomcat as a Windows
> Service, start it manually from the command line:
> 
>   $TOMCAT_HOME/bin/catalina.sh run
> or
>   $TOMCAT_HOME\bin\catalina.bat run
> 
> NB: the attachment won't be allowed through this mailing list which is 
> why I'm cc'ing to you directly as well.
> 
> Ate
> 
> Beema wrote:
>  > Hi,
>  > I'm getting login exception when I try to login using admin (existing)
>  > account. The tomcat log  is so vague, I don't know where to look. Can
>  > someone help? It is taking me too long. Help!!!
>  >
>  > Here is the log:
>  > http://www.nabble.com/file/p18194786/tomcat-ma-1.log tomcat-ma-1.log
>  >
>  > I'm now using tomcat-5.5.23.
>  >
>  >
>  > David Sean Taylor wrote:
>  >>
>  >> On Jun 25, 2008, at 3:50 AM, Beema wrote:
>  >>
>  >>> Hi Woonsan,
>  >>> I have been able to port existing portal/portlet into into 
>  >>> Jetspeed-2.1.3. I
>  >>> could render our customized Login Portlet. The problem was actually 
>  >>> the
>  >>> velocity templates as you suggested.
>  >>>
>  >>> I'm facing another problem, that is, when I tried to login as admin
>  >>> (existing account) I got nullpointer exception.
>  >>
>  >> check your database, you don't have the default profiling rule defined 
>  >> in the database
>  >> (the PROFILING_RULE table should have a column with 'j1' as the rule 
>  >> name)
>  >> this is usually indicative of the database not being populated
>  >>
>  >> ---------------------------------------------------------------------
>  >> To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org 
> <mailto:jetspeed-dev-unsubscribe@portals.apache.org>
>  >> For additional commands, e-mail: 
> jetspeed-dev-help@portals.apache.org 
> <mailto:jetspeed-dev-help@portals.apache.org>
>  >>
>  >>
>  >>
>  >
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message