Skip to content

Commit

Permalink
Renamed progressive calls -> progressive call invocations to be in sy…
Browse files Browse the repository at this point in the history
…nc with WAMP spec
  • Loading branch information
KSDaemon committed Jun 18, 2023
1 parent 691c03b commit a3e99fe
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 21 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ The currently maintained version of this module is 3.x. Earlier major versions
| Feature | Supported |
|------------------------------|-----------|
| progressive_call_results | Yes |
| progressive_calls | Yes |
| progressive_call_invocations | Yes |
| call_timeout | Yes |
| call_canceling | Yes |
| caller_identification | Yes |
Expand Down
2 changes: 1 addition & 1 deletion client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -821,7 +821,7 @@ func (c *Client) CallProgressive(ctx context.Context, procedure string, sendProg
return nil, ErrNotConn
}

if !c.sess.HasFeature(wamp.RoleDealer, wamp.FeatureProgressiveCalls) {
if !c.sess.HasFeature(wamp.RoleDealer, wamp.FeatureProgCallInvocations) {
return nil, ErrProgCallNotSupportedByRouter
}

Expand Down
2 changes: 1 addition & 1 deletion client/error.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ var (
ErrPPTSchemeInvalid = errors.New("ppt scheme provided is invalid")
ErrPPTSerializerInvalid = errors.New("ppt serializer provided is invalid or not supported")
ErrSerialization = errors.New("can not serialize/deserialize payload")
ErrProgCallNotSupportedByRouter = errors.New("progressive calls are not supported by the router")
ErrProgCallNotSupportedByRouter = errors.New("progressive call invocations are not supported by the router")
)
14 changes: 7 additions & 7 deletions examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,10 @@ Nexus supports [Payload PassThru Mode](https://wamp-proto.org/wamp_latest_ietf.h
4. Run the callee with `go run ppt/callee/callee.go`
5. Run the caller with `go run ppt/caller/caller.go`

## Progressive calls (and progressive results)
## Progressive call invocations (and progressive call results)

Nexus supports [Progressive Calls](https://wamp-proto.org/wamp_latest_ietf.html#name-progressive-calls)
dealer feature. Check and run examples in [rpc_progressive_calls](./rpc_progressive_calls) and
Nexus supports [Progressive Call Invocations](https://wamp-proto.org/wamp_latest_ietf.html#name-progressive-call-invocation)
dealer feature. Check and run examples in [rpc_progressive_invocations](./rpc_progressive_invocations) and
[rpc_progress_calls_results](./rpc_progress_calls_results) folders.

Please note that invocation handler is invoked with payload chunks in the same order they are received through the wire
Expand All @@ -139,9 +139,9 @@ cancel deadline is pushed forward in timeline. This can help processing progress
To use timeouted context for the whole call - do not specify `timeout` option within intermediate data chunks.

1. Run the server with `go run server/server.go`
2. Run the callee which accumulates progressive call data chunks with `go run rpc_progressive_calls/callee/callee.go`
3. Run the caller which makes progressive call and sends data chunks with `go run rpc_progressive_calls/caller/caller.go`
4. Run the callee which is aware of progressive call data chunks and at same time sends
2. Run the callee which accumulates progressive call invocations data chunks with `go run rpc_progressive_invocations/callee/callee.go`
3. Run the caller which makes progressive call invocations and sends data chunks with `go run rpc_progressive_invocations/caller/caller.go`
4. Run the callee which is aware of progressive call invocations data chunks and at same time sends
progressive results with `go run rpc_progress_calls_results/callee/callee.go`
5. Run the caller which makes progressive call and sends data chunks and at the same time
5. Run the caller which makes progressive call invocation and sends data chunks and at the same time
receives progress results with `go run rpc_progress_calls_results/caller/caller.go`
2 changes: 1 addition & 1 deletion router/dealer.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ var dealerRole = wamp.Dict{
wamp.FeatureCallerIdent: true,
wamp.FeaturePatternBasedReg: true,
wamp.FeatureProgCallResults: true,
wamp.FeatureProgressiveCalls: true,
wamp.FeatureProgCallInvocations: true,
wamp.FeatureSessionMetaAPI: true,
wamp.FeatureSharedReg: true,
wamp.FeatureRegMetaAPI: true,
Expand Down
20 changes: 10 additions & 10 deletions wamp/roles_reatures.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@ const (
RoleSubscriber = "subscriber"

// RPC features
FeatureCallCanceling = "call_canceling"
FeatureCallTimeout = "call_timeout"
FeatureCallerIdent = "caller_identification"
FeaturePatternBasedReg = "pattern_based_registration"
FeatureProgCallResults = "progressive_call_results"
FeatureProgressiveCalls = "progressive_calls"
FeatureSessionMetaAPI = "session_meta_api"
FeatureSharedReg = "shared_registration"
FeatureRegMetaAPI = "registration_meta_api"
FeatureTestamentMetaAPI = "testament_meta_api"
FeatureCallCanceling = "call_canceling"
FeatureCallTimeout = "call_timeout"
FeatureCallerIdent = "caller_identification"
FeaturePatternBasedReg = "pattern_based_registration"
FeatureProgCallResults = "progressive_call_results"
FeatureProgCallInvocations = "progressive_call_invocations"
FeatureSessionMetaAPI = "session_meta_api"
FeatureSharedReg = "shared_registration"
FeatureRegMetaAPI = "registration_meta_api"
FeatureTestamentMetaAPI = "testament_meta_api"

// PubSub features
FeaturePatternSub = "pattern_based_subscription"
Expand Down

0 comments on commit a3e99fe

Please sign in to comment.