Skip to content

Commit

Permalink
feat(plc4go/cbus): improve logging of discoverer
Browse files Browse the repository at this point in the history
  • Loading branch information
sruehl committed Apr 18, 2023
1 parent 61045e6 commit 14ea38c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions plc4go/internal/cbus/Discoverer.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ func (d *Discoverer) Discover(ctx context.Context, callback func(event apiModel.

go func() {
for transportInstance := range transportInstances {
log.Debug().Stringer("transportInstance", transportInstance).Msg("submitting device scan")
d.deviceScanningQueue.Submit(ctx, d.deviceScanningWorkItemId.Add(1), d.createDeviceScanDispatcher(transportInstance.(*tcp.TransportInstance), callback))
}
}()
Expand Down
2 changes: 2 additions & 0 deletions plc4go/spi/transports/TransportInstance.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,12 @@ package transports
import (
"bufio"
"context"
"fmt"
"github.com/pkg/errors"
)

type TransportInstance interface {
fmt.Stringer
Connect() error
ConnectWithContext(ctx context.Context) error
Close() error
Expand Down

0 comments on commit 14ea38c

Please sign in to comment.