mdbx 0.3.3 → 0.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7a961296e49a7e0e0fee9afbe7d2b92144a23b6295d68c3fc10d2296d5421666
4
- data.tar.gz: 29fd9c1997cb4a6bd6d1f7ce99ccb8cb38651ddc78e34a1a93eb21d55a552505
3
+ metadata.gz: a6ce9c7c96bb8e8857f7a6150df3ded621f5eca3d40848f52999fbe8192f72de
4
+ data.tar.gz: 8445320bae46524ae7dac00dfb9b1bc6d38c9401607a5d2d983380fa73c8d2b4
5
5
  SHA512:
6
- metadata.gz: 8d04ccf57c5cf613e930339c770acaa28c368eba2345e9b1255e0d2584f2271b9d166bdda8f55f2e27dc360315b00c41c4af7e59829f21611946fa2824975cc7
7
- data.tar.gz: f6d39a0a124cd4bfbf189f439ae765c7aec0a99eb0bc7a8b2e4b7d29141faa99a294d50b4110e0d40ac13349b22b731b2df29f8b2b4a36eb199785c0dba22043
6
+ metadata.gz: 0d062355ba32667ac5f4f1d2e6a26a977823d2b0cf841d2f0131509bd2b96f7e36eeb981e96c343a3d960ba77f23996a57f0d1dad4210c99cce9cf870d7a36ee
7
+ data.tar.gz: 2e517e62946e3005da7d5e20190c5362106253fb925c1bd97e15fc4d7fdf5a0e7c536553babb5ef9b704043f7646dbc1dc46873d9939dd85c64a665562fe0de5
checksums.yaml.gz.sig CHANGED
Binary file
data/History.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Release History for MDBX
2
2
 
3
+ ---
4
+ ## v0.3.4 [2022-12-21] Mahlon E. Smith <mahlon@martini.nu>
5
+
6
+ Bugfixes:
7
+
8
+ - Don't use mdbx_replace() when not using the original value(s)
9
+
10
+
3
11
  ---
4
12
  ## v0.3.3 [2021-10-22] Mahlon E. Smith <mahlon@martini.nu>
5
13
 
data/README.md CHANGED
@@ -2,22 +2,13 @@
2
2
  # Ruby::MDBX
3
3
 
4
4
  home
5
- : https://code.martini.nu/ruby-mdbx
6
-
7
- code
8
- : https://code.martini.nu/ruby-mdbx
5
+ : https://code.martini.nu/fossil/ruby-mdbx
9
6
 
10
7
  docs
11
8
  : https://martini.nu/docs/ruby-mdbx
12
9
 
13
- github
14
- : https://github.com/mahlon/ruby-mdbx
15
-
16
- gitlab
17
- : https://gitlab.com/mahlon/ruby-mdbx
18
-
19
- sourcehut:
20
- : https://hg.sr.ht/~mahlon/ruby-mdbx
10
+ github mirror
11
+ : https://github.com/mahlonsmith/ruby-mdbx
21
12
 
22
13
 
23
14
  ## Description
@@ -30,13 +21,13 @@ of properties and capabilities, focused on creating unique lightweight
30
21
  solutions.
31
22
 
32
23
  For more information about libmdbx (features, limitations, etc), see the
