large_object_store 1.6.0 → 1.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/large_object_store/version.rb +1 -1
- data/lib/large_object_store.rb +3 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a72748e1b76afaf0bf1f32ffddba01354405a7fd0d41ee5bdf5a29180259c5d8
|
4
|
+
data.tar.gz: e16591860fd1542d994d49ace89c3f759f00c641c1566d780e6d3fc93afcb258
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0c0878955ba7c92f6fdbdfa9c25c2f8c4b6ef441863940732c804076d423f53a8d1a40aae7f06544a15779b81a7225ec367b65caa3e16a4c49c07952a5363c24
|
7
|
+
data.tar.gz: 3d7c5fdc351ae6c0170ce41cf58696d08d2c1493e35324252ccd49511d977f1880ea00acfddfef741e4977feb201ac052a1270a743c5037befb57ba44edbbcaf
|
data/lib/large_object_store.rb
CHANGED
@@ -38,7 +38,9 @@ module LargeObjectStore
|
|
38
38
|
|
39
39
|
# calculate slice size; note that key length is a factor because
|
40
40
|
# the key is stored on the same slab page as the value
|
41
|
-
|
41
|
+
namespace = (store.respond_to?(:options) && store.options[:namespace]) || ""
|
42
|
+
namespace_length = namespace.empty? ? 0 : namespace.size + 1
|
43
|
+
slice_size = MAX_OBJECT_SIZE - ITEM_HEADER_SIZE - UUID_SIZE - key.bytesize - namespace_length
|
42
44
|
|
43
45
|
# store number of pages
|
44
46
|
pages = (value.size / slice_size.to_f).ceil
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: large_object_store
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ana Martinez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-01-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: zstd-ruby
|
@@ -52,7 +52,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
52
52
|
- !ruby/object:Gem::Version
|
53
53
|
version: '0'
|
54
54
|
requirements: []
|
55
|
-
rubygems_version: 3.
|
55
|
+
rubygems_version: 3.5.3
|
56
56
|
signing_key:
|
57
57
|
specification_version: 4
|
58
58
|
summary: Store large objects in memcache or others
|