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

[orientdb] Added remote connection capabilties #581

Merged
merged 1 commit into from
Jan 17, 2016

Conversation

kruthar
Copy link
Collaborator

@kruthar kruthar commented Jan 12, 2016

Had to implement a separate init path for remote connections using OServerAdmin. The old, local init path is essentially the same as before.

OrientDB does not support the iterator methods that scan is built off of for remote connections, so had to check for that and record NOT_IMPLEMENTED. Made a note of that in the README as well.

* Default: ```false```
* ```orientdb.remote.storagetype``` - Storage type of the database on remote server
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is surprising.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, a remote connection can be used to connect to a long living plocal or memory database on the server. Memory databases stored on the server don't die like local memory databases do. This being the case you could have two databases with the same name but different types, and so when doing any administration of remote databases you have to know the storage type.

@@ -46,6 +49,7 @@
private static final String CLASS = "usertable";
protected ODatabaseDocumentTx db;
private ODictionary<ORecord> dictionary;
private boolean isRemote = false;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this default to true since other bindings default to remote?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whether or not the connection is a remote connection is purely dependent on the url provided by the user, so really there is not default. isRemote is defaulted to false because it is only set to true if the user provides a remote connection url, in any other case (user provides a local url) it should be false.

@kruthar
Copy link
Collaborator Author

kruthar commented Jan 12, 2016

Made a few edits:

  • Added a note in README about newdb
  • No longer honoring newdb if in the transaction phase. Had to modify core to push the dotransactions property to the workload as that information wasn't currently available downstream.
  • Propagating DBExceptions in init()
  • Found it unnecessary to split the url, no just passing the server url which is safer.

@risdenk
Copy link
Collaborator

risdenk commented Jan 13, 2016

Looks good to me.

@busbey
Copy link
Collaborator

busbey commented Jan 15, 2016

+1

busbey added a commit that referenced this pull request Jan 17, 2016
[orientdb] Added remote connection capabilties
@busbey busbey merged commit a02649b into brianfrankcooper:master Jan 17, 2016
@kruthar kruthar deleted the orientdb-remote branch January 18, 2016 13:51
@risdenk risdenk mentioned this pull request Feb 15, 2016
jaricftw pushed a commit to jaricftw/YCSB that referenced this pull request Jul 19, 2016
[orientdb] Added remote connection capabilties
jaricftw pushed a commit to jaricftw/YCSB that referenced this pull request Jul 19, 2016
[orientdb] Added remote connection capabilties
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

Successfully merging this pull request may close these issues.

3 participants