elasticsearch-persistence 0.1.9 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: fa44968662509546e9ad4f6c0faad08a34ec95ad
4
- data.tar.gz: f3402c6d0c02ad259dbc8a39d0afb1274aa73832
3
+ metadata.gz: 2fecb668d985aea949d25522a2d265bb69405fef
4
+ data.tar.gz: 6e1e33e4ebbe7ed098cb03228185f1028b5f202b
5
5
  SHA512:
6
- metadata.gz: 85b3dfbf241cf54b1c67d96b5cc2bfdb79cb4ec315d04fd908f56b6ed3b40f32c6b3adc6c72091f42a9dd52dde8652782774783d31fc4537d5024af4a7176552
7
- data.tar.gz: 0cb3163aa6afa15846d83e2b1abda34a4ace6bba011c4120a2482a0e8bbb6e86484e2b6d429e1a14cab758bb42c6fb8483668089171608192f440dfb2f2e9611
6
+ metadata.gz: 7275a80064971b313d05e3236342df09be9463e4210f755d376aa8501ab9caa66f2448757e8f5541f21f69c11c11ec61aa38e9b17f1646e913275581008a1bf7
7
+ data.tar.gz: f040b1151c735623cba9755b8d812a2d515c27258ed42905eeac97f2f27fa8c8126c499a43ffc111b7980db1b96afb748fedeeb84440bb7b1dafb24559f22446
data/README.md CHANGED
@@ -2,7 +2,19 @@
2
2
 
3
3
  Persistence layer for Ruby domain objects in Elasticsearch, using the Repository and ActiveRecord patterns.
4
4
 
5
- The library is compatible with Ruby 1.9.3 (or higher) and Elasticsearch 1.0 (or higher).
5
+ ## Compatibility
6
+
7
+ This library is compatible with Ruby 1.9.3 and higher.
8
+
9
+ The library version numbers follow the Elasticsearch major versions, and the `master` branch
10
+ is compatible with the Elasticsearch `master` branch, therefore, with the next major version.
11
+
12
+ | Rubygem | | Elasticsearch |
13
+ |:-------------:|:-:| :-----------: |
14
+ | 0.1 | → | 1.x |
15
+ | 2.x | → | 2.x |
16
+ | 5.x | → | 5.x |
17
+ | master | → | master |
6
18
 
7
19
  ## Installation
8
20
 
@@ -12,11 +24,11 @@ Install the package from [Rubygems](https://rubygems.org):
12
24
 
13
25
  To use an unreleased version, either add it to your `Gemfile` for [Bundler](http://bundler.io):
14
26
 
15
- gem 'elasticsearch-persistence', git: 'git://github.com/elasticsearch/elasticsearch-rails.git'
27
+ gem 'elasticsearch-persistence', git: 'git://github.com/elastic/elasticsearch-rails.git', branch: '5.x'
16
28
 
17
29
  or install it from a source code checkout:
18
30
 
19
- git clone https://github.com/elasticsearch/elasticsearch-rails.git
31
+ git clone https://github.com/elastic/elasticsearch-rails.git
20
32
  cd elasticsearch-rails/elasticsearch-persistence
21
33
  bundle install
22
34
  rake install
@@ -100,7 +112,7 @@ repository.delete(note)
100
112
 
101
113
  The repository module provides a number of features and facilities to configure and customize the behavior:
102
114
 
103
- * Configuring the Elasticsearch [client](https://github.com/elasticsearch/elasticsearch-ruby#usage) being used
115
+ * Configuring the Elasticsearch [client](https://github.com/elastic/elasticsearch-ruby#usage) being used
104
116
  * Setting the index name, document type, and object class for deserialization
105
117
  * Composing mappings and settings for the index
106
118
  * Creating, deleting or refreshing the index
@@ -251,7 +263,7 @@ puts repository.find(1).attributes['image']
251
263
 
252
264
  ##### Client
253
265
 
254
- The repository uses the standard Elasticsearch [client](https://github.com/elasticsearch/elasticsearch-ruby#usage),
266
+ The repository uses the standard Elasticsearch [client](https://github.com/elastic/elasticsearch-ruby#usage),
255
267
  which is accessible with the `client` getter and setter methods:
256
268
 
257
269
  ```ruby
@@ -610,7 +622,7 @@ puts results.response.aggregations.authors.buckets.each { |b| puts "#{b['key']}
610
622
 
611
623
  #### The Elasticsearch Client
612
624
 
613
- The module will set up a [client](https://github.com/elasticsearch/elasticsearch-ruby/tree/master/elasticsearch),
625
+ The module will set up a [client](https://github.com/elastic/elasticsearch-ruby/tree/master/elasticsearch),
614
626
  connected to `localhost:9200`, by default.
615
627
 
616
628
  To use a client with different configuration:
@@ -676,7 +688,7 @@ rails generate scaffold Person name:String email:String birthday:Date --orm=elas
676
688
  A fully working Ruby on Rails application can be generated with the following command:
677
689
 
678
690
  ```bash
679
- rails new music --force --skip --skip-bundle --skip-active-record --template https://raw.githubusercontent.com/elasticsearch/elasticsearch-rails/master/elasticsearch-persistence/examples/music/template.rb
691
+ rails new music --force --skip --skip-bundle --skip-active-record --template https://raw.githubusercontent.com/elastic/elasticsearch-rails/master/elasticsearch-persistence/examples/music/template.rb
680
692
  ```
681
693
 
682
694
  The application demonstrates:
data/Rakefile CHANGED
@@ -8,28 +8,21 @@ task :test => 'test:unit'
8
8
 
9
9
  require 'rake/testtask'
10
10
  namespace :test do
11
- task :ci_reporter do
12
- ENV['CI_REPORTS'] ||= 'tmp/reports'
13
- require 'ci/reporter/rake/minitest'
14
- Rake::Task['ci:setup:minitest'].invoke
15
- end
16
-
17
11
  Rake::TestTask.new(:unit) do |test|
18
- Rake::Task['test:ci_reporter'].invoke if ENV['CI']
19
12
  test.libs << 'lib' << 'test'
20
13
  test.test_files = FileList["test/unit/**/*_test.rb"]
21
- # test.verbose = true
22
- # test.warning = true
14
+ test.verbose = false
15
+ test.warning = false
23
16
  end
24
17
 
25
18
  Rake::TestTask.new(:integration) do |test|
26
- Rake::Task['test:ci_reporter'].invoke if ENV['CI']
27
19
  test.libs << 'lib' << 'test'
28
20
  test.test_files = FileList["test/integration/**/*_test.rb"]
21
+ test.verbose = false
22
+ test.warning = false
29
23
  end
30
24
 
31
25
  Rake::TestTask.new(:all) do |test|
32
- Rake::Task['test:ci_reporter'].invoke if ENV['CI']
33
26
  test.libs << 'lib' << 'test'
34
27
  test.test_files = FileList["test/unit/**/*_test.rb", "test/integration/**/*_test.rb"]
35
28
  end
@@ -23,34 +23,31 @@ Gem::Specification.new do |s|
23
23
 
24
24
  s.required_ruby_version = ">= 1.9.3"
25
25
 
26
- s.add_dependency "elasticsearch", '> 0.4'
26
+ s.add_dependency "elasticsearch", '~> 1.1'
27
27
  s.add_dependency "elasticsearch-model", '>= 0.1'
28
- s.add_dependency "activesupport", '> 3'
29
- s.add_dependency "activemodel", '> 3'
28
+ s.add_dependency "activesupport", '> 4'
29
+ s.add_dependency "activemodel", '> 4'
30
30
  s.add_dependency "hashie"
31
31
  s.add_dependency "virtus"
32
32
 
33
33
  s.add_development_dependency "bundler", "~> 1.5"
34
- s.add_development_dependency "rake", "< 11.0"
34
+ s.add_development_dependency "rake", "~> 11.1"
35
35
 
36
36
  s.add_development_dependency "oj"
37
37
 
38
- s.add_development_dependency "rails"
38
+ s.add_development_dependency "rails", '> 4'
39
39
 
40
40
  s.add_development_dependency "elasticsearch-extensions"
41
41
 
42
- s.add_development_dependency "minitest", "~> 4.2"
43
- s.add_development_dependency "test-unit" if defined?(RUBY_VERSION) && RUBY_VERSION > '2.2'
42
+ s.add_development_dependency "minitest"
43
+ s.add_development_dependency "test-unit"
44
44
  s.add_development_dependency "shoulda-context"
45
45
  s.add_development_dependency "mocha"
46
46
  s.add_development_dependency "turn"
47
47
  s.add_development_dependency "yard"
48
48
  s.add_development_dependency "ruby-prof"
49
49
  s.add_development_dependency "pry"
50
- s.add_development_dependency "ci_reporter", "~> 1.9"
51
50
 
52
- if defined?(RUBY_VERSION) && RUBY_VERSION > '1.9'
53
- s.add_development_dependency "simplecov"
54
- s.add_development_dependency "cane"
55
- end
51
+ s.add_development_dependency "simplecov"
52
+ s.add_development_dependency "cane"
56
53
  end
@@ -1,5 +1,5 @@
1
1
  module Elasticsearch
2
2
  module Persistence
3
- VERSION = "0.1.9"
3
+ VERSION = "2.0.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: elasticsearch-persistence
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.9
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Karel Minarik
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-05 00:00:00.000000000 Z
11
+ date: 2017-04-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: elasticsearch
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ">"
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0.4'
19
+ version: '1.1'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ">"
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '0.4'
26
+ version: '1.1'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: elasticsearch-model
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -44,28 +44,28 @@ dependencies:
44
44
  requirements:
45
45
  - - ">"
46
46
  - !ruby/object:Gem::Version
47
- version: '3'
47
+ version: '4'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - ">"
53
53
  - !ruby/object:Gem::Version
54
- version: '3'
54
+ version: '4'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: activemodel
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - ">"
60
60
  - !ruby/object:Gem::Version
61
- version: '3'
61
+ version: '4'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - ">"
67
67
  - !ruby/object:Gem::Version
68
- version: '3'
68
+ version: '4'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: hashie
71
71
  requirement: !ruby/object:Gem::Requirement
@@ -112,16 +112,16 @@ dependencies:
112
112
  name: rake
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
- - - "<"
115
+ - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: '11.0'
117
+ version: '11.1'
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
- - - "<"
122
+ - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: '11.0'
124
+ version: '11.1'
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: oj
127
127
  requirement: !ruby/object:Gem::Requirement
@@ -140,16 +140,16 @@ dependencies:
140
140
  name: rails
141
141
  requirement: !ruby/object:Gem::Requirement
142
142
  requirements:
143
- - - ">="
143
+ - - ">"
144
144
  - !ruby/object:Gem::Version
145
- version: '0'
145
+ version: '4'
146
146
  type: :development
147
147
  prerelease: false
148
148
  version_requirements: !ruby/object:Gem::Requirement
149
149
  requirements:
150
- - - ">="
150
+ - - ">"
151
151
  - !ruby/object:Gem::Version
152
- version: '0'
152
+ version: '4'
153
153
  - !ruby/object:Gem::Dependency
154
154
  name: elasticsearch-extensions
155
155
  requirement: !ruby/object:Gem::Requirement
@@ -168,18 +168,18 @@ dependencies:
168
168
  name: minitest
169
169
  requirement: !ruby/object:Gem::Requirement
170
170
  requirements:
171
- - - "~>"
171
+ - - ">="
172
172
  - !ruby/object:Gem::Version
173
- version: '4.2'
173
+ version: '0'
174
174
  type: :development
175
175
  prerelease: false
176
176
  version_requirements: !ruby/object:Gem::Requirement
177
177
  requirements:
178
- - - "~>"
178
+ - - ">="
179
179
  - !ruby/object:Gem::Version
180
- version: '4.2'
180
+ version: '0'
181
181
  - !ruby/object:Gem::Dependency
182
- name: shoulda-context
182
+ name: test-unit
183
183
  requirement: !ruby/object:Gem::Requirement
184
184
  requirements:
185
185
  - - ">="
@@ -193,7 +193,7 @@ dependencies:
193
193
  - !ruby/object:Gem::Version
194
194
  version: '0'
195
195
  - !ruby/object:Gem::Dependency
196
- name: mocha
196
+ name: shoulda-context
197
197
  requirement: !ruby/object:Gem::Requirement
198
198
  requirements:
199
199
  - - ">="
@@ -207,7 +207,7 @@ dependencies:
207
207
  - !ruby/object:Gem::Version
208
208
  version: '0'
209
209
  - !ruby/object:Gem::Dependency
210
- name: turn
210
+ name: mocha
211
211
  requirement: !ruby/object:Gem::Requirement
212
212
  requirements:
213
213
  - - ">="
@@ -221,7 +221,7 @@ dependencies:
221
221
  - !ruby/object:Gem::Version
222
222
  version: '0'
223
223
  - !ruby/object:Gem::Dependency
224
- name: yard
224
+ name: turn
225
225
  requirement: !ruby/object:Gem::Requirement
226
226
  requirements:
227
227
  - - ">="
@@ -235,7 +235,7 @@ dependencies:
235
235
  - !ruby/object:Gem::Version
236
236
  version: '0'
237
237
  - !ruby/object:Gem::Dependency
238
- name: ruby-prof
238
+ name: yard
239
239
  requirement: !ruby/object:Gem::Requirement
240
240
  requirements:
241
241
  - - ">="
@@ -249,7 +249,7 @@ dependencies:
249
249
  - !ruby/object:Gem::Version
250
250
  version: '0'
251
251
  - !ruby/object:Gem::Dependency
252
- name: pry
252
+ name: ruby-prof
253
253
  requirement: !ruby/object:Gem::Requirement
254
254
  requirements:
255
255
  - - ">="
@@ -263,19 +263,19 @@ dependencies:
263
263
  - !ruby/object:Gem::Version
264
264
  version: '0'
265
265
  - !ruby/object:Gem::Dependency
266
- name: ci_reporter
266
+ name: pry
267
267
  requirement: !ruby/object:Gem::Requirement
268
268
  requirements:
269
- - - "~>"
269
+ - - ">="
270
270
  - !ruby/object:Gem::Version
271
- version: '1.9'
271
+ version: '0'
272
272
  type: :development
273
273
  prerelease: false
274
274
  version_requirements: !ruby/object:Gem::Requirement
275
275
  requirements:
276
- - - "~>"
276
+ - - ">="
277
277
  - !ruby/object:Gem::Version
278
- version: '1.9'
278
+ version: '0'
279
279
  - !ruby/object:Gem::Dependency
280
280
  name: simplecov
281
281
  requirement: !ruby/object:Gem::Requirement
@@ -410,7 +410,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
410
410
  version: '0'
411
411
  requirements: []
412
412
  rubyforge_project:
413
- rubygems_version: 2.2.2
413
+ rubygems_version: 2.6.10
414
414
  signing_key:
415
415
  specification_version: 4
416
416
  summary: Persistence layer for Ruby models and Elasticsearch.
@@ -437,4 +437,3 @@ test_files:
437
437
  - test/unit/repository_search_test.rb
438
438
  - test/unit/repository_serialize_test.rb
439
439
  - test/unit/repository_store_test.rb
440
- has_rdoc: