extralite 2.5 → 2.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (45) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/CHANGELOG.md +34 -13
  4. data/Gemfile +4 -0
  5. data/Gemfile-bundle +1 -1
  6. data/LICENSE +1 -1
  7. data/README.md +1059 -247
  8. data/Rakefile +18 -0
  9. data/TODO.md +0 -7
  10. data/examples/kv_store.rb +49 -0
  11. data/examples/multi_fiber.rb +16 -0
  12. data/examples/on_progress.rb +9 -0
  13. data/examples/pubsub_store_polyphony.rb +194 -0
  14. data/examples/pubsub_store_threads.rb +204 -0
  15. data/ext/extralite/changeset.c +463 -0
  16. data/ext/extralite/common.c +177 -91
  17. data/ext/extralite/database.c +745 -276
  18. data/ext/extralite/extconf-bundle.rb +10 -4
  19. data/ext/extralite/extconf.rb +34 -34
  20. data/ext/extralite/extralite.h +104 -47
  21. data/ext/extralite/extralite_ext.c +6 -0
  22. data/ext/extralite/iterator.c +14 -86
  23. data/ext/extralite/query.c +171 -264
  24. data/extralite-bundle.gemspec +1 -1
  25. data/extralite.gemspec +1 -1
  26. data/gemspec.rb +10 -11
  27. data/lib/extralite/version.rb +1 -1
  28. data/lib/extralite.rb +69 -10
  29. data/lib/sequel/adapters/extralite.rb +1 -1
  30. data/test/helper.rb +9 -1
  31. data/test/perf_argv_transform.rb +74 -0
  32. data/test/perf_ary.rb +14 -12
  33. data/test/perf_hash.rb +17 -15
  34. data/test/perf_hash_prepared.rb +58 -0
  35. data/test/perf_hash_transform.rb +66 -0
  36. data/test/perf_polyphony.rb +74 -0
  37. data/test/test_changeset.rb +161 -0
  38. data/test/test_database.rb +720 -104
  39. data/test/test_extralite.rb +2 -2
  40. data/test/test_iterator.rb +28 -13
  41. data/test/test_query.rb +352 -110
  42. data/test/test_sequel.rb +4 -4
  43. metadata +24 -16
  44. data/Gemfile.lock +0 -37
  45. data/test/perf_prepared.rb +0 -64
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: dd2ac51ceb97cc6476f169da43fd11d6dad00ac39d5e9fd5eb0d4842ce670f0e
4
- data.tar.gz: f58478324015a1f1827c55ca8b2170b177b270cad0ab8102be225a414da34148
3
+ metadata.gz: 377d86ec4649a083af81ee2958f14f2aa738eec05ae8730502738c090466f120
4
+ data.tar.gz: 47fad09e3cc2283065bc236ad43a2414bbe9b272173fc8a9e30c5a7ea74b5539
5
5
  SHA512:
6
- metadata.gz: 3051d9b5d2a2543be9bdafd5b46aab5574acefa8ca946eaf34f5b1a8097154748f90ab6ba1b7fd76d5bb2b92d97599b35748be0d815258b4b3a499c6c5cefef7
7
- data.tar.gz: 148d29ccfff66b0f1531000d0773b8de98b98169594c08ed032fccd7e92ffe1333357aa3da2e168d2b629d4c7b41b14af373e705601bf384b9d4a4f39af9c4f6
6
+ metadata.gz: 9638d918fb2c909db161757606493463dc5672535bba998db0f53f74b88bdd0f0c2bdd7ca0bfb31b068b6a9d1a3fdf8dda202446aa15ec32bae5b8ceaf9b0e3a
7
+ data.tar.gz: 1502f0be7681c2bd27b89351c4da138de9043453c2e21ecd1349f0cec9fa0f9d500e84eea6dc341d584a0819b1c11315a758c269138a19de0c342fb2a95aa3aa
data/.gitignore CHANGED
@@ -11,6 +11,7 @@
11
11
  /tmp/
12
12
  lib/extralite_ext.*
13
13
  Gemfile-bundle.lock
14
+ Gemfile.lock
14
15
  /cmake-build-debug/
15
16
  CMakeLists.txt
16
17
 
data/CHANGELOG.md CHANGED
@@ -1,22 +1,43 @@
1
+ # 2.7 2024-02-09
2
+
3
+ - Improve progress handler API, add mode, period, tick options, global progress
4
+ handler. [#68](https://github.com/digital-fabric/extralite/pull/68)
5
+ - Rework `Database#initialize` options
6
+ - Add argv row mode (for passing column values as argv)
7
+ - Streamline and improve query methods
8
+ [#67](https://github.com/digital-fabric/extralite/pull/67)
9
+ - Implement row transforms
10
+
11
+ # 2.6 2024-01-23
12
+
13
+ - Implement changeset API.
14
+ [#58](https://github.com/digital-fabric/extralite/issues/58)
15
+ - Reorganize README, update benchmarks.
16
+ [#63](https://github.com/digital-fabric/extralite/issues/63)
17
+ - Implement progress handler API.
18
+ [#62](https://github.com/digital-fabric/extralite/issues/62)
19
+ - Implement savepoint methods.
20
+
1
21
  # 2.5 2024-01-16
2
22
 
3
- - Update bundled sqlite to version 3.45.0
4
- - Implement `Database#batch_query` and related methods
23
+ - Update bundled sqlite to version 3.45.0.
24
+ - Implement `Database#batch_query` and related methods.
5
25
  [53](https://github.com/digital-fabric/extralite/issues/53)
6
- - Accept more options in `Database#initialize`
26
+ - Accept more options in `Database#initialize`.
7
27
  [48](https://github.com/digital-fabric/extralite/issues/48)
8
- - Fix `Database#pragma` to return single value when reading pragma value
9
- - Accept database name in `Database#tables` method
28
+ - Fix `Database#pragma` to return single value when reading pragma value.
29
+ - Accept database name in `Database#tables` method.
10
30
  - Improve `Database#batch_execute` - now accepts Enumerable and Callable
11
- parameters [52](https://github.com/digital-fabric/extralite/issues/52)
12
- - Rename `Database#execute_multi` to `Database#batch_execute`
13
- - Implement Query#clone
31
+ parameters. [52](https://github.com/digital-fabric/extralite/issues/52)
32
+ - Rename `Database#execute_multi` to `Database#batch_execute`.
33
+ - Implement `Query#clone`.
14
34
  [51](https://github.com/digital-fabric/extralite/issues/51)
15
- - Add support for GC compaction
16
- - Remove support for Ruby 2.7
17
- - Implement Query#<< [49](https://github.com/digital-fabric/extralite/issues/49)
18
- - Allow passing parameters in array
19
- - Add support for ractors
35
+ - Add support for GC compaction.
36
+ - Remove support for Ruby 2.7.
37
+ - Implement `Query#<<`.
38
+ [49](https://github.com/digital-fabric/extralite/issues/49)
39
+ - Allow passing parameters in array.
40
+ - Add support for ractors.
20
41
  [#50](https://github.com/digital-fabric/extralite/issues/50)
21
42
 
22
43
  # 2.4 2023-12-24
data/Gemfile CHANGED
@@ -1,3 +1,7 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
3
  gemspec name: 'extralite'
4
+
5
+ group :development do
6
+ gem "ruby_memcheck", "2.3.0" if Gem::Platform.local.os == "linux"
7
+ end
data/Gemfile-bundle CHANGED
@@ -2,4 +2,4 @@ source 'https://rubygems.org'
2
2
 
3
3
  gemspec name: 'extralite'
4
4
 
5
- gem "extralite-bundle", git: "file://#{File.expand_path(__dir__)}", ref: `git rev-parse --abbrev-ref HEAD`.strip
5
+ gem 'extralite-bundle', git: "file://#{File.expand_path(__dir__)}", ref: `git rev-parse --abbrev-ref HEAD`.strip
data/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2023 Sharon Rosner
3
+ Copyright (c) 2024 Sharon Rosner
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal