timescaledb 0.1.2 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (89) hide show
  1. checksums.yaml +4 -4
  2. data/.ruby-version +1 -0
  3. data/.tool-versions +1 -0
  4. data/.travis.yml +3 -0
  5. data/Gemfile +4 -0
  6. data/Gemfile.lock +11 -3
  7. data/Gemfile.scenic +7 -0
  8. data/Gemfile.scenic.lock +121 -0
  9. data/README.md +267 -121
  10. data/Rakefile +16 -1
  11. data/bin/console +2 -2
  12. data/bin/setup +2 -0
  13. data/bin/tsdb +30 -6
  14. data/examples/{Gemfile → all_in_one/Gemfile} +1 -1
  15. data/examples/{Gemfile.lock → all_in_one/Gemfile.lock} +2 -2
  16. data/examples/{all_in_one.rb → all_in_one/all_in_one.rb} +3 -6
  17. data/examples/ranking/.gitattributes +7 -0
  18. data/examples/ranking/.gitignore +29 -0
  19. data/examples/ranking/.ruby-version +1 -0
  20. data/examples/ranking/Gemfile +33 -0
  21. data/examples/ranking/Gemfile.lock +189 -0
  22. data/examples/ranking/README.md +166 -0
  23. data/examples/ranking/Rakefile +6 -0
  24. data/examples/ranking/app/controllers/application_controller.rb +2 -0
  25. data/examples/ranking/app/controllers/concerns/.keep +0 -0
  26. data/examples/ranking/app/jobs/application_job.rb +7 -0
  27. data/examples/ranking/app/models/application_record.rb +3 -0
  28. data/examples/ranking/app/models/concerns/.keep +0 -0
  29. data/examples/ranking/app/models/game.rb +2 -0
  30. data/examples/ranking/app/models/play.rb +7 -0
  31. data/examples/ranking/bin/bundle +114 -0
  32. data/examples/ranking/bin/rails +4 -0
  33. data/examples/ranking/bin/rake +4 -0
  34. data/examples/ranking/bin/setup +33 -0
  35. data/examples/ranking/config/application.rb +39 -0
  36. data/examples/ranking/config/boot.rb +4 -0
  37. data/examples/ranking/config/credentials.yml.enc +1 -0
  38. data/examples/ranking/config/database.yml +86 -0
  39. data/examples/ranking/config/environment.rb +5 -0
  40. data/examples/ranking/config/environments/development.rb +60 -0
  41. data/examples/ranking/config/environments/production.rb +75 -0
  42. data/examples/ranking/config/environments/test.rb +53 -0
  43. data/examples/ranking/config/initializers/cors.rb +16 -0
  44. data/examples/ranking/config/initializers/filter_parameter_logging.rb +8 -0
  45. data/examples/ranking/config/initializers/inflections.rb +16 -0
  46. data/examples/ranking/config/initializers/timescale.rb +3 -0
  47. data/examples/ranking/config/locales/en.yml +33 -0
  48. data/examples/ranking/config/puma.rb +43 -0
  49. data/examples/ranking/config/routes.rb +6 -0
  50. data/examples/ranking/config/storage.yml +34 -0
  51. data/examples/ranking/config.ru +6 -0
  52. data/examples/ranking/db/migrate/20220209120747_create_games.rb +10 -0
  53. data/examples/ranking/db/migrate/20220209120910_create_plays.rb +19 -0
  54. data/examples/ranking/db/migrate/20220209143347_create_score_per_hours.rb +5 -0
  55. data/examples/ranking/db/schema.rb +47 -0
  56. data/examples/ranking/db/seeds.rb +7 -0
  57. data/examples/ranking/db/views/score_per_hours_v01.sql +7 -0
  58. data/examples/ranking/lib/tasks/.keep +0 -0
  59. data/examples/ranking/log/.keep +0 -0
  60. data/examples/ranking/public/robots.txt +1 -0
  61. data/examples/ranking/storage/.keep +0 -0
  62. data/examples/ranking/tmp/.keep +0 -0
  63. data/examples/ranking/tmp/pids/.keep +0 -0
  64. data/examples/ranking/tmp/storage/.keep +0 -0
  65. data/examples/ranking/vendor/.keep +0 -0
  66. data/lib/timescaledb/acts_as_hypertable/core.rb +87 -0
  67. data/lib/timescaledb/acts_as_hypertable.rb +62 -0
  68. data/lib/{timescale → timescaledb}/chunk.rb +9 -1
  69. data/lib/{timescale → timescaledb}/compression_settings.rb +3 -2
  70. data/lib/timescaledb/continuous_aggregates.rb +19 -0
  71. data/lib/timescaledb/dimensions.rb +6 -0
  72. data/lib/{timescale → timescaledb}/hypertable.rb +9 -5
  73. data/lib/timescaledb/job.rb +10 -0
  74. data/lib/{timescale → timescaledb}/job_stats.rb +3 -4
  75. data/lib/{timescale → timescaledb}/migration_helpers.rb +35 -5
  76. data/lib/timescaledb/scenic/adapter.rb +55 -0
  77. data/lib/timescaledb/scenic/extension.rb +72 -0
  78. data/lib/timescaledb/schema_dumper.rb +88 -0
  79. data/lib/timescaledb/stats_report.rb +35 -0
  80. data/lib/timescaledb/version.rb +3 -0
  81. data/lib/timescaledb.rb +64 -0
  82. data/{timescale.gemspec → timescaledb.gemspec} +6 -4
  83. metadata +106 -20
  84. data/lib/timescale/acts_as_hypertable.rb +0 -114
  85. data/lib/timescale/continuous_aggregates.rb +0 -9
  86. data/lib/timescale/job.rb +0 -13
  87. data/lib/timescale/stats_report.rb +0 -28
  88. data/lib/timescale/version.rb +0 -3
  89. data/lib/timescale.rb +0 -52
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 69db00d0dc568db01a5bd739183cd5615dbdc66267ad1441502d5c3774753dcb
4
- data.tar.gz: be2271adcbc9e9b81302d9597824d18462ff64530c095c9e4a3239db1ccbaa51
3
+ metadata.gz: 128f81d085e998eb85b11ae08b9647880e5da2033fe8c845716fb5cb0a231cb8
4
+ data.tar.gz: 95c934194cad90f67d4f058491b011935f1da4bf62d40c82bbc85fb293a3189c
5
5
  SHA512:
6
- metadata.gz: cc6a3bf67e7c73096d6a9a739d1a52ca0f4c560c80e1a7febf90a8e99d3f1009bd282ad16dfeb235b03c6613e27d7d35938a51a10314a1ffb83209b81686e748
7
- data.tar.gz: effbd8f2686a312671c9275945a8705ec64453687699935872e7cb5e3445e1edcd982ee86b625dc69ba673166b13c9839d11a5756e95212b3dab4cca59055eeb
6
+ metadata.gz: 589909dd6e1baa40199c0147d8b6e65a4848090d9c7ec9575be64ca841e8e690554ada570136a8b32e60c93f0b155c0cf1a9ba80c601c3923146690e102382ce
7
+ data.tar.gz: ca63b74219756fa81ca586ad78b55e597a86f96a354b53a5c20e531925e02bb12aad7ebff000a90082040158e1ddfa6974c97e927c40c2ec65c46c2375656c67
data/.ruby-version ADDED
@@ -0,0 +1 @@
1
+ 2.7.1
data/.tool-versions ADDED
@@ -0,0 +1 @@
1
+ ruby 2.7.1
data/.travis.yml CHANGED
@@ -4,3 +4,6 @@ cache: bundler
4
4
  rvm:
5
5
  - 2.7.1
6
6
  before_install: gem install bundler -v 2.1.4
7
+ gemfile:
8
+ - Gemfile
9
+ - Gemfile.scenic
data/Gemfile CHANGED
@@ -2,3 +2,7 @@ source "https://rubygems.org"
2
2
 
3
3
  # Specify your gem's dependencies in timescale.gemspec
4
4
  gemspec
5
+
6
+ # gemika must be listed in the Gemfile rather than as a development dependency in the gemspec.
7
+ # It throws an error, otherwise.
8
+ gem "gemika"
data/Gemfile.lock CHANGED
@@ -1,8 +1,9 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- timescaledb (0.1.1)
4
+ timescaledb (0.2.0)
5
5
  activerecord
6
+ activesupport
6
7
  pg (~> 1.2)
7
8
 
8
9
  GEM
@@ -21,13 +22,18 @@ GEM
21
22
  zeitwerk (~> 2.3)
22
23
  coderay (1.1.3)
23
24
  concurrent-ruby (1.1.9)
25
+ database_cleaner-active_record (2.0.1)
26
+ activerecord (>= 5.a)
27
+ database_cleaner-core (~> 2.0.0)
28
+ database_cleaner-core (2.0.1)
24
29
  diff-lcs (1.4.4)
25
30
  dotenv (2.7.6)
31
+ gemika (0.6.1)
26
32
  i18n (1.8.10)
27
33
  concurrent-ruby (~> 1.0)
28
34
  method_source (1.0.0)
29
35
  minitest (5.14.4)
30
- pg (1.2.3)
36
+ pg (1.3.1)
31
37
  pry (0.14.1)
32
38
  coderay (~> 1.1)
33
39
  method_source (~> 1.0)
@@ -56,7 +62,9 @@ PLATFORMS
56
62
  ruby
57
63
 
58
64
  DEPENDENCIES
65
+ database_cleaner-active_record
59
66
  dotenv
67
+ gemika
60
68
  pry
61
69
  rake (~> 12.0)
62
70
  rspec (~> 3.0)
@@ -64,4 +72,4 @@ DEPENDENCIES
64
72
  timescaledb!
65
73
 
66
74
  BUNDLED WITH
67
- 2.1.4
75
+ 2.2.31
data/Gemfile.scenic ADDED
@@ -0,0 +1,7 @@
1
+ source "https://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in timescale.gemspec
4
+ gemspec
5
+
6
+ gem "scenic"
7
+ gem "gemika"
@@ -0,0 +1,121 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ timescaledb (0.1.5)
5
+ activerecord
6
+ activesupport
7
+ pg (~> 1.2)
8
+
9
+ GEM
10
+ remote: https://rubygems.org/
11
+ specs:
12
+ actionpack (6.1.4.1)
13
+ actionview (= 6.1.4.1)
14
+ activesupport (= 6.1.4.1)
15
+ rack (~> 2.0, >= 2.0.9)
16
+ rack-test (>= 0.6.3)
17
+ rails-dom-testing (~> 2.0)
18
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
19
+ actionview (6.1.4.1)
20
+ activesupport (= 6.1.4.1)
21
+ builder (~> 3.1)
22
+ erubi (~> 1.4)
23
+ rails-dom-testing (~> 2.0)
24
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
25
+ activemodel (6.1.4.1)
26
+ activesupport (= 6.1.4.1)
27
+ activerecord (6.1.4.1)
28
+ activemodel (= 6.1.4.1)
29
+ activesupport (= 6.1.4.1)
30
+ activesupport (6.1.4.1)
31
+ concurrent-ruby (~> 1.0, >= 1.0.2)
32
+ i18n (>= 1.6, < 2)
33
+ minitest (>= 5.1)
34
+ tzinfo (~> 2.0)
35
+ zeitwerk (~> 2.3)
36
+ builder (3.2.4)
37
+ coderay (1.1.3)
38
+ concurrent-ruby (1.1.9)
39
+ crass (1.0.6)
40
+ database_cleaner-active_record (2.0.1)
41
+ activerecord (>= 5.a)
42
+ database_cleaner-core (~> 2.0.0)
43
+ database_cleaner-core (2.0.1)
44
+ diff-lcs (1.4.4)
45
+ dotenv (2.7.6)
46
+ erubi (1.10.0)
47
+ gemika (0.6.1)
48
+ i18n (1.8.11)
49
+ concurrent-ruby (~> 1.0)
50
+ loofah (2.12.0)
51
+ crass (~> 1.0.2)
52
+ nokogiri (>= 1.5.9)
53
+ method_source (1.0.0)
54
+ mini_portile2 (2.6.1)
55
+ minitest (5.14.4)
56
+ nokogiri (1.12.5)
57
+ mini_portile2 (~> 2.6.1)
58
+ racc (~> 1.4)
59
+ nokogiri (1.12.5-x86_64-darwin)
60
+ racc (~> 1.4)
61
+ pg (1.3.0)
62
+ pry (0.14.1)
63
+ coderay (~> 1.1)
64
+ method_source (~> 1.0)
65
+ racc (1.6.0)
66
+ rack (2.2.3)
67
+ rack-test (1.1.0)
68
+ rack (>= 1.0, < 3)
69
+ rails-dom-testing (2.0.3)
70
+ activesupport (>= 4.2.0)
71
+ nokogiri (>= 1.6)
72
+ rails-html-sanitizer (1.4.2)
73
+ loofah (~> 2.3)
74
+ railties (6.1.4.1)
75
+ actionpack (= 6.1.4.1)
76
+ activesupport (= 6.1.4.1)
77
+ method_source
78
+ rake (>= 0.13)
79
+ thor (~> 1.0)
80
+ rake (12.3.3)
81
+ rspec (3.10.0)
82
+ rspec-core (~> 3.10.0)
83
+ rspec-expectations (~> 3.10.0)
84
+ rspec-mocks (~> 3.10.0)
85
+ rspec-core (3.10.1)
86
+ rspec-support (~> 3.10.0)
87
+ rspec-expectations (3.10.1)
88
+ diff-lcs (>= 1.2.0, < 2.0)
89
+ rspec-support (~> 3.10.0)
90
+ rspec-its (1.3.0)
91
+ rspec-core (>= 3.0.0)
92
+ rspec-expectations (>= 3.0.0)
93
+ rspec-mocks (3.10.2)
94
+ diff-lcs (>= 1.2.0, < 2.0)
95
+ rspec-support (~> 3.10.0)
96
+ rspec-support (3.10.3)
97
+ scenic (1.5.4)
98
+ activerecord (>= 4.0.0)
99
+ railties (>= 4.0.0)
100
+ thor (1.1.0)
101
+ tzinfo (2.0.4)
102
+ concurrent-ruby (~> 1.0)
103
+ zeitwerk (2.5.1)
104
+
105
+ PLATFORMS
106
+ ruby
107
+ x86_64-darwin-20
108
+
109
+ DEPENDENCIES
110
+ database_cleaner-active_record
111
+ dotenv
112
+ gemika
113
+ pry
114
+ rake (~> 12.0)
115
+ rspec (~> 3.0)
116
+ rspec-its
117
+ scenic
118
+ timescaledb!
119
+
120
+ BUNDLED WITH
121
+ 2.2.33