You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-user@jakarta.apache.org by Eirikur Hrafnsson <ei...@idega.is> on 2007/03/21 13:27:27 UTC

DASL search doesn't work with httpclient 3.0, Lucene 2.1.0

(Sending again under a new thread name with some additions)
Hi
just built our webapp with Slide from HEAD with HttpClient 3.0.1 and  
Lucene 2.1.0 (was in head) and ALMOST everything works it seems.
Our webbased slide browser works fine

The only thing that is broken is the DASL search, anyone care to take  
a look at that? I have tried debugging but my knowledge of the  
insides of Slide is limited. HELP?

It seems that the DASL search actually does find results but the  
URI's it's passing to the store to fetch is not valid?
That is my guess since debugging retrieveObject(Uri uri) from the  
NodeStore interface got some Uri objects that pointed to real images  
found in Slide except their URI's had " /UURI:" prefixed to them!

The stacktrace I get using txfile store is:

org.apache.slide.structure.ObjectNotFoundException: No object found  
at /UURI:
	at  
org.apache.slide.store.txfile.AbstractXMLResourceDescriptor.retrieveObje 
ct(AbstractXMLResourceDescriptor.java:296)
	at  
org.apache.slide.store.txfile.TxXMLFileDescriptorsStore.retrieveObject 
(TxXMLFileDescriptorsStore.java:104)
	at org.apache.slide.store.AbstractStore.retrieveObject 
(AbstractStore.java:699)
	at org.apache.slide.store.ExtendedStore.retrieveObject 
(ExtendedStore.java:605)
	at org.apache.slide.structure.StructureImpl.retrieve 
(StructureImpl.java:207)
	at org.apache.slide.content.ContentImpl.retrieve(ContentImpl.java:155)
	at org.apache.slide.search.basic.ComparableResourceImpl.<init> 
(ComparableResourceImpl.java:166)
	at org.apache.slide.search.basic.ComparableResourceImpl.<init> 
(ComparableResourceImpl.java:137)
	at  
org.apache.slide.index.lucene.expressions.AbstractLuceneExpression.creat 
eResource(AbstractLuceneExpression.java:354)
	at  
org.apache.slide.index.lucene.expressions.AbstractLuceneExpression.execu 
te(AbstractLuceneExpression.java:250)
	at  
org.apache.slide.index.lucene.expressions.AbstractLuceneExpression.execu 
te(AbstractLuceneExpression.java:116)
	at org.apache.slide.search.basic.BasicQueryImpl.execute 
(BasicQueryImpl.java:134)
	at org.apache.slide.search.basic.BasicQueryEnvelope.execute 
(BasicQueryEnvelope.java:214)
	at org.apache.slide.search.SearchImpl.search(SearchImpl.java:116)
	at org.apache.slide.webdav.method.SearchMethod.executeRequest 
(SearchMethod.java:230)
	at  
org.apache.slide.webdav.method.AbstractWebdavMethod.executeRedirect 
(AbstractWebdavMethod.java:583)
	at org.apache.slide.webdav.method.AbstractWebdavMethod.run 
(AbstractWebdavMethod.java:416)
	at org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java: 
151)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
	at com.idega.servlet.ServletWrapper.service(ServletWrapper.java:174)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter 
(ApplicationFilterChain.java:237)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter 
(ApplicationFilterChain.java:157)
	at  
com.idega.slide.authentication.IWSlideAuthenticator.doAuthentication 
(IWSlideAuthenticator.java:159)
...
	at java.lang.Thread.run(Thread.java:552)
20 Mar 2007 18:19:47 - org.apache.slide.common.Domain - WARNING - No  
object found at /UURI:
20 Mar 2007 18:19:47 - org.apache.slide.common.Domain - WARNING - No  
object found at /UURI:

Best Regards

Eirikur S. Hrafnsson, eiki@idega.is
Chief Software Engineer
Idega Software
http://www.idega.com



On Mar 20, 2007, at 10:19 AM, Eirikur Hrafnsson wrote:

> Thanks for the quick reply Greg :)
>
> From what I've gathered with searching for Slide and HTTPClient 3.0  
> and what we tried in the past the DASL search didn't work.
> Does it work for you?
>
> cheers
> Eiki
>
>
> On Mar 19, 2007, at 6:18 PM, Greg Schueler wrote:
>
>> Hi Eirikur,
>>
>> We've built slide against HttpClient 3.0.1, and it seems to work,  
>> aside from
>> that problem that I sent in the patch for.
>>
>> We have only tested the Ant tasks a bit, but so far they appear to  
>> work.
>> (put, delete, mkcol, get)
>>
>> I'd be interested to hear your results with it if you decided to  
>> try it
>> again.
>>
>> Thanks,
>> Greg Schueler
>>
>> On 3/19/07, Eirikur Hrafnsson <ei...@idega.is> wrote:
>>>
>>> Question for Slide developers or someone who knows...
>>>
>>> a while ago we tested HttpClient 3.0 with Slide (HEAD) and it didn't
>>> work. Does it work now?
>>>
>>> We are unfortunately forced to use HttpClient 3.0 so I really hope
>>> the answer is yes and I only have to rebuild our jar. (we use an
>>> older version from HEAD today)
>>>
>>> Best Regards
>>>
>>> Eirikur S. Hrafnsson, eiki@idega.is
>>> Chief Software Engineer
>>> Idega Software
>>> http://www.idega.com
>>>
>>>
>>>
>>> On Mar 15, 2007, at 10:24 PM, Antoine Levy-Lambert wrote:
>>>
>>> > Hello Greg,
>>> >
>>> > thanks for your patch. Will work on it.
>>> >
>>> > Antoine
>>> > -------- Original-Nachricht --------
>>> > Datum: Thu, 15 Mar 2007 15:18:27 -0700
>>> > Von: "Greg Schueler" <gr...@controltier.com>
>>> > An: antoine@apache.org, "Anthony Shortland"
>>> > <an...@controltier.com>, "dev@controltier.com"  
>>> <de...@controltier.com>
>>> > CC:
>>> > Betreff: patch for Slide Ant tasks and commons httpclient 3.0
>>> >
>>> >> Hi Antoine,
>>> >>
>>> >> re: Slide with commons httpclient 3.0
>>> >> http://issues.apache.org/bugzilla/show_bug.cgi?id=35213
>>> >>
>>> >>
>>> >> I was able to compile Slide against commons httpclient 3.0, but
>>> >> ran into
>>> >> one
>>> >> bug when using the Ant tasks for slide.  Using the Put task fails
>>> >> because
>>> >> httpclient 3.0 throws an exception:
>>> >>
>>> >> java.lang.IllegalArgumentException : Entity enclosing requests
>>> >> cannot be
>>> >> redirected without user intervention
>>> >>         at
>>> >>  
>>> org.apache.commons.httpclient.methods.EntityEnclosingMethod.setFollo 
>>> w
>>> >> Redirects
>>> >> (EntityEnclosingMethod.java:221)
>>> >>         at org.apache.webdav.ant.Utils.putFile (Utils.java:272)
>>> >>         at org.apache.webdav.ant.taskdefs.Put.uploadFile 
>>> (Put.java:
>>> >> 345)
>>> >>
>>> >> The attached patch for Utils.java fixes this problem.  I'm not
>>> >> familiar
>>> >> with
>>> >> the DAV spec (specifically wrt redirects during a PUT  
>>> operation), but
>>> >> httpclient 3.0 references the HTTP 1.1 RFC so I can't imagine  
>>> that
>>> >> DAV
>>> >> goes
>>> >> against that RFC.
>>> >>
>>> >> We are hoping to use Slide with httpclient 3.0 in our software,
>>> >> especially
>>> >> via the Ant tasks, so we do look forward to having a release
>>> >> version of
>>> >> slide with that support (rather than building from source  
>>> ourselves).
>>> >>
>>> >> Thanks!
>>> >> Greg
>>> >>
>>> >> Index: webdavclient/ant/src/java/org/apache/webdav/ant/Utils.java
>>> >>  
>>> ===================================================================
>>> >> --- webdavclient/ant/src/java/org/apache/webdav/ant/Utils.java
>>> >> (revision
>>> >> 518395)
>>> >> +++ webdavclient/ant/src/java/org/apache/webdav/ant/Utils.java
>>> >> (working
>>> >> copy)
>>> >> @@ -269,7 +269,7 @@
>>> >>        generateIfHeader(put, lockToken);
>>> >>        put.setRequestHeader("Content-Type", contentType);
>>> >>        put.setRequestBody(is);
>>> >> -      put.setFollowRedirects(true);
>>> >> +      put.setFollowRedirects(false);
>>> >>        int status = client.executeMethod(put);
>>> >>        switch (status) {
>>> >>           case WebdavStatus.SC_OK:
>>> >> --
>>> >> Greg
>>> >
>>> >  
>>> -------------------------------------------------------------------- 
>>> -
>>> > To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
>>> > For additional commands, e-mail: slide-dev-help@jakarta.apache.org
>>> >
>>>
>>>
>>>
>>>
>>>
>>
>>
>> -- 
>> Greg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: slide-dev-help@jakarta.apache.org
>






---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org