33
- [introduction](https://erthink.github.io/libmdbx/intro.html).
24
+ [introduction](https://libmdbx.dqdkfa.ru).
34
25
 
35
26
 
36
27
  ## Prerequisites
37
28
 
38
29
  * Ruby 2.6+
39
- * [libmdbx](https://github.com/erthink/libmdbx)
30
+ * [libmdbx](https://gitflic.ru/project/erthink/libmdbx)
40
31
 
41
32
 
42
33
  ## Installation
@@ -342,8 +333,8 @@ the currently connected clients.
342
333
 
343
334
  ## Contributing
344
335
 
345
- You can check out the current development source with Mercurial via its
346
- [home repo](https://code.martini.nu/ruby-mdbx), or with Git at its
336
+ You can check out the current development source with Fossil via its
337
+ [home repo](https://code.martini.nu/fossil/ruby-mdbx), or with Git at its
347
338
  [project mirror](https://gitlab.com/mahlon/ruby-mdbx).
348
339
 
349
340
  After checking out the source, run:
@@ -362,7 +353,7 @@ development.
362
353
 
363
354
  ## License
364
355
 
365
- Copyright (c) 2020-2021 Mahlon E. Smith
356
+ Copyright (c) 2020-2022 Mahlon E. Smith
366
357
  All rights reserved.
367
358
 
368
359
  Redistribution and use in source and binary forms, with or without
@@ -101,16 +101,6 @@ rmdbx_closed_p( VALUE self )
101
101
  }
102
102
 
103
103
 
104
- /*
105
- * Check if a given +flag+ is enabled for flag +val+.
106
- */
107
- int
108
- rmdbx_flag_enabled( val, flag )
109
- {
110
- return ( val & flag ) == flag;
111
- }
112
-
113
-
114
104
  /*
115
105
  * Given a ruby string +key+ and a pointer to an MDBX_val, prepare the
116
106
  * key for usage within mdbx. All keys are explicitly converted to
@@ -371,10 +361,9 @@ rmdbx_put_val( VALUE self, VALUE key, VALUE val )
371
361
  rc = mdbx_del( db->txn, db->dbi, &ckey, NULL );
372
362
  }
373
363
  else {
374
- MDBX_val old;
375
364
  MDBX_val data;
376
365
  rmdbx_val_for( self, val, &data );
377
- rc = mdbx_replace( db->txn, db->dbi, &ckey, &data, &old, 0 );
366
+ rc = mdbx_put( db->txn, db->dbi, &ckey, &data, 0 );
378
367
  xfree( data.iov_base );
379
368
  }
380
369
 
@@ -870,7 +859,7 @@ static VALUE rmdbx_init_copy( VALUE copy, VALUE orig )
870
859
  void
871
860
  rmdbx_init_database()
872
861
  {
873
- rmdbx_cDatabase = rb_define_class_under( rmdbx_mMDBX, "Database", rb_cData );
862
+ rmdbx_cDatabase = rb_define_class_under( rmdbx_mMDBX, "Database", rb_cObject );
874
863
 
875
864
  #ifdef FOR_RDOC
876
865
  rmdbx_mMDBX = rb_define_module( "MDBX" );
data/lib/mdbx/database.rb CHANGED
@@ -85,7 +85,7 @@ class MDBX::Database
85
85
  ###
86
86
  ### [:no_threadlocal]
87
87
  ### Parallelize read-only transactions across threads. Writes are
88
- ### always thread local. (See MDBX documentatoin for details.)
88
+ ### always thread local. (See MDBX documentation for details.)
89
89
  ###
90
90
  ### [:readonly]
91
91
  ### Reject any write attempts while using this database handle.
@@ -364,7 +364,6 @@ class MDBX::Database
364
364
  protected
365
365
  #########
366
366
 
367
-
368
367
  ### Safely serialize a value, closing any open transaction and re-raising
369
368
  ### if necessary.
370
369
  ###
@@ -391,7 +390,6 @@ class MDBX::Database
391
390
  end
392
391
 
393
392
 
394
-
395
393
  ### Yield and return the block, opening a snapshot first if
396
394
  ### there isn't already a transaction in progress. Closes
397
395
  ### the snapshot if this method opened it.
data/lib/mdbx.rb CHANGED
@@ -13,7 +13,7 @@ module MDBX
13
13
  extend Loggability
14
14
 
15
15
  # The version of this gem.
16
- VERSION = '0.3.3'
16
+ VERSION = '0.3.4'
17
17
 
18
18
 
19
19
  log_as :mdbx
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mdbx
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.3.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mahlon E. Smith
@@ -34,7 +34,7 @@ cert_chain:
34
34
  49pOzX5KHZLTS9DKeaP/xcGPz6C8MiwQdYrZarr2SHRASX1zFa79rkItO8kE6RDr
35
35
  b6WDF79UvZ55ajtE00TiwqjQL/ZPEtbd
36
36
  -----END CERTIFICATE-----
37
- date: 2021-10-22 00:00:00.000000000 Z
37
+ date: 2022-12-21 00:00:00.000000000 Z
38
38
  dependencies:
39
39
  - !ruby/object:Gem::Dependency
40
40
  name: loggability
@@ -206,14 +206,13 @@ files:
206
206
  - ext/mdbx_ext/stats.c
207
207
  - lib/mdbx.rb
208
208
  - lib/mdbx/database.rb
209
- homepage: https://code.martini.nu/ruby-mdbx
209
+ homepage: https://code.martini.nu/fossil/ruby-mdbx
210
210
  licenses:
211
211
  - BSD-3-Clause
212
212
  metadata:
213
- homepage_uri: https://code.martini.nu/ruby-mdbx
213
+ homepage_uri: https://code.martini.nu/fossil/ruby-mdbx
214
214
  documentation_uri: https://martini.nu/docs/ruby-mdbx
215
215
  changelog_uri: https://martini.nu/docs/ruby-mdbx/History_md.html
216
- source_uri: https://code.martini.nu/ruby-mdbx
217
216
  post_install_message:
218
217
  rdoc_options: []
219
218
  require_paths:
@@ -229,7 +228,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
229
228
  - !ruby/object:Gem::Version
230
229
  version: '0'
231
230
  requirements: []
232
- rubygems_version: 3.1.4
231
+ rubygems_version: 3.3.7
233
232
  signing_key:
234
233
  specification_version: 4
235
234
  summary: A ruby binding to libmdbx, an improved version of the Lightning Memory Mapped
metadata.gz.sig CHANGED
Binary file