sbmt-outbox 6.4.2 → 6.5.0
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e88f22ff7adf6d76e9fb116d0de7d825986114fc4e68a289e286c5e3d9d24fde
|
4
|
+
data.tar.gz: f3ec1429fba3c58bc741ab2c6ebbe9cc1483716cc703a76385c90c09f1e70e24
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a4afedde029080834e7d379402c7832b5d6dfaa6c1d86c25b38358bc95fb9b7db2d1ade8458a2b28750f2a6a8247bede8838198a7b15cb1397b944f6a0e4b174
|
7
|
+
data.tar.gz: 7524112c3ec1e28a594af7fd44bd7cb18bd0e52dc199fa6c327314245e3ca41160aaf28922d94cdedb59c56f7faf528871a216f0d02dae11023c599f62bb2acf
|
@@ -1,5 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require "sbmt/outbox/metrics/utils"
|
4
|
+
|
3
5
|
module Sbmt
|
4
6
|
module Outbox
|
5
7
|
class BaseCreateItem < Outbox::DryInteractor
|
@@ -41,14 +43,14 @@ module Sbmt
|
|
41
43
|
Yabeda
|
42
44
|
.outbox
|
43
45
|
.last_stored_event_id
|
44
|
-
.set({type: box_type, name: box_name, owner: owner, partition: partition}, item_id)
|
46
|
+
.set({type: box_type, name: Sbmt::Outbox::Metrics::Utils.metric_safe(box_name), owner: owner, partition: partition}, item_id)
|
45
47
|
end
|
46
48
|
|
47
49
|
def track_counter(partition)
|
48
50
|
Yabeda
|
49
51
|
.outbox
|
50
52
|
.created_counter
|
51
|
-
.increment({type: box_type, name: box_name, owner: owner, partition: partition}, by: 1)
|
53
|
+
.increment({type: box_type, name: Sbmt::Outbox::Metrics::Utils.metric_safe(box_name), owner: owner, partition: partition}, by: 1)
|
52
54
|
end
|
53
55
|
end
|
54
56
|
end
|
@@ -64,9 +64,12 @@ module Sbmt
|
|
64
64
|
def delete_stale_items(waterline)
|
65
65
|
logger.log_info("Start deleting #{box_type} items for #{box_name} older than #{waterline}")
|
66
66
|
|
67
|
-
|
67
|
+
loop do
|
68
|
+
ids = Outbox.database_switcher.use_slave do
|
69
|
+
item_class.where("created_at < ?", waterline).limit(BATCH_SIZE).ids
|
70
|
+
end
|
71
|
+
break if ids.empty?
|
68
72
|
|
69
|
-
while (ids = scope.limit(BATCH_SIZE).ids).present?
|
70
73
|
item_class.where(id: ids).delete_all
|
71
74
|
sleep SLEEP_TIME
|
72
75
|
end
|
@@ -7,33 +7,55 @@ module Sbmt
|
|
7
7
|
|
8
8
|
def logo
|
9
9
|
<<~'TEXT'
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
10
|
+
|
11
|
+
@@@@@@@
|
12
|
+
@* @.@@
|
13
|
+
@ - @
|
14
|
+
@@@@@@@
|
15
|
+
|
16
|
+
.@@@@ ##.#=. ####
|
17
|
+
@@ .-@ @ *#.#-. -## * # #*
|
18
|
+
@@=.#* @@@ *#.#-. ##- +# ###
|
19
|
+
@+ @@-@@ *#.#-. . ## .# ##
|
20
|
+
%@# # ## #-. # -##.
|
21
|
+
##### # .# . ..## . .## # # ####
|
22
|
+
## :==# #+ ### ### *# # #
|
23
|
+
# -# #### :#=. @@ @@@ @ @@@ @@ .:#- ## ## #
|
24
|
+
####### ### .##: @@ @ @ @@ .##+ ### .######
|
25
|
+
##.. ###. @ @@@@@ @@@@@ @@@@@ @ .*## . :##.
|
26
|
+
# +### * @@@@@@@@ @@@ @@@ @@@ @@@@@@@@ ## .###= *#
|
27
|
+
# :## @@@@%%%%@@@@@@@ @ @ @ @@@@@@@%%%%@@@@ ##. +#
|
28
|
+
# @@@@%%%%%%%%%%%@@@@@@@= =@@@@@@@%%%%%%%%%%%@@@@ +#
|
29
|
+
# -@@@@@@@%%%%%%%%%%%%@@@@@@ @@@@@@%%%%%%%%%%%%@@@@@@@- +#
|
30
|
+
#. :@@@@@@@%%%%%%@@@- @ @ @@@@%%%%%%@@@@@@@# .+
|
31
|
+
################### @@- *@@@@@@@@@ @@@ @# @@@@@@@@@@ :@ ###################+
|
32
|
+
#. ... @@@@@@@@ @@@ + @@ @@@ : @@@ :-* @@@ .. .. .+
|
33
|
+
# -##* -###: @ @ @@@ -@@.@@ @ @#@ :*- @ #@@@.: +@ -###: .### +#
|
34
|
+
# .#...:*# @ @@@@@@@ .@@# @@+@ @*@%+ @@=@+ @@%# @ ## :.# # +#
|
35
|
+
# -##.-: ## @ @@@@@@ @@@@@= @@%@ @#*@@ *@@@. ##@@ @ # +.-.#. +
|
36
|
+
### ##- @ @@ @% : @@@@@@ @* @@#- :@@@= =## @ ##+ ###+
|
37
|
+
# @@@ @@@@ @@ @@@ @ @ @* @%@@ .@@ :@@@@@@ .-
|
38
|
+
+*@*- %@@ =% @%@.=@ @ @@ @#+ *@@@@ @@@%
|
39
|
+
@@@ @ @@@ @@@@@@:@ @ @@ @@@@@@ .@..# @ @
|
40
|
+
@..@ +. @ ######################### @@@@ @@@@ ##########################=%@ #.@= @
|
41
|
+
@@@@@ # # @@@@@@
|
42
|
+
# #
|
43
|
+
@@@@@@ # # @@@@@
|
44
|
+
@@ @#% @ ###################### @@@ ###################### @@ @*@ @@
|
45
|
+
@@ @#@--@ @@@@@ @@ @#@ @@
|
46
|
+
@@@@@@ ####################### @@@ ######################## @@@@@
|
47
|
+
|
48
|
+
@@@@@ @@@@@
|
49
|
+
@@@@@@@ @@@@@@@
|
50
|
+
@@@@@ @@ @@@@@
|
51
|
+
@@@@@@@@@@ @@@ @@
|
52
|
+
@@@@@ @@@ @@@ @@@ @@@ @@@@@@@ @@ @@@@@ @@@@@@@ @@@ @@@ @@@@@
|
53
|
+
@@@@@@@ @@@ @@@ @@@ @@@ @@@ @@ @@@ @@@ @@ @@@ @@@@@@@
|
54
|
+
@@@@@ @@@ @@@ @@@ @@@@ @@@ @@@ @@@ @@@ @@ @@@ @@@@@
|
55
|
+
@@@@@@@@@@ @@@@ @@@ @@@@@ @@ @@@@@ @@@@@@ @@@ @@@
|
56
|
+
@@@@@ @@@@@
|
57
|
+
@@@@@@@ @@@@@@@
|
58
|
+
@@@@@ @@@@@
|
37
59
|
TEXT
|
38
60
|
end
|
39
61
|
|
@@ -94,7 +94,7 @@ module Sbmt
|
|
94
94
|
end
|
95
95
|
end
|
96
96
|
rescue Cutoff::CutoffExceededError
|
97
|
-
box_worker.job_timeout_counter.increment(
|
97
|
+
box_worker.job_timeout_counter.increment(task.yabeda_labels)
|
98
98
|
logger.log_info("Lock timeout while processing #{task.resource_key} at id #{last_id}")
|
99
99
|
end
|
100
100
|
|
data/lib/sbmt/outbox/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sbmt-outbox
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.
|
4
|
+
version: 6.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sbermarket Ruby-Platform Team
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-05
|
11
|
+
date: 2024-06-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: connection_pool
|
@@ -636,7 +636,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
636
636
|
- !ruby/object:Gem::Version
|
637
637
|
version: '0'
|
638
638
|
requirements: []
|
639
|
-
rubygems_version: 3.
|
639
|
+
rubygems_version: 3.5.11
|
640
640
|
signing_key:
|
641
641
|
specification_version: 4
|
642
642
|
summary: Outbox service
|