Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move AwaitGraphIndex and UpdateIndex out of Index builders #94

Closed
debasishdebs opened this issue Sep 28, 2018 · 0 comments
Closed

Move AwaitGraphIndex and UpdateIndex out of Index builders #94

debasishdebs opened this issue Sep 28, 2018 · 0 comments

Comments

@debasishdebs
Copy link
Owner

Now, when a Index query is build to create an Index, the set of queries being submitted to Server contains queries for

  • Creating Index.

  • Await till Graph Index is in Installed state.

  • Update Index into existing data.

We need to move the last 2 points, i.e. awaitGraphIndex and updateIndex out of Index builder so that user can invoke it based on their needs. Like UpdateIndex isn't required if the schema loading is first thing being done on graph.

The syntax to be followed would be:

graph = JanusGraph().connect()
mgmt = graph.openManagement()

index_builder = mgmt.buildCompositeIndex("indexName", "Vertex")
index_builder.addKey("prop1").addKey("prop2").indexOnly("label1").unique().make()

mgmt.awaitGraphIndex("indexName").make()

mgmt.updateIndex("indexName").make()
debasishdebs added a commit that referenced this issue Sep 28, 2018
…sing just the the name of property and label for mixed index.

Cleaned code and mixed index builder now takes element.

fixes #94

Signed-off-by: Debasish Kanhar <dekanhar@in.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant