You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When creating multiple outlets with the same alias, ockam command doesn't report a conflict and only the last outlet is listed in the status.
See the outlet listed by show.
$ ockam tcp-outlet create --to 127.0.0.1:1080 --alias my-alias --from outlet1
Creating TCP Outlet to 127.0.0.1:1080...
There is no node, on this machine, marked as your default.
Creating a new Ockam node for you...
Created a new node named default
Marked this node as your default, on this machine.
✔︎ Created a new TCP Outlet on node default from address /service/outlet1 to 127.0.0.1:1080
$ ockam node show default
Node:
Name: default (Default)
Status: UP
Route To Node:
Short: /node/default
Verbose: /dnsaddr/localhost/tcp/56734
Identity: Pc25b4dbe8acecda55438a6babcd209c86fae806f0b12e3d6c8d9eafe44f1b184
Transports:
Transport:
Type: TCP
Mode: Listening
Socket: 127.0.0.1:56734
Worker: <none>
FlowControlId: 7fa70d15c9a1b5e430ad1c544c7b8c9e
Secure Channel Listeners:
Listener:
Address: /service/api
FlowControlId: 9ece9ed3123ec83081b8179c284a225a
Inlets:
Outlets:
Outlet:
Forward Address: 127.0.0.1:1080
Address: /service/outlet1
Services:
Service:
Type: uppercase
Address: /service/uppercase
Service:
Type: echo
Address: /service/echo
davidebaldo@mac ~/workspace/github/build-trust/ockam
$ ockam tcp-outlet create --to 127.0.0.1:1080 --alias my-alias --from outlet2
Creating TCP Outlet to 127.0.0.1:1080...
✔︎ Created a new TCP Outlet on node default from address /service/outlet2 to 127.0.0.1:1080
$ ockam node show default
Node:
Name: default (Default)
Status: UP
Route To Node:
Short: /node/default
Verbose: /dnsaddr/localhost/tcp/56734
Identity: Pc25b4dbe8acecda55438a6babcd209c86fae806f0b12e3d6c8d9eafe44f1b184
Transports:
Transport:
Type: TCP
Mode: Listening
Socket: 127.0.0.1:56734
Worker: <none>
FlowControlId: 7fa70d15c9a1b5e430ad1c544c7b8c9e
Secure Channel Listeners:
Listener:
Address: /service/api
FlowControlId: 9ece9ed3123ec83081b8179c284a225a
Inlets:
Outlets:
Outlet:
Forward Address: 127.0.0.1:1080
Address: /service/outlet2
Services:
Service:
Type: uppercase
Address: /service/uppercase
Service:
Type: echo
Address: /service/echo
Hi all! So I tried replicating this issue and I believe it's been fixed sometime over the last weeks because creating the second outlet with the duplicate name reports an error as intended. See the transcript below:
OCK500
× Ockam Error [origin: Node, kind: AlreadyExists] at implementations/rust/ockam/ockam_api/src/nodes/service/portals.rs:59:24
│ --- Details ---
│ - Caused by: A TCP outlet with alias 'my-alias' already exists
│ - possible root cause `alloc::string::String`: A TCP outlet with alias 'my-alias' already exists
│ debug output:
│ "A TCP outlet with alias 'my-alias' already exists"
│ --- Captured Spantrace ---
│
│ --------------------------
│ (origin: Api, kind: Invalid, source location: /Users/nidnogg/localdev/ockam/implementations/rust/ockam/ockam_core/src/api.rs:144:44)
help: Please report this issue, with a copy of your logs, to https://github.com/build-trust/ockam/issues
Version 0.94.0, hash: de5b2f78e083d6a47330b7aab7b7f0413f50846d
Observed behavior
When creating multiple outlets with the same alias, ockam command doesn't report a conflict and only the last outlet is listed in the status.
See the outlet listed by show.
Steps to reproduce
Expected behavior
The second outlet creation onward should fail since the alias is already in-use.
Ockam Version
0.90.0/8a77aa9dec024b05d9da00f4e75acd188ff6e785
The text was updated successfully, but these errors were encountered: