DataImportHandler on Websphere 6.1 NullPointer Exception from SRTServletResponse.setContentType

2011-01-12 Thread chrisclark

Has anyone had any success using the DataImportHandler on Webshpere 6.1

I am getting the following exception from Websphere when viewing the
DataImport Development Console in the browser. The ajax call to retrieve the
dataconfig.xml fails. The thing is that if you do an import the import
succeeds.

[1/11/11 15:38:10:194 GMT] 0042 SolrDispatchF I
org.apache.solr.servlet.SolrDispatchFilter init SolrDispatchFilter.init()
done
[1/11/11 15:38:10:381 GMT] 0042 SolrCore  I
org.apache.solr.core.SolrCore execute [] webapp=/solr path=/select
params={command=show-config&qt=/dataimport} status=0 QTime=47 
[1/11/11 15:38:10:428 GMT] 0042 SolrDispatchF E
org.apache.solr.common.SolrException log java.lang.NullPointerException
at
com.ibm.ws.webcontainer.srt.SRTServletResponse.setContentType(SRTServletResponse.java:1017)
at
org.apache.solr.servlet.SolrDispatchFilter.writeResponse(SolrDispatchFilter.java:318)
at
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:254)

This may be a symptom of what's causing problems when my app tries to do a
dataimport using SolrJ, so that is why I put the stack trace here.

What's happening in my app is that SolrJ sends an Http request to the Solr
instance to do a dataimport. The dataimport succeeds, but the response comes
back as a 404 page not found. This causes SolrJ to throw an exception, and
so the rest of my application fails and reports an error. When doing this
call there is no stack trace in the logs, just an error saying page not
found.

The app works fine on JBoss but doesn't work on Websphere.
The version of Solr is 1.4.1
Websphere is: 
version 6.1.0.0 
Build Number: b0620.14
Build Date: 5/16/06


-- 
View this message in context: 
http://lucene.472066.n3.nabble.com/DataImportHandler-on-Websphere-6-1-NullPointer-Exception-from-SRTServletResponse-setContentType-tp2240281p2240281.html
Sent from the Solr - User mailing list archive at Nabble.com.


DataImportHandler on Websphere - http response 404

2011-01-12 Thread chrisclark

Has anyone had any success using the DataImportHandler on Webshpere 6.1

Below are the logs for a call to reload-config.
I have turned on debug and stepped through the code and the
dataImportHandler correctly reloads the config and the response gets written
out to the http response without any errors being thrown from the Solr code.
However, in Websphere the response is returned as a 404 page not found. So
this is happening somewhere in the Websphere code.
There are no errors reported in any of the Websphere logs.

This all works fine on JBoss but doesn't work on Websphere.
The version of Solr is 1.4.1
Websphere is: 
version 6.1.0.0 
Build Number: b0620.14
Build Date: 5/16/06


This is the log file snippet.

12-Jan-2011 10:54:15,320 -  -  DEBUG header:70 - >> "GET
/solr/dataimport?optimize=true&clean=false&commit=true&command=reload-config&qt=%2Fdataimport&omitHeader=true&wt=javabin&version=1
HTTP/1.1[\r][\n]"
12-Jan-2011 10:54:15,352 -  -  DEBUG header:70 - >> "User-Agent:
Solr[org.apache.solr.client.solrj.impl.CommonsHttpSolrServer] 1.0[\r][\n]"
12-Jan-2011 10:54:15,367 -  -  DEBUG header:70 - >> "Host:
10.101.41.1:10012[\r][\n]"
12-Jan-2011 10:54:15,398 -  -  DEBUG header:70 - >> "[\r][\n]"
12-Jan-2011 10:55:11,403 -  -  DEBUG header:70 - << "HTTP/1.1 404 Not
Found[\r][\n]"
12-Jan-2011 10:55:11,418 -  -  DEBUG header:70 - << "HTTP/1.1 404 Not
Found[\r][\n]"
12-Jan-2011 10:55:11,434 -  -  DEBUG header:70 - << "Last-Modified: Wed, 12
Jan 2011 10:54:15 GMT[\r][\n]"
12-Jan-2011 10:55:11,465 -  -  DEBUG header:70 - << "ETag:
"12d79dc9632"[\r][\n]"
12-Jan-2011 10:55:11,481 -  -  DEBUG header:70 - << "Cache-Control:
no-cache, no-store[\r][\n]"
12-Jan-2011 10:55:11,497 -  -  DEBUG header:70 - << "Pragma:
no-cache[\r][\n]"
12-Jan-2011 10:55:11,528 -  -  DEBUG header:70 - << "Expires: Sat, 01 Jan
2000 01:00:00 GMT[\r][\n]"
12-Jan-2011 10:55:11,543 -  -  DEBUG header:70 - << "Content-Type:
text/html;charset=ISO-8859-1[\r][\n]"
12-Jan-2011 10:55:11,559 -  -  DEBUG header:70 - << "$WSEP: [\r][\n]"
12-Jan-2011 10:55:11,575 -  -  DEBUG header:70 - << "Content-Language:
en-US[\r][\n]"
12-Jan-2011 10:55:11,606 -  -  DEBUG header:70 - << "Content-Length:
51[\r][\n]"
12-Jan-2011 10:55:11,622 -  -  DEBUG header:70 - << "Connection:
Close[\r][\n]"
12-Jan-2011 10:55:11,637 -  -  DEBUG header:70 - << "Date: Wed, 12 Jan 2011
10:55:10 GMT[\r][\n]"
12-Jan-2011 10:55:11,653 -  -  DEBUG header:70 - << "Server: WebSphere
Application Server/6.1[\r][\n]"
12-Jan-2011 10:55:11,684 -  -  DEBUG header:70 - << "[\r][\n]"
12-Jan-2011 10:55:11,700 -  -  DEBUG content:70 - << "Error 404: SRVE0190E:
File not found: /dataimport[\r][\n]"
12-Jan-2011 10:55:11,715 -  -  ERROR SolrSearchEngine:422 - Failed to
perform reload-config
org.apache.solr.client.solrj.SolrServerException: Error executing query
at
org.apache.solr.client.solrj.request.QueryRequest.process(QueryRequest.java:95)
at org.apache.solr.client.solrj.SolrServer.query(SolrServer.java:118)
at
com.norkom.search.business.engine.solr.SolrSearchEngine.executeDataImportCommand(SolrSearchEngine.java:415)
at
com.norkom.search.business.engine.solr.SolrSearchEngine.reloadDataImportConfig(SolrSearchEngine.java:374)
at
com.norkom.search.business.engine.solr.SolrSearchEngine.buildIndex(SolrSearchEngine.java:314)
at
com.norkom.search.business.jobs.FtsBuildIndexJob.executeJob(FtsBuildIndexJob.java:62)
at com.norkom.base.business.jobs.ThreadedJob.run(ThreadedJob.java:52)
at java.lang.Thread.run(Thread.java:797)
Caused by: 
org.apache.solr.common.SolrException: Not Found

Not Found




-- 
View this message in context: 
http://lucene.472066.n3.nabble.com/DataImportHandler-on-Websphere-http-response-404-tp2240440p2240440.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: DataImportHandler on Websphere - http response 404

2011-01-12 Thread chrisclark

I have found a workaround for this.

1. change the entry in solrconfig.xml for the DataImportHandler by removing
the slash from the name, like this http://lucene.472066.n3.nabble.com/DataImportHandler-on-Websphere-http-response-404-tp2240440p2242162.html
Sent from the Solr - User mailing list archive at Nabble.com.