dapr 0.1.26 → 0.2.2

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
  SHA256:
3
- metadata.gz: ede293d0cbb90960527f0c91f4009679a2db765f355b8a9d17094f209c11b900
4
- data.tar.gz: a6ca7bc7a6ad7f8a775b395a6c5eb1da9164f820af88efd8768827436beabc75
3
+ metadata.gz: cdeb79cfa744ea1ef4f7188298ca887359ce26c703944d6e4fa109d2e485ee66
4
+ data.tar.gz: 4f9ac87190179fe43e61110b1328a0e5b1edb9cd2180ec902307fe6386c31052
5
5
  SHA512:
6
- metadata.gz: 4f0d9506ea6006ddd9a117bb330767b86c208d56ef668b418e46b0f3cc231788a8c28dee64a2b412b32cda25bbe104f1b7d27a26b063773e4173c8e127a149d5
7
- data.tar.gz: 5b3612f1175a25544aa284514391d4b0c27f9ddaca60eafafe589e7cfc5942b4c2d73c616e7d6743e1596558216302ed7371f8d2f322100e116bd218f4040e07
6
+ metadata.gz: 856a772018ee14ad66121bc774254c161e8437d60ed5a43d0dd449a011ce7198cb493c6f00713ec8054dc34f3c1c616db756df1184f6d889b574c5475cc2d22f
7
+ data.tar.gz: 169b7844c310f71d9b75b392114f7bc8bc9f69d40fa59a3f0fb351148a94fb1a6b1930cdc1f25f0a7a97aa6428c1bdfc981bdbeb3aede368e53c59fefc2b86d4
data/.overcommit.yml CHANGED
@@ -54,7 +54,7 @@ PreCommit:
54
54
  enabled: false
55
55
  ForbiddenBranches:
56
56
  enabled: true
57
- branch_patterns: [ 'main', 'master' ]
57
+ branch_patterns: ['main', 'master']
58
58
  GinkgoFocus:
59
59
  enabled: false
60
60
  GoFmt:
@@ -205,7 +205,7 @@ PreCommit:
205
205
  enabled: false
206
206
  CommitMsg:
207
207
  CapitalizedSubject:
208
- enabled: true
208
+ enabled: false
209
209
  EmptyMessage:
210
210
  enabled: true
211
211
  GerritChangeId:
@@ -213,15 +213,23 @@ CommitMsg:
213
213
  HardTabs:
214
214
  enabled: false
215
215
  MessageFormat:
216
- enabled: false
216
+ enabled: true
217
+ expected_pattern_message: |-
218
+ /^(?<type>[a-z]+)(?<scope>\(\w+\))?!?: (?<subject>[A-Z].*)$/
219
+ The scope and ! are optional see
220
+ https://www.conventionalcommits.org/en/v1.0.0/#specification
221
+ Subject must start with a capital letter
222
+ pattern: '^(?<type>[a-z]+)(?<scope>\(\w+\))?!?: (?<subject>[A-Z].*)$'
223
+ sample_message: 'docs(readme): ISSUE-10 - Correct typo'
217
224
  RussianNovel:
218
- enabled: false
225
+ enabled: true
219
226
  SingleLineSubject:
220
227
  enabled: true
221
228
  SpellCheck:
222
229
  enabled: false
223
230
  TextWidth:
224
231
  enabled: true
232
+ max_subject_width: 72
225
233
  TrailingPeriod:
226
234
  enabled: true
227
235
  PostCheckout:
@@ -0,0 +1,28 @@
1
+ {
2
+ "packages": {
3
+ ".": {
4
+ "changelog-path": "CHANGELOG.md",
5
+ "release-type": "simple",
6
+ "bump-minor-pre-major": true,
7
+ "bump-patch-for-minor-pre-major": true,
8
+ "draft": false,
9
+ "prerelease": false,
10
+ "version-file": ".version.txt",
11
+ "extra-files": [
12
+ {
13
+ "type": "generic",
14
+ "path": "lib/dapr/version.rb"
15
+ }
16
+ ],
17
+ "exclude-paths": [
18
+ ".release-please-manifest.json",
19
+ ".version.txt",
20
+ "lib/dapr/version.rb",
21
+ ".rubocop.yml",
22
+ ".overcommit.yml",
23
+ "coverage/coverage.json"
24
+ ]
25
+ }
26
+ },
27
+ "$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json"
28
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ ".": "0.2.2"
3
+ }
data/.version.txt ADDED
@@ -0,0 +1 @@
1
+ 0.2.2
data/CHANGELOG.md CHANGED
@@ -1,5 +1,35 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.2.2](https://github.com/rubyists/dapr-ruby-client/compare/v0.2.1...v0.2.2) (2024-06-02)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * It helps to check out the code before building a gem ([#24](https://github.com/rubyists/dapr-ruby-client/issues/24)) ([8bfd14e](https://github.com/rubyists/dapr-ruby-client/commit/8bfd14eee9b548916afe028fc19a4c1a6088ec78))
9
+
10
+ ## [0.2.1](https://github.com/rubyists/dapr-ruby-client/compare/v0.2.0...v0.2.1) (2024-06-02)
11
+
12
+
13
+ ### Features
14
+
15
+ * Adds separate callable gem publish workflow ([#21](https://github.com/rubyists/dapr-ruby-client/issues/21)) ([96dbb03](https://github.com/rubyists/dapr-ruby-client/commit/96dbb034fcc2fdc8e6a51bba92250eeffe5e7630))
16
+
17
+
18
+ ### Bug Fixes
19
+
20
+ * Corrects release flow so gem does not require release ([#22](https://github.com/rubyists/dapr-ruby-client/issues/22)) ([5ea0bca](https://github.com/rubyists/dapr-ruby-client/commit/5ea0bca485f94204e468ac425d3dd0619088dacb))
21
+
22
+ ## [0.2.0](https://github.com/rubyists/dapr-ruby-client/compare/v0.1.27...v0.2.0) (2024-06-02)
23
+
24
+
25
+ ### ⚠ BREAKING CHANGES
26
+
27
+ * **dep:** Adds overcommit development dependency ([#19](https://github.com/rubyists/dapr-ruby-client/issues/19))
28
+
29
+ ### Features
30
+
31
+ * **dep:** Adds overcommit development dependency ([#19](https://github.com/rubyists/dapr-ruby-client/issues/19)) ([37687b1](https://github.com/rubyists/dapr-ruby-client/commit/37687b197c61374613b8a88f7996a1adb1980bd1))
32
+
3
33
  ## [0.1.0] - 2024-04-15
4
34
 
5
35
  - Initial release
data/Readme.adoc CHANGED
@@ -99,7 +99,7 @@ sub.start! <5>
99
99
  +
100
100
  NOTE: The handler can be anything that responds to `#call`, such as a lambda, proc, or instance. Sky's the limit! (Dependency injection, anyone?)
101
101
  +
102
- <2> The name of the Dapr pubsub component this subscriber will utilize.
102
+ <2> The name of the Dapr pubsub component this subscriber will utilize.
103
103
  <3> The name of the topic(s) to subscribe to.
104
104
  +
105
105
  TIP: Multiple topics can be subscribed to simultaneously by passing an array of topic names to the `topics` argument.
@@ -148,3 +148,13 @@ To install this gem on your local machine, run `bundle exec rake install`. To re
148
148
  == Contributing
149
149
 
150
150
  Bug reports and pull requests are welcome on GitHub at https://github.com/rubyists/dapr.
151
+
152
+ === Conventional Commits
153
+
154
+ This project uses Conventional Commits for commit messages. Please follow the guidelines at https://www.conventionalcommits.org/en/v1.0.0/[conventionalcommits.org].
155
+
156
+ === Overcommit
157
+
158
+ This project uses https://github.com/sds/overcommit[overcommit] to enforce repository policies. Please ensure you have it installed and configured before contributing.
159
+
160
+ tl;dr;: `overcommit --install && overcommit --sign`
@@ -1 +1 @@
1
- {"timestamp":1715471428,"command_name":"Unit Tests","files":[{"filename":"/home/bougyman/rubyists/dapr/lib/dapr.rb","covered_percent":100.0,"coverage":{"lines":[null,null,1,1,null,null,1,1,3,null,null,null,1,1,1,1,1,null,null]},"covered_strength":1.2,"covered_lines":10,"lines_of_code":10},{"filename":"/home/bougyman/rubyists/dapr/lib/dapr/client.rb","covered_percent":100.0,"coverage":{"lines":[null,null,1,1,1,1,1,null,1,1,null,1,1,1,1,1,null,1,4,null,1,1,null,null,1,8,null,null,1,1,null,null,1,11,null,null,null,1,1,null,1,5,null,null,1,1,1,1,null,1,null,null,1,2,null,null,null,null,null]},"covered_strength":1.7575757575757576,"covered_lines":33,"lines_of_code":33},{"filename":"/home/bougyman/rubyists/dapr/lib/dapr/client/lock.rb","covered_percent":100.0,"coverage":{"lines":[null,null,1,1,null,1,1,1,null,1,null,1,1,null,null,1,null,null,1,null,1,1,null,1,6,6,null,null,null,null,null,null,1,6,6,null,null,null,1,6,6,5,5,null,null,1,null,null,null,1,4,4,4,null,3,3,null,null,1,null,null,1,18,null,null,null,null,null]},"covered_strength":3.0606060606060606,"covered_lines":33,"lines_of_code":33}],"metrics":{"covered_percent":100.0,"covered_strength":2.25,"covered_lines":76,"total_lines":76}}
1
+ {"timestamp":1716154010,"command_name":"Unit Tests","files":[{"filename":"/home/bougyman/rubyists/dapr/lib/dapr.rb","covered_percent":100.0,"coverage":{"lines":[null,null,1,1,null,null,1,1,5,null,null,null,1,1,1,1,1,null,null]},"covered_strength":1.4,"covered_lines":10,"lines_of_code":10},{"filename":"/home/bougyman/rubyists/dapr/lib/dapr/client.rb","covered_percent":100.0,"coverage":{"lines":[null,null,1,1,1,1,1,null,1,1,null,1,1,1,1,1,null,1,4,null,1,1,null,null,1,9,null,null,1,1,null,null,1,12,null,null,null,1,1,null,1,5,null,null,1,1,1,1,null,1,null,null,1,1,null,null,null,null,null]},"covered_strength":1.7878787878787878,"covered_lines":33,"lines_of_code":33},{"filename":"/home/bougyman/rubyists/dapr/lib/dapr/client/configuration.rb","covered_percent":100.0,"coverage":{"lines":[null,null,1,null,1,1,1,null,1,null,1,1,null,null,1,null,null,1,null,1,1,null,1,1,1,null,null,null,null,null,null,null,1,1,1,1,null,null,1,1,1,null,null,null,null,null]},"covered_strength":1.0,"covered_lines":21,"lines_of_code":21},{"filename":"/home/bougyman/rubyists/dapr/lib/dapr/client/lock.rb","covered_percent":100.0,"coverage":{"lines":[null,null,1,1,null,1,1,1,null,1,null,1,1,null,null,1,null,null,1,null,1,1,null,1,6,6,null,null,null,null,null,null,1,6,6,null,null,null,1,6,6,5,5,null,null,1,null,null,null,1,4,4,4,null,3,3,null,null,1,null,null,1,18,null,null,null,null,null]},"covered_strength":3.0606060606060606,"covered_lines":33,"lines_of_code":33}],"metrics":{"covered_percent":100.0,"covered_strength":2.0103092783505154,"covered_lines":97,"total_lines":97}}
@@ -0,0 +1,46 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative '../client'
4
+
5
+ module Rubyists
6
+ module Dapr
7
+ module Client
8
+ # Handles publishing messages to Dapr pub/sub topics
9
+ class Configuration
10
+ # Include the client module
11
+ include Client
12
+ include SemanticLogger::Loggable
13
+
14
+ # The name of the configuration component, the keys we care about, and the metadata
15
+ attr_reader :store_name, :keys, :metadata
16
+
17
+ # The proto class for the GetConfiguration request
18
+ ConfigurationRequest = ::Dapr::Proto::Runtime::V1::GetConfigurationRequest
19
+ # The proto class for the GetConfiguration response
20
+ ConfigurationResponse = ::Dapr::Proto::Runtime::V1::GetConfigurationResponse
21
+ DEFAULT_STORE_NAME = 'dapr-config'
22
+
23
+ def self.get(keys = [], store_name: DEFAULT_STORE_NAME, metadata: {})
24
+ configuration = new(store_name, keys:, metadata:)
25
+ configuration.get
26
+ end
27
+
28
+ # Initialize the Configuration object
29
+ #
30
+ # @param store_name [String] The name of the Dapr Configuration component to use
31
+ # @param keys [Array<String>] The keys to retrieve from the configuration store (empty means all)
32
+ # @param metadata [Hash] Optional metadata to pass to the Dapr configuration store
33
+ def initialize(store_name, keys: [], metadata: {})
34
+ @store_name = store_name
35
+ @keys = Array(keys)
36
+ @metadata = metadata
37
+ end
38
+
39
+ def get
40
+ logger.debug('Getting configuration', keys:, store_name:)
41
+ singleton.get_configuration(ConfigurationRequest.new(store_name:, keys:, metadata:))
42
+ end
43
+ end
44
+ end
45
+ end
46
+ end
data/lib/dapr/version.rb CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  module Rubyists
4
4
  module Dapr
5
- VERSION = '0.1.26'
5
+ # x-release-please-start-version
6
+ VERSION = '0.2.2'
7
+ # x-release-please-end
6
8
  end
7
9
  end
data/oci/Containerfile CHANGED
@@ -33,9 +33,10 @@ RUN bundle config set build.nokogiri --use-system-libraries && \
33
33
  RUN rm -rf node_modules tmp/cache app/assets vendor/assets spec
34
34
 
35
35
  ############### Build step done ###############
36
- FROM docker.io/ruby:3.3.0-alpine3.19
37
36
  ARG ALPINE_VERSION=3.19
38
37
  ARG RUBY_VERSION=3.3.1
38
+ FROM docker.io/$RUBY_VERSION-alpine$ALPINE_VERSION
39
+
39
40
  ARG APP_ROOT=/app
40
41
 
41
42
  WORKDIR $APP_ROOT
@@ -45,4 +46,4 @@ RUN apk --update --no-cache add coreutils curl bash runit
45
46
  COPY --from=build-env /usr/local/bundle/ /usr/local/bundle/
46
47
  COPY --from=build-env /bin/snooze /bin/snooze
47
48
 
48
- CMD ['bundle', 'exec', 'puma', '-C', 'config/puma.rb']
49
+ CMD ['/bin/sh']
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dapr
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.26
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tj (bougyman) Vanderpoel
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2024-05-14 00:00:00.000000000 Z
12
+ date: 2024-06-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: dapr-ruby
@@ -47,14 +47,18 @@ extensions: []
47
47
  extra_rdoc_files: []
48
48
  files:
49
49
  - ".overcommit.yml"
50
+ - ".release-please-config.json"
51
+ - ".release-please-manifest.json"
50
52
  - ".rspec"
51
53
  - ".rubocop.yml"
54
+ - ".version.txt"
52
55
  - CHANGELOG.md
53
56
  - Rakefile
54
57
  - Readme.adoc
55
58
  - coverage/coverage.json
56
59
  - lib/dapr.rb
57
60
  - lib/dapr/client.rb
61
+ - lib/dapr/client/configuration.rb
58
62
  - lib/dapr/client/lock.rb
59
63
  - lib/dapr/client/publisher.rb
60
64
  - lib/dapr/service.rb