service_mesh 0.7.0 → 0.8.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: 966f879206d92063d0a9fb94576db740746b6809e629548df3cad531547b543f
4
- data.tar.gz: 0e411f07db7f14c1fd9e7bbe483a8d44d75c8bc13df6b111eb4ffdd8b0377d7e
3
+ metadata.gz: 1ef4f07d34ce8b6f4120004321a36ef5bd99e620e06564bb8c51a89ac5d8c2be
4
+ data.tar.gz: cd4798cd9b3fef7505093d6bec02d0e08ded4d9c16458b48ae872aa64348f5c1
5
5
  SHA512:
6
- metadata.gz: 9590a21777d4afacd500e6e294042a44ad31581a8688d32119e51d547e4c4917ecb7e5149b834862785971a8942e071f406ab590eb65aa3c81f1c9859f6e7a21
7
- data.tar.gz: 374757753729d92f5e20930aaef9739676f600a75eb6d9fbdfecf3194590e03c29c9c9f11a0d748105b645b9fdf94438412c276083a13716a321ec732faa166f
6
+ metadata.gz: 955ef2c6ba89a3cf0114678586832a2f1b033167174ee775d52590323fcaa7aa9bd1d961d502fab35714e608b3e70290533c2ff42c49712c36247c42b9947d82
7
+ data.tar.gz: 25214fe0310e2fd40f43f687b08f9189e8553f51b1de2ac635168afbf929c55993b086c388d453d73e2fc55925a660564a827187b41b629f7e6cc664ebc22536
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # service-mesh-ruby
2
2
 
3
- This version implements the Service Mesh API Specification v0.4.0.
3
+ This library implements the Service Mesh API Specification v0.5.0.
4
4
 
5
5
  service-mesh-ruby is the Ruby contract for the
6
6
  [Service Mesh API Specification](https://github.com/Paymentbox-com/service-mesh-api).
@@ -30,8 +30,8 @@ Requires Ruby 3.3 or newer. The gem has no runtime dependencies.
30
30
  - The consumer group is the `consumer_group` member of `Endpoint` and `Subscriber`, defaulting to
31
31
  `nil`. `CONSUMER_GROUP_NONE` is the value for no group.
32
32
  - The reserved metadata prefix `RESERVED_PREFIX` (`Mesh-`).
33
- - The metadata keys the specification defines: `HANDLER_ERROR_KEY`, `TIMEOUT_KEY`, `DEADLINE_KEY`,
34
- `DELIVERY_ATTEMPT_KEY`, and `MESSAGE_ID_KEY`.
33
+ - The metadata keys the specification defines: `HANDLER_ERROR_KEY`, `TIMEOUT_KEY`,
34
+ `DEADLINE_OFFSET_KEY`, `DEADLINE_KEY`, `DELIVERY_ATTEMPT_KEY`, and `MESSAGE_ID_KEY`.
35
35
  - The errors defined by the specification as `ServiceMesh::Error`: `ServiceMesh::KindMismatch`,
36
36
  `ServiceMesh::InvalidTarget`, and `ServiceMesh::NoDeploymentGroup`.
37
37
  - A conformance suite a transport runs against its own `Client` and
@@ -142,7 +142,7 @@ RSpec.shared_examples "a service mesh transport" do
142
142
  end
143
143
 
144
144
  it "carries an empty payload with no metadata" do
145
- serve(endpoints: [endpoint(route_target, ->(m) { m })])
145
+ serve(endpoints: [endpoint(route_target, ->(_) { message(route_target) })])
146
146
  reply = request(message(route_target))
147
147
  expect([reply.payload, reply.metadata]).to eq(["", {}])
148
148
  end
@@ -26,9 +26,15 @@ module ServiceMesh
26
26
  # caller waits for the reply, as a whole number of milliseconds.
27
27
  TIMEOUT_KEY = "Mesh-Timeout"
28
28
 
29
+ # Set by the requesting transport on a request. The value is how much
30
+ # earlier than the timeout the handler's deadline falls, as a whole number
31
+ # of milliseconds. Absent means 0.
32
+ DEADLINE_OFFSET_KEY = "Mesh-Deadline-Offset"
33
+
29
34
  # Set by the receiving transport on a message it hands to a handler. The
30
35
  # value is when the handler's result stops mattering, in RFC 3339 with
31
- # fractional seconds.
36
+ # fractional seconds. For a request it is the arrival time plus the
37
+ # timeout, minus the offset when the request carries one.
32
38
  DEADLINE_KEY = "Mesh-Deadline"
33
39
 
34
40
  # Set by the receiving transport on a message it hands to a handler. The
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ServiceMesh
4
- VERSION = "0.7.0"
4
+ VERSION = "0.8.0"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: service_mesh
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bryant Morrill
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2026-10-08 00:00:00.000000000 Z
12
+ date: 2026-12-04 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description:
15
15
  email: