You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by Odo <ay...@aa.wakwak.com> on 2005/09/27 14:07:56 UTC
[J1.6] getUserName() returns NULL
I am trying to change DB from hypersonic to PostgreSQL in Jetspeed 1.6.
And I had below exception.
I have looked into following file,
jetspeed-1.6/src/java/org/apache/jetspeed/services/profiler/JetspeedProfilerService.java
and found that nullpointer exception is at line 786, caused by
user.getUserName() which returns NULL.
profile.setAnonymous(
user.getUserName().equals(
JetspeedSecurity.getAnonymousUserName()));
profile.setUser(user);
I suppose that generally this is the case where connection to DB is
not established.
However, I cannot find any mistake in modifying project.properties and
webapp/WEB-INF/conf/Torque.properties like this.
torque.database.default.adapter=postgresql
torque.dsfactory.default.connection.driver = org.postgresql.Driver
torque.dsfactory.default.connection.url = jdbc:postgresql://127.0.0.1/j2
torque.dsfactory.default.connection.user = username
torque.dsfactory.default.connection.password = password
Is there any other possibilities for getUserName() to return NULL?
Or is it the problem of configuration all the same?
Odo
----------------------------------------------------------------------
org.apache.jetspeed.om.profile.ProfileException: java.lang.NullPointerException
at org.apache.jetspeed.services.profiler.JetspeedProfilerService.fallbackProfile(JetspeedProfilerService.java:823)
at org.apache.jetspeed.services.profiler.JetspeedProfilerService.getProfile(JetspeedProfilerService.java:301)
at org.apache.jetspeed.services.profiler.JetspeedProfilerService.getProfile(JetspeedProfilerService.java:848)
at org.apache.jetspeed.services.Profiler.getProfile(Profiler.java:87)
at org.apache.jetspeed.modules.actions.JetspeedAccessController.doPerform(JetspeedAccessController.java:74)
at org.apache.turbine.modules.Action.perform(Action.java:87)
at org.apache.turbine.modules.ActionLoader.exec(ActionLoader.java:122)
at org.apache.turbine.Turbine.doGet(Turbine.java:529)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
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.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(Http11Protocol.java:744)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org