Skip to content

Add connectionName field and structured log format for sessions#120

Merged
willhoy merged 1 commit into
bloomberg:mainfrom
flamble:log-connection-name
Jun 3, 2026
Merged

Add connectionName field and structured log format for sessions#120
willhoy merged 1 commit into
bloomberg:mainfrom
flamble:log-connection-name

Conversation

@flamble
Copy link
Copy Markdown
Contributor

@flamble flamble commented Jun 1, 2026

The "Starting connection" log line now includes the AMQP client's connection_name property as a key=value field, making it easy to identify which application established a connection when ingesting logs into observability tooling.

The TLS status and SessionState output are also reformatted as consistent key=value pairs for easier log ingestion.

An integration test has been added to verify the connectionName and tlsEnabled fields appear in the "Starting connection" log line.

eg. From the tests

Starting connection for: connectionName="my-test-app" tlsEnabled=insecure id=1 vhost=/ disconnected=N paused=N authDenied=N ingressRemote=127.0.0.1:36678 ingressLocal=127.0.0.1 egressLocal=127.0.0.1:39452 egressRemote=127.0.0.1:5800 inBytes=0 inFrames=0 inPackets=0 inAvgLatencyMs=0 outBytes=0 outFrames=0 outPackets=0

The "Starting connection" log line now includes the AMQP client's
`connection_name` property as a key=value field, making it easy to
identify which application established a connection when ingesting
logs into observability tooling.

The TLS status and `SessionState` output are also reformatted as
consistent key=value pairs for easier log ingestion.

An integration test has been added to verify the `connectionName`
and `tlsEnabled` fields appear in the "Starting connection" log line.

```
Starting connection for: connectionName="my-test-app" tlsEnabled=insecure id=1 vhost=/ disconnected=N paused=N authDenied=N ingressRemote=127.0.0.1:36678 ingressLocal=127.0.0.1 egressLocal=127.0.0.1:39452 egressRemote=127.0.0.1:5800 inBytes=0 inFrames=0 inPackets=0 inAvgLatencyMs=0 outBytes=0 outFrames=0 outPackets=0
```
@willhoy willhoy merged commit 86ae9a0 into bloomberg:main Jun 3, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants