-
Notifications
You must be signed in to change notification settings - Fork 9
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
update gremlin #5
Comments
I use gremlin-console-js to connect gremlin server 3.2.1 , and I meet a problem - all of the user share the same graph, one make some change against the graph will affect the otherone. How can I do to isolate everyone's data space? Looking forward to your reply. Thank U very much. |
Hey @billho Yes this is probably because you have the graph handled in the server configuration. You will need some logic to separate the spaces. The graphs are set for each individual instance by running an initial query such as : graph = TinkerFactory.createModern();
g = graph.traversal(standard()); The bindings ( You can do this with the console automatically by following the instructions in the Populating the console on init section. That is to say with : // Start an instance of gremlin-console
var gc = GremlinConsole('#console-window', '#console-input');
// Provide a history array to populate the graph
// In this case we create a modern graph "graph", with a traversal object "g".
gc.populateDbFromHistory([
{query: "graph = TinkerFactory.createModern();", error: undefined, results: [null]},
{query: "g = graph.traversal();", error: undefined, results: [null]}
]); If you want to be able to persist each user's graph between connections then you will need to add some more logic. Most likely you would create a gremlin-server plugin or use some form of partitioning. Let me know if you have any other questions. Cheers |
@PommeVerte First, I set the configuration Secondly, I initial query like that:
but , still has problem:
What's wrong ? Thank you for your help! |
Can you show me your full |
There is no errors in the browser before running queries. And the full
|
I can't find anything wrong. This is even weirder from the fact that tests seem to pass on travis. Though it tests |
OK,Thank you. And I will try |
A created PR #6 to test Specifically these two :
If trying |
Mental note to self: The |
I change to
I think that why the errors comes when I use |
Ah, does changing the timeout make it work? Or are you stil experiencing issues? |
Yes, it works . And no problem now. |
Interesting. Which browser is this? I've been meaning to set tests up for better cross browser coverage. Maybe it's time I do it. Mental note to add https://github.com/PommeVerte/gremlin-console-js/blob/master/test/ConsoleTest.js#L28-L41 to indexTest.js |
Chrome v52.0.2743.116 m |
Don't need to use master anymore. Can update simply which will prevent having to generate the lib.
The text was updated successfully, but these errors were encountered: