elasticgraph-indexer 0.18.0.4 → 0.18.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/elastic_graph/indexer/config.rb +2 -2
- data/lib/elastic_graph/indexer/datastore_indexing_router.rb +3 -3
- data/lib/elastic_graph/indexer/event_id.rb +1 -1
- data/lib/elastic_graph/indexer/failed_event_error.rb +2 -2
- data/lib/elastic_graph/indexer/indexing_failures_error.rb +2 -2
- data/lib/elastic_graph/indexer/indexing_preparers/integer.rb +1 -1
- data/lib/elastic_graph/indexer/operation/update.rb +1 -1
- data/lib/elastic_graph/indexer/processor.rb +1 -1
- data/lib/elastic_graph/indexer/record_preparer.rb +1 -1
- metadata +20 -18
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 30529126d550acc2f7da86d8bbcc426caf29f2d78d2f47e06ffeb0cd4e4c7870
|
4
|
+
data.tar.gz: aeddbd82a3fc0f48db45a648cb0bc8188b99e338b32a78f920eebf66f25bb386
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0c519e8f13d1a1b46bf523aaf80e92ab9b59c65218307ad1dc6deb49673b7626203426827282a859c84651654ab11912003104518c48e5ef75f2b1e116b95941
|
7
|
+
data.tar.gz: 9b18953c9fce2f1bf2e530fb8e42ff55904438f43f04673340ca3a86ce415e832d568c1e0d00af6d21ac7ddc0b46654ca53503dcaea3fdcd70b3ced1423620c1
|
@@ -6,7 +6,7 @@
|
|
6
6
|
#
|
7
7
|
# frozen_string_literal: true
|
8
8
|
|
9
|
-
require "elastic_graph/
|
9
|
+
require "elastic_graph/errors"
|
10
10
|
require "elastic_graph/indexer/event_id"
|
11
11
|
|
12
12
|
module ElasticGraph
|
@@ -29,7 +29,7 @@ module ElasticGraph
|
|
29
29
|
extra_keys = hash.keys - EXPECTED_KEYS
|
30
30
|
|
31
31
|
unless extra_keys.empty?
|
32
|
-
raise ConfigError, "Unknown `indexer` config settings: #{extra_keys.join(", ")}"
|
32
|
+
raise Errors::ConfigError, "Unknown `indexer` config settings: #{extra_keys.join(", ")}"
|
33
33
|
end
|
34
34
|
|
35
35
|
new(
|
@@ -7,7 +7,7 @@
|
|
7
7
|
# frozen_string_literal: true
|
8
8
|
|
9
9
|
require "elastic_graph/constants"
|
10
|
-
require "elastic_graph/
|
10
|
+
require "elastic_graph/errors"
|
11
11
|
require "elastic_graph/datastore_core/index_config_normalizer"
|
12
12
|
require "elastic_graph/indexer/event_id"
|
13
13
|
require "elastic_graph/indexer/hash_differ"
|
@@ -298,7 +298,7 @@ module ElasticGraph
|
|
298
298
|
end
|
299
299
|
end
|
300
300
|
else
|
301
|
-
raise IdentifyDocumentVersionsFailedError, "Got #{failures.size} failure(s) while querying the datastore " \
|
301
|
+
raise Errors::IdentifyDocumentVersionsFailedError, "Got #{failures.size} failure(s) while querying the datastore " \
|
302
302
|
"for document versions:\n\n#{failures.join("\n")}"
|
303
303
|
end
|
304
304
|
end
|
@@ -337,7 +337,7 @@ module ElasticGraph
|
|
337
337
|
EOS
|
338
338
|
end.join("\n\n")
|
339
339
|
|
340
|
-
raise ConfigError, "Datastore index mappings are incomplete compared to the current schema. " \
|
340
|
+
raise Errors::ConfigError, "Datastore index mappings are incomplete compared to the current schema. " \
|
341
341
|
"The diff below uses the datastore index mapping as the base, and shows the expected mapping as a diff. " \
|
342
342
|
"\n\n#{formatted_diffs}"
|
343
343
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
#
|
7
7
|
# frozen_string_literal: true
|
8
8
|
|
9
|
-
require "elastic_graph/
|
9
|
+
require "elastic_graph/errors"
|
10
10
|
require "elastic_graph/indexer/event_id"
|
11
11
|
|
12
12
|
module ElasticGraph
|
@@ -14,7 +14,7 @@ module ElasticGraph
|
|
14
14
|
# Indicates an event that we attempted to process which failed for some reason. It may have
|
15
15
|
# failed due to a validation issue before we even attempted to write it to the datastore, or it
|
16
16
|
# could have failed in the datastore itself.
|
17
|
-
class FailedEventError < Error
|
17
|
+
class FailedEventError < Errors::Error
|
18
18
|
# @dynamic main_message, event, operations
|
19
19
|
|
20
20
|
# The "main" part of the error message (without the `full_id` portion).
|
@@ -6,11 +6,11 @@
|
|
6
6
|
#
|
7
7
|
# frozen_string_literal: true
|
8
8
|
|
9
|
-
require "elastic_graph/
|
9
|
+
require "elastic_graph/errors"
|
10
10
|
|
11
11
|
module ElasticGraph
|
12
12
|
class Indexer
|
13
|
-
class IndexingFailuresError < Error
|
13
|
+
class IndexingFailuresError < Errors::Error
|
14
14
|
# Builds an `IndexingFailuresError` with a nicely formatted message for the given array of `FailedEventError`.
|
15
15
|
def self.for(failures:, events:)
|
16
16
|
summary = "Got #{failures.size} failure(s) from #{events.size} event(s):"
|
@@ -33,7 +33,7 @@ module ElasticGraph
|
|
33
33
|
def self.prepare_for_indexing(value)
|
34
34
|
integer = value.to_i
|
35
35
|
return integer if value == integer
|
36
|
-
raise IndexOperationError, "Cannot safely coerce `#{value.inspect}` to an integer"
|
36
|
+
raise Errors::IndexOperationError, "Cannot safely coerce `#{value.inspect}` to an integer"
|
37
37
|
end
|
38
38
|
end
|
39
39
|
end
|
@@ -7,7 +7,7 @@
|
|
7
7
|
# frozen_string_literal: true
|
8
8
|
|
9
9
|
require "elastic_graph/constants"
|
10
|
-
require "elastic_graph/
|
10
|
+
require "elastic_graph/errors"
|
11
11
|
require "elastic_graph/indexer/event_id"
|
12
12
|
require "elastic_graph/indexer/operation/count_accumulator"
|
13
13
|
require "elastic_graph/indexer/operation/result"
|
metadata
CHANGED
@@ -1,14 +1,16 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: elasticgraph-indexer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.18.0.
|
4
|
+
version: 0.18.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Myron Marston
|
8
|
+
- Ben VandenBos
|
9
|
+
- Square Engineering
|
8
10
|
autorequire:
|
9
11
|
bindir: exe
|
10
12
|
cert_chain: []
|
11
|
-
date: 2024-09-
|
13
|
+
date: 2024-09-20 00:00:00.000000000 Z
|
12
14
|
dependencies:
|
13
15
|
- !ruby/object:Gem::Dependency
|
14
16
|
name: rubocop-factory_bot
|
@@ -266,56 +268,56 @@ dependencies:
|
|
266
268
|
requirements:
|
267
269
|
- - '='
|
268
270
|
- !ruby/object:Gem::Version
|
269
|
-
version: 0.18.0.
|
271
|
+
version: 0.18.0.5
|
270
272
|
type: :runtime
|
271
273
|
prerelease: false
|
272
274
|
version_requirements: !ruby/object:Gem::Requirement
|
273
275
|
requirements:
|
274
276
|
- - '='
|
275
277
|
- !ruby/object:Gem::Version
|
276
|
-
version: 0.18.0.
|
278
|
+
version: 0.18.0.5
|
277
279
|
- !ruby/object:Gem::Dependency
|
278
280
|
name: elasticgraph-json_schema
|
279
281
|
requirement: !ruby/object:Gem::Requirement
|
280
282
|
requirements:
|
281
283
|
- - '='
|
282
284
|
- !ruby/object:Gem::Version
|
283
|
-
version: 0.18.0.
|
285
|
+
version: 0.18.0.5
|
284
286
|
type: :runtime
|
285
287
|
prerelease: false
|
286
288
|
version_requirements: !ruby/object:Gem::Requirement
|
287
289
|
requirements:
|
288
290
|
- - '='
|
289
291
|
- !ruby/object:Gem::Version
|
290
|
-
version: 0.18.0.
|
292
|
+
version: 0.18.0.5
|
291
293
|
- !ruby/object:Gem::Dependency
|
292
294
|
name: elasticgraph-schema_artifacts
|
293
295
|
requirement: !ruby/object:Gem::Requirement
|
294
296
|
requirements:
|
295
297
|
- - '='
|
296
298
|
- !ruby/object:Gem::Version
|
297
|
-
version: 0.18.0.
|
299
|
+
version: 0.18.0.5
|
298
300
|
type: :runtime
|
299
301
|
prerelease: false
|
300
302
|
version_requirements: !ruby/object:Gem::Requirement
|
301
303
|
requirements:
|
302
304
|
- - '='
|
303
305
|
- !ruby/object:Gem::Version
|
304
|
-
version: 0.18.0.
|
306
|
+
version: 0.18.0.5
|
305
307
|
- !ruby/object:Gem::Dependency
|
306
308
|
name: elasticgraph-support
|
307
309
|
requirement: !ruby/object:Gem::Requirement
|
308
310
|
requirements:
|
309
311
|
- - '='
|
310
312
|
- !ruby/object:Gem::Version
|
311
|
-
version: 0.18.0.
|
313
|
+
version: 0.18.0.5
|
312
314
|
type: :runtime
|
313
315
|
prerelease: false
|
314
316
|
version_requirements: !ruby/object:Gem::Requirement
|
315
317
|
requirements:
|
316
318
|
- - '='
|
317
319
|
- !ruby/object:Gem::Version
|
318
|
-
version: 0.18.0.
|
320
|
+
version: 0.18.0.5
|
319
321
|
- !ruby/object:Gem::Dependency
|
320
322
|
name: hashdiff
|
321
323
|
requirement: !ruby/object:Gem::Requirement
|
@@ -336,56 +338,56 @@ dependencies:
|
|
336
338
|
requirements:
|
337
339
|
- - '='
|
338
340
|
- !ruby/object:Gem::Version
|
339
|
-
version: 0.18.0.
|
341
|
+
version: 0.18.0.5
|
340
342
|
type: :development
|
341
343
|
prerelease: false
|
342
344
|
version_requirements: !ruby/object:Gem::Requirement
|
343
345
|
requirements:
|
344
346
|
- - '='
|
345
347
|
- !ruby/object:Gem::Version
|
346
|
-
version: 0.18.0.
|
348
|
+
version: 0.18.0.5
|
347
349
|
- !ruby/object:Gem::Dependency
|
348
350
|
name: elasticgraph-elasticsearch
|
349
351
|
requirement: !ruby/object:Gem::Requirement
|
350
352
|
requirements:
|
351
353
|
- - '='
|
352
354
|
- !ruby/object:Gem::Version
|
353
|
-
version: 0.18.0.
|
355
|
+
version: 0.18.0.5
|
354
356
|
type: :development
|
355
357
|
prerelease: false
|
356
358
|
version_requirements: !ruby/object:Gem::Requirement
|
357
359
|
requirements:
|
358
360
|
- - '='
|
359
361
|
- !ruby/object:Gem::Version
|
360
|
-
version: 0.18.0.
|
362
|
+
version: 0.18.0.5
|
361
363
|
- !ruby/object:Gem::Dependency
|
362
364
|
name: elasticgraph-opensearch
|
363
365
|
requirement: !ruby/object:Gem::Requirement
|
364
366
|
requirements:
|
365
367
|
- - '='
|
366
368
|
- !ruby/object:Gem::Version
|
367
|
-
version: 0.18.0.
|
369
|
+
version: 0.18.0.5
|
368
370
|
type: :development
|
369
371
|
prerelease: false
|
370
372
|
version_requirements: !ruby/object:Gem::Requirement
|
371
373
|
requirements:
|
372
374
|
- - '='
|
373
375
|
- !ruby/object:Gem::Version
|
374
|
-
version: 0.18.0.
|
376
|
+
version: 0.18.0.5
|
375
377
|
- !ruby/object:Gem::Dependency
|
376
378
|
name: elasticgraph-schema_definition
|
377
379
|
requirement: !ruby/object:Gem::Requirement
|
378
380
|
requirements:
|
379
381
|
- - '='
|
380
382
|
- !ruby/object:Gem::Version
|
381
|
-
version: 0.18.0.
|
383
|
+
version: 0.18.0.5
|
382
384
|
type: :development
|
383
385
|
prerelease: false
|
384
386
|
version_requirements: !ruby/object:Gem::Requirement
|
385
387
|
requirements:
|
386
388
|
- - '='
|
387
389
|
- !ruby/object:Gem::Version
|
388
|
-
version: 0.18.0.
|
390
|
+
version: 0.18.0.5
|
389
391
|
description:
|
390
392
|
email:
|
391
393
|
- myron@squareup.com
|