[Mulgara-general] Lucene question

David Smith DMS at viewpointusa.com
Tue Jun 17 14:29:16 UTC 2008


The Lucene resolver seems to work,  we're still learning how it's
intended to be used.
Searching works ok, within what appears to be the way Lucene wants to
work 
 
But we have 2 issues:
 
1) deletes don't work, 
    we're getting an error "Lock obtain timed out" when we try to
delete.
    Has anyone else observed this?
 
2) droping the model doesn;t delete the indexes
    Is this by design? 
    (I could se this being the case if Mulgara was looking over the
shoulder of another app that uses Lucene... but it seems odd from an all
mulgara application)
 
 
Thanks
 
Dave Smith
Viewpoint
 
 
====================================
 
the sequence for the delete problem goes something like:
 
====================================

create <rmi://localhost/server1#sampledata> ;
 
#load the same sample data as in the Mulgara Viewer pulldowns
#
load <jar:file:/C:/Mulgara/dist/mulgara-1.2.1.jar!/data/w3c-news.rss>
into <rmi://localhost/server1#sampledata>;
 
create <rmi://localhost/server1#fulltext>
<http://mulgara.org/mulgara#LuceneModel
<http://mulgara.org/mulgara#LuceneModel> > ;
 
#add some data to the fulltext model
#
insert select $s $p $o
  from <rmi://localhost/server1#sampledata>
  where 
   
   ( 
    $p <http://mulgara.org/mulgara#is <http://mulgara.org/mulgara#is> >
<http://purl.org/rss/1.0/title <http://purl.org/rss/1.0/title> > or
    $p <http://mulgara.org/mulgara#is <http://mulgara.org/mulgara#is> >
<http://purl.org/rss/1.0/description
<http://purl.org/rss/1.0/description> >  
   )
   and 
    $s $p $o 
    
  into <rmi://localhost/server1#fulltext>
;
 

select $s $p $o
from <rmi://localhost/server1#sampledata>
where
$s $p $o and
$s $p 'profile' in <rmi://localhost/server1#fulltext>
;
 
#
# 2 "rows" returned OK
#
 
delete
 select $s $p $o
 from <rmi://localhost/server1#sampledata>
 where
 $s $p $o and
 $s $p 'profile' in <rmi://localhost/server1#fulltext>
from <rmi://localhost/server1#fulltext>
;
 
#
# unable to modify...
#

====
 
log shows 
 
