Page 1 of 1

NullPointerException on adding documents

PostPosted:Mon Apr 12, 2010 4:43 am
by Anshul
Hi,

I have compiled and configured fresh code from svn on my local machine.

I am able to login successfully. I am able to add folder also but when I try to add documents it generates NullPointerException as following:
Code: Select all
2010-04-12 09:52:18,093 INFO  [STDOUT] INFO  es.git.openkm.module.direct.DirectDashboardModule - getUserDocumentsSize(1076396525670056587295-2641880071) 
2010-04-12 09:52:18,093 INFO  [STDOUT] INFO  es.git.openkm.module.direct.DirectDashboardModule - getUserDocumentsSizeCached(1076396525670056587295-2641880071) 
2010-04-12 09:52:18,093 INFO  [STDOUT] INFO  es.git.openkm.module.direct.DirectDashboardModule - getUserDocumentsSizeCached: 0 
2010-04-12 09:52:18,093 INFO  [STDOUT] INFO  es.git.openkm.module.direct.DirectDashboardModule - getUserDocumentsSize: 0 
2010-04-12 09:52:32,421 INFO  [STDOUT] ERROR es.git.openkm.frontend.server.OKMFileUploadServlet -  
java.lang.NullPointerException
	at es.git.openkm.module.direct.DirectDocumentModule.create(DirectDocumentModule.java:278)
	at es.git.openkm.api.OKMDocument.create(OKMDocument.java:68)
	at es.git.openkm.frontend.server.OKMFileUploadServlet.doPost(OKMFileUploadServlet.java:132)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
	at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
	at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
	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)

Re: NullPointerException on adding documents

PostPosted:Mon Apr 12, 2010 4:01 pm
by pavila
Can you reproduce the problem in a "JBoss with already configured OpenKM bundle"? You can download it from http://www.openkm.com/Download.html.

Re: NullPointerException on adding documents

PostPosted:Mon Apr 12, 2010 5:50 pm
by jllort
Which exact OpenKM version 4.0 or 4.1 ? put here your svn url.

Which kind of file are you uploading, can you send us to try it.

Could you try uploading in demo.openkm.com to see if there appears the error too ?

Re: NullPointerException on adding documents

PostPosted:Thu Apr 15, 2010 12:34 pm
by Anshul
Hi,

I am using version 4.0 of openkm from following svn url:

https://openkm.svn.sourceforge.net/svnr ... 4.0/openkm

I'm using simple text file to uplaod evn i'm not able to upload any file. It throws NullPointerException.

In demo.openkm.com I'm able to upload file.

Thanks.

Re: NullPointerException on adding documents

PostPosted:Thu Apr 15, 2010 5:49 pm
by jllort
Sure you're doing something bad.

I've downloaded a fresh OpenKM 4.0 version, exploded, replaced OpenKM.war file by actual 4.0/trunk, started and uploaded successfully a file.

There's no problem in actual 4.0/trunk if you make OpenKM.war file successfully sure must upload the file without problems.

Ensure you're compiling with jdk 1.6 and run with same version jboss, take a look not appears any problem on eclipse problems tab, etc... you've got some extrange problem.

1- Ensure in your actual testing computer the openkm 4.0 without changes starts well and can upload files ( with it you're sure problem is not on your computer environment, etc... )
2- After it take a look at eclipse and ensure you've compiling with right jdk, etc.. and you've not got any error ... after it replacing OpenKM.war 4.0 to your generated must run well ( there's no reason for it in code )