orient_db_client icon indicating copy to clipboard operation
orient_db_client copied to clipboard

Updated for protocol version 12

Open jhstatewide opened this issue 13 years ago • 7 comments

I've updated the library for version 12... let me know what you think

jhstatewide avatar Nov 05 '12 02:11 jhstatewide

Which version of OrientDB did you develop against? I'm getting integration test failures in version 1.1.0 and mismatches in protocol expectations in version 1.2.0.

I noticed that you modified several tests. Were you testing against a fresh install of OrientDB, or did you modify some of its internal data before doing your testing?

beverlycodes avatar Nov 05 '12 06:11 beverlycodes

This is based off stock 1.3 database. I more or less clobbered the version 9 stuff but I could implement it as extensions to 9, similar to what you did in relation from version 7 to 9.

On version 1.3 all unit tests pass except for one which receives a heap error. I am hoping to determine the cause and push a fix. I have every intent of implementing all new version capabilities.

I have great interest in your library and I have begun implementing an object relational library which I'd like to share soon.

Ryan Fields [email protected] wrote:

Which version of OrientDB did you develop against? I'm getting integration test failures in version 1.1.0 and mismatches in protocol expectations in version 1.2.0.

I noticed that you modified several tests. Were you testing against a fresh install of OrientDB, or did you modify some of its internal data before doing your testing?

— Reply to this email directly or view it on GitHub.

jhstatewide avatar Nov 05 '12 13:11 jhstatewide

I'm not seeing an OrientDB download for 1.3. Did you build it from source?

There is a lot of reorganizing I want to do with the code, but I'd still like to continue the trend of building up each protocol as an extension of the previous. While I don't believe there are many users of this gem, I don't want to break backward compatibility yet without a really compelling reason. I pulled your changes into a branch on my local machine to review them and merge. I put Protocol9 back in, so you don't need to worry about dealing with that.

As soon as I can get the tests passing, I'll merge into master and bump the gem version. If you have any luck resolving the heap dump, let me know. It happens on Orient 1.1 and 1.2 as well, so resolving it on any version is likely to resolve it for all.

beverlycodes avatar Nov 06 '12 04:11 beverlycodes

Yes. Originally I was using the stable version downloaded from their site but then I had an issue ( http://code.google.com/p/orient/issues/detail?id=949&start=100)

After some digging this was revealed to be solved in latest version from svn.

To reproduce my results from clean build....

Install ant, jdk, etc.

svn checkout http://orient.googlecode.com/svn/trunk/ orient-read-only

cd orient-read-only/trunk

ant install

(this will yield ../releases which has binary dist)

cd ../releases/ORIENTDB-1.3-RELEASE/bin

(customize configuration of orientdb server for root password, bind IP etc..)

bash ./server.sh

After that the unit tests will pass (except for the aforementioned heap problem)

This implements version 12 of the protocol.

Don't worry about "not many users" because I think this gem is great and it's been interesting to work with OrientDB/Ruby.

On 11/05/2012 11:18 PM, Ryan Fields wrote:

I'm not seeing an OrientDB download for 1.3. Did you build it from source?

There is a lot of reorganizing I want to do with the code, but I'd still like to continue the trend of building up each protocol as an extension of the previous. While I don't believe there are many users of this gem, I don't want to break backward compatibility yet without a really compelling reason. I pulled your changes into a branch on my local machine to review them and merge. I put Protocol9 back in, so you don't need to worry about dealing with that.

As soon as I can get the tests passing, I'll merge into master and bump the gem version. If you have any luck resolving the heap dump, let me know. It happens on Orient 1.1 and 1.2 as well, so resolving it on any version is likely to resolve it for all.

— Reply to this email directly or view it on GitHub https://github.com/ryanfields/orient_db_client/pull/5#issuecomment-10098774.

jhstatewide avatar Nov 06 '12 22:11 jhstatewide

josh@inspiron620mt:~/orient_db_client$ rake test:integration /home/josh/.rvm/rubies/ruby-1.9.3-p194/bin/ruby -I"lib:lib" -I"/home/josh/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib" "/home/josh/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb" "test/integration/connection_test.rb" "test/integration/database_session_12_test.rb" "test/integration/database_session_test.rb" "test/integration/open_database_test.rb" "test/integration/open_server_test.rb" "test/integration/server_session_test.rb" Run options: --seed 10171

Running tests:

...................S.. Finished tests in 3.343591s, 6.5798 tests/s, 17.3466 assertions/s.

22 tests, 58 assertions, 0 failures, 0 errors, 1 skips

All unit tests passing now.... killed several bugs regarding protocol 12 implementation....

jhstatewide avatar Nov 11 '12 19:11 jhstatewide

I'm having trouble opening databases on the 1.3.0-SNAPSHOT (downloaded here: oss.sonatype.org/content/repositories/snapshots/com/orientechnologies/orientdb/1.3.0-SNAPSHOT/). I'd like to fix it but I don't enough knowledge of the NetworkBinaryProtocol to figure out what's wrong. Any tips?

davide avatar Nov 21 '12 02:11 davide

A good way to debug the NetworkBinary protocol is to reference http://code.google.com/p/orient/wiki/NetworkBinaryProtocol#Enable_debug_messages_on_protocol

This will print out Orient's activity relating to binary input / output. Using this method I was able to do a great deal of work with the library.

jhstatewide avatar Nov 21 '12 16:11 jhstatewide