Bug #2638
Error: channel already exists in bag
Status: | Resolved | Start date: | 08/01/2016 | |
---|---|---|---|---|
Priority: | Normal | Due date: | ||
Assignee: | - | % Done: | 100% | |
Category: | - | |||
Target version: | Robotics Service Bus - rsb-0.15 |
Description
Seens while recording performance tests using the most recent rsbag version.
<WARN> [13:10:41] [main thread] rsb.introspection variables.lisp (call-with-local-database with-recursive-lock-thunk) - Condition The channel #<SYNCHRONIZED-CHANNEL "/__rsb/introspection/participants/:.rsb.protocol.introspection.Hello" (0) (RSB-EVENT-0.9 .rsb.protocol.introspection.Hello) {100C778343}> already exists in bag #<SYNCHRONIZED-BAG "logger-compact-Mon Aug 01 13:10:28 CEST 2016.tide" -w (3) {100B6C4313}>. Ignore the failure to RSB.EVENT-PROCESSING:DISPATCH datum #<EVENT /__rsb/introspection/participants/C350B3EA-8A87-4710-A962-32DAD6A6B784/ #(10 8 108 105 115 116 101 110 101 114 18 16 195 80 179 234 138 135 71 16 169 98 50 218 214 166 183 132 34 1 47 42 1 84 50 62 115 111 99 107 101 116 58 47 47 108 111 99 97 108 104 111 115 116 58 53 53 53 53 53 47 35 67 51 ...) (414) FA783AF8> in #<#<STANDARD-CLASS "(RSB.EVENT-PROCESSING:ERROR-POLICY-HANDLER-MIXIN RSB.EVENT-PROCESSING:RESTART-HANDLER-MIXIN RSB.EVENT-PROCESSING:RESTART-DISPATCHER-MIXIN RSB.EVENT-PROCESSING:FILTERING-PROCESSOR-MIXIN RSB.EVENT-PROCESSING:DELIVER-TIMESTAMP-MIXIN RSB.EVENT-PROCESSING:BROADCAST-PROCESSOR RSB.EVENT-PROCESSING:ERROR-POLICY-MIXIN)" {100DC55733}> {100DCEA3B3}>.
Associated revisions
Improved if-does-not-exist parameter of bag-channel in src/{protocol,bag}.lisp
refs #2638
- src/protocol.lisp (bag-channel): adapted description of
if-does-not-exist keyword parameter - src/bag.lisp (bag-channel bag string): use
`error-behavior-restart-case' to handle the if-does-not-exist argument - test/bag.lisp (test bag-root::bag-channel): new test; Smoke test for
the `bag-channel' method on the `bag' class
Allow atomic creation of non-existing channels in src/bag.lisp
Previously, ensuring the existence of a channel could only be done
as
(unless (bag-channel ... :if-does-not-exist nil))
(setf (bag-channel ...) ...)
which is racy. Ensuring the existence of a channel can now be performed
atomically via
(bag-channel ... :if-does-not-exist (lambda (...)
(invoke-restart 'create ...)))
fixes #2638
- src/protocol.lisp (bag-channel): mention `create' restart in
documentation string - src/bag.lisp (add-channel): new helper function for creating a channel
(bag-channel bag string): establish `create' restart; use
`add-channel'
(setf bag-channel list bag string): use `add-channel' - src/package.lisp (package rsbag): added exported symbol create
- src/rsb/protocol.lisp (make-channel-for): adapted documentation string
- src/rsb/channel-strategies.lisp (name): removed; no longer needed
(ensure-channel-for channel-connection event ensure-channel-mixin):
use `create' restart in case the channel does not exist
(make-channel-for participant-channel-connection event ensure-channel-mixin):
return meta-data and transform as two values instead of creating the
channel - test/bag.lisp (test bag-root::bag-channel): use `create' restart
Fixed name clash in bag-{cat,info}/package.lisp
refs #2638
- bag-cat/package.lisp (package rsbag.tools.cat): added
shadowing-import-form rsb.formatting symbol create - bag-info/package.lisp (package rsbag.tools.info): likewise
History
#1 Updated by J. Wienke about 8 years ago
- Subject changed from Warning about channel already existing to Error: channel already exists in bag
This also happens with this older version:
rsbag record version 0.14.9-g632ea9d SBCL version 1.3.5.40-2024ed9 RSB version 0.14.54-ga045934 RSBAG version 0.14.6-g3f6fa4c RSBAG-TIDELOG version 0.14.6-g3f6fa4c
#2 Updated by J. Moringen about 8 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100
Applied in changeset rsbag-cl|62e299e61a0dcf31cd2c36bb9bb1e7b7f9b1e489.