odba 1.0.2 → 1.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +4 -0
- data/lib/odba.rb +1 -1
- data/lib/odba/cache.rb +1 -1
- data/test/test_cache.rb +4 -5
- metadata +4 -11
data/History.txt
CHANGED
data/lib/odba.rb
CHANGED
data/lib/odba/cache.rb
CHANGED
@@ -398,7 +398,7 @@ module ODBA
|
|
398
398
|
# Returns the next valid odba_id
|
399
399
|
def next_id
|
400
400
|
#id = ODBA.storage.next_id
|
401
|
-
dbname = ODBA.storage.dbi.dbi_args.first.split(/:/).last
|
401
|
+
dbname = ODBA.storage.instance_variable_get('@dbi').dbi_args.first.split(/:/).last
|
402
402
|
id = new_id(dbname, ODBA.storage)
|
403
403
|
@peers.each do |peer|
|
404
404
|
peer.reserve_next_id id rescue DRb::DRbError
|
data/test/test_cache.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
2
|
# encoding: utf-8
|
3
|
-
# ODBA::TestCache -- odba --
|
3
|
+
# ODBA::TestCache -- odba -- 09.12.2011 -- mhatakeyama@ywesee.com
|
4
4
|
|
5
5
|
$: << File.dirname(__FILE__)
|
6
6
|
$: << File.expand_path('../lib/', File.dirname(__FILE__))
|
@@ -626,10 +626,9 @@ module ODBA
|
|
626
626
|
@storage.should_receive(:restore_collection).with(Integer)\
|
627
627
|
.times(2).and_return([])
|
628
628
|
dbi = flexmock('dbi', :dbi_args => ['dbi_args'])
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
)
|
629
|
+
@storage.should_receive(:instance_variable_get).and_return(dbi)
|
630
|
+
@storage.should_receive(:update_max_id)
|
631
|
+
flexmock(@storage, :max_id => 'max_id')
|
633
632
|
@marshal.should_receive(:load).with('dump1')\
|
634
633
|
.times(1).and_return(o4)
|
635
634
|
@cache.fetched.store(1, ODBA::CacheEntry.new(o1))
|
metadata
CHANGED
@@ -1,13 +1,12 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: odba
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
prerelease:
|
4
|
+
prerelease: false
|
6
5
|
segments:
|
7
6
|
- 1
|
8
7
|
- 0
|
9
|
-
-
|
10
|
-
version: 1.0.
|
8
|
+
- 3
|
9
|
+
version: 1.0.3
|
11
10
|
platform: ruby
|
12
11
|
authors:
|
13
12
|
- Masaomi Hatakeyama, Zeno R.R. Davatz
|
@@ -22,11 +21,9 @@ dependencies:
|
|
22
21
|
name: hoe
|
23
22
|
prerelease: false
|
24
23
|
requirement: &id001 !ruby/object:Gem::Requirement
|
25
|
-
none: false
|
26
24
|
requirements:
|
27
25
|
- - ">="
|
28
26
|
- !ruby/object:Gem::Version
|
29
|
-
hash: 41
|
30
27
|
segments:
|
31
28
|
- 2
|
32
29
|
- 9
|
@@ -97,27 +94,23 @@ rdoc_options:
|
|
97
94
|
require_paths:
|
98
95
|
- lib
|
99
96
|
required_ruby_version: !ruby/object:Gem::Requirement
|
100
|
-
none: false
|
101
97
|
requirements:
|
102
98
|
- - ">="
|
103
99
|
- !ruby/object:Gem::Version
|
104
|
-
hash: 3
|
105
100
|
segments:
|
106
101
|
- 0
|
107
102
|
version: "0"
|
108
103
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
109
|
-
none: false
|
110
104
|
requirements:
|
111
105
|
- - ">="
|
112
106
|
- !ruby/object:Gem::Version
|
113
|
-
hash: 3
|
114
107
|
segments:
|
115
108
|
- 0
|
116
109
|
version: "0"
|
117
110
|
requirements: []
|
118
111
|
|
119
112
|
rubyforge_project: odba
|
120
|
-
rubygems_version: 1.
|
113
|
+
rubygems_version: 1.3.6
|
121
114
|
signing_key:
|
122
115
|
specification_version: 3
|
123
116
|
summary: Object Database Access - Ruby Software for ODDB.org Memory Management
|