Skip to content

Commit

Permalink
feat: Additional admin API cleanup to remove unnecessary outputs, add…
Browse files Browse the repository at this point in the history
… transport types to lieceners, and add max queue size
  • Loading branch information
driskell committed Mar 1, 2025
1 parent 1f97a54 commit 788e098
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions lc-lib/receiver/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ func (a *apiStatus) Update() error {
a.SetEntry("activeConnections", api.Number(len(a.r.connectionStatus)))
a.SetEntry("queuePayloads", api.Number(len(a.r.spool)))
a.SetEntry("queueSize", api.Number(a.r.spoolSize))
a.SetEntry("maxQueueSize", api.Number(a.r.generalConfig.MaxQueueSize))
a.r.connectionLock.RUnlock()

return nil
Expand Down
2 changes: 2 additions & 0 deletions lc-lib/receiver/pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,8 @@ func (r *Pool) updateReceivers(newConfig *config.Config) {
newReceivers[newReceiversByListen[listen]] = &poolReceiverStatus{config: cfgEntry, listen: listen, active: true}
receiverApi := &api.KeyValue{}
receiverApi.SetEntry("listen", api.String(listen))
receiverApi.SetEntry("transport", api.String(cfgEntry.Transport))
receiverApi.SetEntry("name", api.String(cfgEntry.Name))
if newReceiversByListen[listen].SupportsAck() {
// Only applies if supports ack
receiverApi.SetEntry("maxPendingPayloads", api.Number(cfgEntry.MaxPendingPayloads))
Expand Down

0 comments on commit 788e098

Please sign in to comment.