diun icon indicating copy to clipboard operation
diun copied to clipboard

notif mqtt JSON is split in 2 messages

Open tobser opened this issue 10 months ago • 1 comments

Support guidelines

I've found a bug and checked that ...

  • [x] ... the documentation does not mention anything about my problem
  • [x] ... there are no open or closed issues that are related to my problem

Description

I have containers where my notificiations get split into two messages mqtt messages, these obviously fail to get parsed by my receiver.

Expected behaviour

I would expect this to be a single MQTT notification

Actual behaviour

it gets split into multible messages

Steps to reproduce

to reproduce i run diun image prune inside the container watch for the messages with mosquitto_sub -t 'portainer/#' -v

and restart the container. This results in these two messages:

portainer/diun {"diun_version":"v4.29.0","hostname":"ba0ad62dbde8","status":"new","provider":"docker","image":"docker.io/cthulhoo/ttrss-web-nginx:latest","hub_link":"https://hub.docker.com/r/cthulhoo/ttrss-web-nginx","mime_type":"application/vnd.docker.distribution.manifest.v2+json","digest":"sha256:997301a258ee6012ef165fe0dcc345d5792e48784aa17bb9f4af7002a701123a","created":"2025-02-08T17:20:19.980299124Z","platform":"linux/amd64","metadata":{"ctn_command":"/docker-entrypoint.sh nginx -g 'daemon off

portainer/diun '","ctn_createdat":"2025-02-09 09:08:33 +0100 CET","ctn_id":"753e26a35694e880fa9133d3ae9a3aec0a3a3e15264cde7eb274adce74ce35c8","ctn_names":"ttrss-web-nginx-1","ctn_size":"0B","ctn_state":"running","ctn_status":"Up 6 days (healthy)"}}

Diun version

v4.29.0

Docker info

Client: Docker Engine - Community
 Version:    27.5.1
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Docker Buildx (Docker Inc.)
    Version:  v0.20.0
    Path:     /usr/libexec/docker/cli-plugins/docker-buildx
  compose: Docker Compose (Docker Inc.)
    Version:  v2.32.4
    Path:     /usr/libexec/docker/cli-plugins/docker-compose

Server:
 Containers: 11
  Running: 11
  Paused: 0
  Stopped: 0
 Images: 19
 Server Version: 27.5.1
 Storage Driver: overlay2
  Backing Filesystem: zfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: true
 Logging Driver: json-file
 Cgroup Driver: systemd
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: bcc810d6b9066471b0b6fa75f557a15a1cbf31bb
 runc version: v1.2.4-0-g6c52b3f
 init version: de40ad0
 Security Options:
  apparmor
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.8.12-8-pve
 Operating System: Ubuntu 24.04.1 LTS
 OSType: linux
 Architecture: x86_64
 CPUs: 4
 Total Memory: 8GiB
 Name: portainer
 ID: 39f1a6eb-48f2-479d-ba10-6a50062f445b
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  127.0.0.0/8
 Live Restore Enabled: false

Docker Compose config


Logs

..

Additional info

No response

tobser avatar Feb 15 '25 10:02 tobser

Hum indeed, seems to be an issue with the metadata

crazy-max avatar Apr 13 '25 22:04 crazy-max