riakpb 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +1 -1
- data/lib/riak/riak_content.rb +8 -6
- data/lib/riak.rb +1 -1
- data/spec/riak/bucket_spec.rb +0 -13
- data/spec/riak/client_spec.rb +0 -13
- data/spec/riak/riak_content_spec.rb +0 -13
- data/spec/riak/rpc_spec.rb +0 -13
- metadata +2 -2
data/README.rdoc
CHANGED
@@ -47,7 +47,7 @@ This is a work in progress and I am current improving the rspec and the document
|
|
47
47
|
>> bucket = client["goog"]
|
48
48
|
=> #<Riak::Bucket name=goog, props={n_val=>3, allow_mult=false}>
|
49
49
|
>> bucket.keys
|
50
|
-
=> ["2010-05-03", "2010-03-24", "2010-03-05", "2010-02-25",
|
50
|
+
=> ["2010-05-03", "2010-03-24", "2010-03-05", "2010-02-25", <<SNIP>>, "2005-02-10", "2005-01-04"]
|
51
51
|
|
52
52
|
=== Fetch a Key:
|
53
53
|
|
data/lib/riak/riak_content.rb
CHANGED
@@ -157,12 +157,14 @@ module Riak
|
|
157
157
|
raise TypeError.new t('value_empty') if @value.nil?
|
158
158
|
|
159
159
|
rpb_content = Riak::RpbContent.new
|
160
|
+
rpb_links = []
|
160
161
|
|
161
|
-
links
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
162
|
+
@links.each do |tag, links|
|
163
|
+
links.each do |link|
|
164
|
+
pb_link = link.to_pb_link
|
165
|
+
pb_link.tag = tag
|
166
|
+
rpb_links << pb_link
|
167
|
+
end
|
166
168
|
end
|
167
169
|
|
168
170
|
usermeta = []
|
@@ -191,7 +193,7 @@ module Riak
|
|
191
193
|
rpb_content.charset = @charset unless @charset.nil? # || @charset.empty?
|
192
194
|
rpb_content.content_encoding = @content_encoding unless @content_encoding.nil? # || @content_encoding.empty?
|
193
195
|
rpb_content.vtag = @vtag unless @vtag.nil?
|
194
|
-
rpb_content.links =
|
196
|
+
rpb_content.links = rpb_links unless rpb_links.empty?
|
195
197
|
rpb_content.usermeta = usermeta unless usermeta.empty?
|
196
198
|
|
197
199
|
return(rpb_content)
|
data/lib/riak.rb
CHANGED
data/spec/riak/bucket_spec.rb
CHANGED
@@ -1,16 +1,3 @@
|
|
1
|
-
# Copyright 2010 Sean Cribbs, Sonian Inc., and Basho Technologies, Inc.
|
2
|
-
#
|
3
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
# you may not use this file except in compliance with the License.
|
5
|
-
# You may obtain a copy of the License at
|
6
|
-
#
|
7
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
-
#
|
9
|
-
# Unless required by applicable law or agreed to in writing, software
|
10
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
# See the License for the specific language governing permissions and
|
13
|
-
# limitations under the License.
|
14
1
|
require File.expand_path("../spec_helper", File.dirname(__FILE__))
|
15
2
|
|
16
3
|
describe Riak::Bucket do
|
data/spec/riak/client_spec.rb
CHANGED
@@ -1,16 +1,3 @@
|
|
1
|
-
# Copyright 2010 Sean Cribbs, Sonian Inc., and Basho Technologies, Inc.
|
2
|
-
#
|
3
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
# you may not use this file except in compliance with the License.
|
5
|
-
# You may obtain a copy of the License at
|
6
|
-
#
|
7
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
-
#
|
9
|
-
# Unless required by applicable law or agreed to in writing, software
|
10
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
# See the License for the specific language governing permissions and
|
13
|
-
# limitations under the License.
|
14
1
|
require File.expand_path("../spec_helper", File.dirname(__FILE__))
|
15
2
|
|
16
3
|
describe Riak::Client do
|
@@ -1,16 +1,3 @@
|
|
1
|
-
# Copyright 2010 Sean Cribbs, Sonian Inc., and Basho Technologies, Inc.
|
2
|
-
#
|
3
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
# you may not use this file except in compliance with the License.
|
5
|
-
# You may obtain a copy of the License at
|
6
|
-
#
|
7
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
-
#
|
9
|
-
# Unless required by applicable law or agreed to in writing, software
|
10
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
# See the License for the specific language governing permissions and
|
13
|
-
# limitations under the License.
|
14
1
|
require File.expand_path("../spec_helper", File.dirname(__FILE__))
|
15
2
|
|
16
3
|
describe Riak::RiakContent do
|
data/spec/riak/rpc_spec.rb
CHANGED
@@ -1,16 +1,3 @@
|
|
1
|
-
# Copyright 2010 Sean Cribbs, Sonian Inc., and Basho Technologies, Inc.
|
2
|
-
#
|
3
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
# you may not use this file except in compliance with the License.
|
5
|
-
# You may obtain a copy of the License at
|
6
|
-
#
|
7
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
-
#
|
9
|
-
# Unless required by applicable law or agreed to in writing, software
|
10
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
# See the License for the specific language governing permissions and
|
13
|
-
# limitations under the License.
|
14
1
|
require File.expand_path("../spec_helper", File.dirname(__FILE__))
|
15
2
|
|
16
3
|
describe Riak::Client::Rpc do
|