lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <>
Subject Re: Bad Request (Solr + Weblogic + Oracle DB)
Date Thu, 02 Feb 2012 13:37:45 GMT
I just tried your code in 3.x (with no DB connection) and it works fine,
so it looks like something in your environment....

Longer term, it's a bad idea to commit (or even update) single
documents, you can use the
add(Collection<SolrInputDocument) form to send a bunch of docs at once, either
the UpdateRequest version or the CommonsHttpSolrServer version.... and
think about
the commitWithin rather than explicitly committing, but that's for later....

Could it be something as silly as the wrong port? Or something else on
port 7001?
Are your Solr logs showing anything? What version of Solr are you running?

You might consider taking the Oracle stuff out and just creating a
dummy document
just to remove one more variable, though I expect that part's just
fine given that
I assume your print statements are showing valid output.


On Thu, Feb 2, 2012 at 8:25 AM, Michael Kuhlmann <> wrote:
> Hi rzao!
> I think this is the problem:
> On 02.02.2012 13:59, rzoao wrote:
>>                                UpdateRequest req = new UpdateRequest();
>>  req.setAction(AbstractUpdateRequest.ACTION.COMMIT, false,
>>                                                false);
>>                                req.add(documento);
> You create a commit request, but send a document with it - that won't work.
> Either you add documents, or you perform a commit, but you can't do both.
> Remove the line with setAction(), send the document, and after that, call
> commit() directly on the SolrServer.
> If this doesn't help, then have a look into Weblogic's log files. You should
> find an exception there that helps you more.
> -Kuli

View raw message