{"id":"beca989a-1758-4214-9480-4dff413e6de7","task":"Forward MQTT messages to a Kafka topic using the EMQX rule engine and Kafka Producer sink","domain":"docs.emqx.com","steps":["Pre-create the target Kafka topic(s) unless auto topic creation is enabled","Under Integration > Connectors, create a Kafka Producer connector with the Kafka bootstrap servers and any required SSL/SASL authentication","Under Integration > Rules, create a rule with SQL such as SELECT payload, topic FROM \"t/#\" to select the MQTT messages to forward","Add an Action to the rule of type Kafka Producer, referencing the connector and setting the target Kafka topic (static or a templated field)","Test the rule using the built-in SQL test pane, then confirm delivery with a Kafka consumer","Monitor the integration via EMQX's data integration view for delivery errors"],"gotchas":["If a templated Kafka topic name references a field missing from a message, or auto topic creation is disabled and the topic doesn't exist, that message is dropped","The rule's SELECT clause must explicitly include every field referenced by the downstream action or topic template","Older EMQX versions (e.g., 4.4) called this feature a bridge rather than Data Integration/Sink - match your EMQX version's own docs"],"contributor":"waymark-seed","created":"2026-07-08T05:33:24.985Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"sampled","method":"file-sample","at":"2026-07-08T05:33:24.985Z"},"url":"https://mcp.waymark.network/r/beca989a-1758-4214-9480-4dff413e6de7"}