async-service 0.20.1 → 0.21.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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data/bake/async/service/configuration.rb +30 -0
- data/bake/async/service/controller.rb +22 -0
- data/lib/async/service/version.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +4 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: de59afc9bb1a297f08d89797f5cc1cab814aadb6fd867773a70a3c2b83bcf1d7
|
|
4
|
+
data.tar.gz: 07c8402c361ae967fd593616d1777367118687fa490b9bb8e5cb5e64003280c0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 777190197a4272ce2f8c726abdbf1b018e46af424ca68d9fbfa4eba8490912e3c9cbb9579490743bbddf384a3b4fa2159f38ec9d58c013badd9ce4642f9bfb68
|
|
7
|
+
data.tar.gz: 5976d4d560ddcb71e781bdd1ec9a304f7851ed3cb76f1f1d82fb590765fd4137cd463afabb4da78abead51f328ce5d55cd3b45d272056fa765be086c1531c835
|
checksums.yaml.gz.sig
CHANGED
|
Binary file
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Released under the MIT License.
|
|
4
|
+
# Copyright, 2024-2025, by Samuel Williams.
|
|
5
|
+
|
|
6
|
+
def initialize(context)
|
|
7
|
+
super
|
|
8
|
+
|
|
9
|
+
require "async/service/configuration"
|
|
10
|
+
|
|
11
|
+
@configuration = Async::Service::Configuration.new
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
attr :configuration
|
|
15
|
+
|
|
16
|
+
# Load the configuration from the given path.
|
|
17
|
+
# @parameter path [String] The path to the configuration file.
|
|
18
|
+
def load(path)
|
|
19
|
+
@configuration.load_file(path)
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
# List the available environments (all named environments).
|
|
23
|
+
def list
|
|
24
|
+
@configuration.environments.map(&:to_h)
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
# List the available services (those that define a service class).
|
|
28
|
+
def services
|
|
29
|
+
@configuration.services.map(&:to_h)
|
|
30
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Released under the MIT License.
|
|
4
|
+
# Copyright, 2024-2026, by Samuel Williams.
|
|
5
|
+
|
|
6
|
+
def initialize(context)
|
|
7
|
+
super
|
|
8
|
+
|
|
9
|
+
require "async/service/controller"
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
def run
|
|
13
|
+
controller.run
|
|
14
|
+
end
|
|
15
|
+
|
|
16
|
+
private
|
|
17
|
+
|
|
18
|
+
def controller
|
|
19
|
+
configuration = context.lookup("async:service:configuration").instance.configuration
|
|
20
|
+
|
|
21
|
+
return configuration.make_controller
|
|
22
|
+
end
|
data.tar.gz.sig
CHANGED
|
Binary file
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: async-service
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.21.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Samuel Williams
|
|
@@ -85,6 +85,8 @@ executables:
|
|
|
85
85
|
extensions: []
|
|
86
86
|
extra_rdoc_files: []
|
|
87
87
|
files:
|
|
88
|
+
- bake/async/service/configuration.rb
|
|
89
|
+
- bake/async/service/controller.rb
|
|
88
90
|
- bin/async-service
|
|
89
91
|
- context/best-practices.md
|
|
90
92
|
- context/deployment.md
|
|
@@ -124,7 +126,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
124
126
|
requirements:
|
|
125
127
|
- - ">="
|
|
126
128
|
- !ruby/object:Gem::Version
|
|
127
|
-
version: '3.
|
|
129
|
+
version: '3.3'
|
|
128
130
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
129
131
|
requirements:
|
|
130
132
|
- - ">="
|
metadata.gz.sig
CHANGED
|
Binary file
|