2008-06-17 09:32:51,333 [main] -
org.mulgara.resolver.lucene.LuceneResolverFactory - Creating Lucene
resolver factory
2008-06-17 09:32:51,333 [main] -
org.mulgara.resolver.lucene.LuceneResolverFactory - Creating Lucene
resolver factory
2008-06-17 09:33:33,313 [main] - org.mortbay.http.HttpContext - Delete
existing temp dir
C:\DOCUME~1\DMS~1.VIE\LOCALS~1\Temp\Jetty_localhost_8080__webui for
WebApplicationContext[/webui,jar:file:/C:/Mulgara/dist/mulgara-1.2.1.jar
!/webapps/webui.war]
2008-06-17 09:34:20,251 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolverFactory - Creating Lucene
resolver
2008-06-17 09:34:20,251 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolverFactory - Creating Lucene
resolver
2008-06-17 09:34:20,251 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolver - Resolve [$s $p qn1 gn28]
2008-06-17 09:34:20,251 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolver - Resolve [$s $p qn1 gn28]
2008-06-17 09:34:20,411 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Initialization of
FullTextStringIndex to directory to C:\Mulgara\dist\server1\lucene\28
2008-06-17 09:34:20,411 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Initialization of
FullTextStringIndex to directory to C:\Mulgara\dist\server1\lucene\28
2008-06-17 09:34:20,411 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexWriter and IndexReader (deletions):
org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\lucene\28
<mailto:org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\luce
ne\28> 
2008-06-17 09:34:20,411 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexWriter and IndexReader (deletions):
org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\lucene\28
<mailto:org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\luce
ne\28> 
2008-06-17 09:34:20,441 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexSearcher
2008-06-17 09:34:20,441 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexSearcher
2008-06-17 09:34:20,441 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
string pool indexes to disk
2008-06-17 09:34:20,441 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
string pool indexes to disk
2008-06-17 09:34:20,441 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
index at C:\Mulgara\dist\server1\lucene\28 please wait...
2008-06-17 09:34:20,441 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
index at C:\Mulgara\dist\server1\lucene\28 please wait...
2008-06-17 09:34:20,471 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Fulltext string index
initialized
2008-06-17 09:34:20,471 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Fulltext string index
initialized
2008-06-17 09:34:20,481 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndexTuples - Searching for
null : null : profile
2008-06-17 09:34:20,481 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndexTuples - Searching for
null : null : profile
2008-06-17 09:34:20,481 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Searching the fulltext
string index pool with  subject :null predicate :null literal :profile
2008-06-17 09:34:20,481 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Searching the fulltext
string index pool with  subject :null predicate :null literal :profile
2008-06-17 09:34:20,531 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Searching the fulltext
string index pool with parsed query as +profile
2008-06-17 09:34:20,531 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Searching the fulltext
string index pool with parsed query as +profile
2008-06-17 09:34:20,541 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Got hits: 2
2008-06-17 09:34:20,541 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Got hits: 2
2008-06-17 09:34:20,591 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolver - Modify URL model 28
2008-06-17 09:34:20,591 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolver - Modify URL model 28
2008-06-17 09:34:20,601 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Initialization of
FullTextStringIndex to directory to C:\Mulgara\dist\server1\lucene\28
2008-06-17 09:34:20,601 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Initialization of
FullTextStringIndex to directory to C:\Mulgara\dist\server1\lucene\28
2008-06-17 09:34:20,601 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexWriter and IndexReader (deletions):
org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\lucene\28
<mailto:org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\luce
ne\28> 
2008-06-17 09:34:20,601 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexWriter and IndexReader (deletions):
org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\lucene\28
<mailto:org.apache.lucene.store.FSDirectory at C:\Mulgara\dist\server1\luce
ne\28> 
2008-06-17 09:34:20,611 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexSearcher
2008-06-17 09:34:20,611 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Opening index for
IndexSearcher
2008-06-17 09:34:20,611 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
string pool indexes to disk
2008-06-17 09:34:20,611 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
string pool indexes to disk
2008-06-17 09:34:20,611 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
index at C:\Mulgara\dist\server1\lucene\28 please wait...
2008-06-17 09:34:20,611 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Optimizing fulltext
index at C:\Mulgara\dist\server1\lucene\28 please wait...
2008-06-17 09:34:20,621 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Fulltext string index
initialized
2008-06-17 09:34:20,621 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Fulltext string index
initialized
2008-06-17 09:34:20,621 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolver - Deleting
http://www.w3.org/News/2002#item14 <http://www.w3.org/News/2002#item14>
http://purl.org/rss/1.0/title <http://purl.org/rss/1.0/title>
XHTML+SMIL Profile Published
2008-06-17 09:34:20,621 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.LuceneResolver - Deleting
http://www.w3.org/News/2002#item14 <http://www.w3.org/News/2002#item14>
http://purl.org/rss/1.0/title <http://purl.org/rss/1.0/title>
XHTML+SMIL Profile Published
2008-06-17 09:34:21,623 [RMI TCP Connection(4)-192.168.80.80] -
org.mulgara.resolver.lucene.FullTextStringIndex - Unable to delete the
string '1028003055097080231694042652'
java.io.IOException: Lock obtain timed out:
Lock at C:\DOCUME~1\DMS~1.VIE\LOCALS~1\Temp\lucene-31f1966fa42ca6356502c978
3703dc0c-write.lock
<mailto:Lock at C:\DOCUME~1\DMS~1.VIE\LOCALS~1\Temp\lucene-31f1966fa42ca635
6502c9783703dc0c-write.lock> 
 at org.apache.lucene.store.Lock.obtain(Lock.java:56)
 at
org.apache.lucene.index.IndexReader.aquireWriteLock(IndexReader.java:489
)
 at
org.apache.lucene.index.IndexReader.deleteDocument(IndexReader.java:514)
 at
org.apache.lucene.index.IndexReader.deleteDocuments(IndexReader.java:541
)
 at
org.mulgara.resolver.lucene.FullTextStringIndex.remove(FullTextStringInd
ex.java:670)
 at
org.mulgara.resolver.lucene.LuceneResolver.modifyModel(LuceneResolver.ja
va:277)
 at
org.mulgara.resolver.InternalResolver.modifyModel(InternalResolver.java:
169)
 at
org.mulgara.resolver.ModifyModelOperation.doModify(ModifyModelOperation.
java:248)
 at
org.mulgara.resolver.ModifyModelOperation.execute(ModifyModelOperation.j
ava:209)
.
.
. 
 at java.lang.Thread.run(Unknown Source)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mulgara.org/pipermail/mulgara-general/attachments/20080617/dc0b3b77/attachment.htm>


More information about the Mulgara-general mailing list