[ 
https://issues.apache.org/jira/browse/DERBY-590?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rick Hillegas updated DERBY-590:
--------------------------------

    Attachment: derby-590-13-aa-indexViews.diff

Attaching derby-590-13-aa-indexViews.diff. This patch adds support for creating 
Lucene indexes on arbitrary views.

In order to index a view, you must supply a list of columns which will be 
treated as a key. I could not think of any reason to avoid sharing this 
capability with tables too. So now you can index a table which doesn't have a 
primary key. If you omit the key columns, then we try to find a primary key; 
and we raise an error if we can't find one.

You do not supply key columns when you update a Lucene index, however. Instead, 
the plugin looks up the existing key information for the table function.

Errors can, of course, occur if you drop a key column from the table. If you do 
this, you will get an error when you try to select from the Lucene index; that 
is because we still check to see if you have SELECT privilege on the missing 
column.

This raises an interesting defect of the plugin: Creating a Lucene index does 
not prevent you from performing DDL on the table/view which will make it 
impossible to join the Lucene index back to Derby data. You are on your own 
there.

At this point, I think that the api for the plugin is stable enough that I can 
write a first rev of a functional spec.

Touches the following files:

M       java/engine/org/apache/derby/vti/VTITemplate.java
M       java/optional/org/apache/derby/optional/lucene/LuceneSupport.java
M       
java/testing/org/apache/derbyTesting/functionTests/tests/lang/LuceneSupportPermsTest.java


> How to integrate Derby with Lucene API?
> ---------------------------------------
>
>                 Key: DERBY-590
>                 URL: https://issues.apache.org/jira/browse/DERBY-590
>             Project: Derby
>          Issue Type: Improvement
>          Components: Documentation, SQL
>            Reporter: Abhijeet Mahesh
>              Labels: derby_triage10_11
>         Attachments: derby-590-01-ag-publicAccessToLuceneRoutines.diff, 
> derby-590-01-ah-publicAccessToLuceneRoutines.diff, 
> derby-590-01-am-publicAccessToLuceneRoutines.diff, 
> derby-590-02-aa-cleanupFindbugsErrors.diff, 
> derby-590-03-aa-removeTestingDiagnostic.diff, 
> derby-590-04-aa-removeIDFromListIndexes.diff, 
> derby-590-05-aa-accessDeclaredMembers.diff, 
> derby-590-06-aa-suppressAccessChecks.diff, 
> derby-590-07-aa-accessClassInPackage.sun.misc.diff, 
> derby-590-08-aa-omitLuceneFlag.diff, 
> derby-590-09-aa-localeSensitiveAnalysis.diff, 
> derby-590-10-aa-fixLocaleTest.diff, derby-590-11-aa-moveCode.diff, 
> derby-590-12-aa-newJar.diff, derby-590-13-aa-indexViews.diff, 
> lucene_demo.diff, lucene_demo_2.diff
>
>
> In order to use derby with lucene API what should be the steps to be taken? 



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to