PLCcom MQTT Core Java class library documentation
First steps PLCcom MQTT Core for Java
The PLCcom MQTT Core module is the shared technical foundation used by the PLCcom MQTT Client and PLCcom MQTT Broker modules. It contains common limits, base exceptions, PKI helpers, result quality support and internal protocol code that keeps MQTT behavior consistent across both delivered libraries.
plccom-mqtt-client, plccom-mqtt-broker, or both.
Maven will bring plccom-mqtt-core automatically. Core is documented
so developers can understand shared result objects, diagnostics, PKI handling
and common exception behavior that appear in Client and Broker APIs.
How to read this API
Core is the shared foundation below the customer-facing Client and Broker libraries. It is intentionally smaller than the Client and Broker Javadocs. The classes documented here are the shared types that application developers may see when they handle results, diagnostics, PKI stores, TLS certificate decisions, base exceptions or common protocol limits. Protocol packet internals remain implementation detail and are not part of the supported SDK contract.
Client and Broker use the same result quality model, base exception hierarchy and diagnostic event objects. This makes error handling feel consistent across the SDK.
The folder-based PKI store, own certificate handling and remote certificate validation contracts live in Core so Client and Broker follow the same PLCcom trust-store pattern.
Core owns common MQTT limits and internal protocol support. Only the stable shared API is documented; wire parsing and state machines remain intentionally hidden.
Main entry points
| Entry point | Use it when | Typical source |
|---|---|---|
OperationResult | You want PLCcom-style quality, localized text and optional inner exception information from higher-level results. | Returned by Client and Broker result classes. |
OperationResult.eQuality | You need a stable machine-readable result state such as good, timeout, protocol error, authorization failure or certificate problem. | Available through every PLCcom MQTT operation result. |
PlccomMqttException | You want to catch broad MQTT SDK errors without handling each specialized exception separately. | Thrown by Client and Broker APIs. |
PlccomMqttPkiStore | You manage trusted, rejected, issuer and own certificates in the PLCcom folder layout. | Used by TLS options and certificate management tooling. |
PlccomMqttDiagnosticEvent | You want structured runtime warnings and errors without binding the SDK to a logging framework. | Emitted through Client and Broker diagnostic listeners. |
PlccomMqttLimits | You configure shared MQTT size and protocol bounds. | Used by advanced Client/Broker configuration. |
Maven dependency
Most applications should not need this dependency explicitly. If you intentionally use shared Core API types, use the same v2 release line as Client and Broker:
<dependency>
<groupId>com.indi-an.plccom</groupId>
<artifactId>plccom-mqtt-core</artifactId>
<version>2.x.x</version>
</dependency>
Replace 2.x.x with the concrete PLCcom MQTT v2 release version you
use.
What belongs into the Core Javadoc?
The Core Javadoc describes only supported API surface that application developers may see through Client or Broker usage. It does not expose the internal packet parser, wire codec, flow-state helpers or session internals as customer contracts.
| Included in Core Javadoc | Excluded from Core Javadoc |
|---|---|
| Shared public base exceptions used by Client and Broker APIs. | Classes below com.plccom.mqtt.core.internal. |
| Shared public limits, result base types and quality values used by the delivered APIs. | MQTT packet body parsers, property codecs, internal topic alias tables, QoS state machines and retained/session implementation helpers. |
| PKI store and own-certificate APIs that are intended for TLS trust management. | License-gate internals and other implementation-only support classes. |
Why the Core Javadoc is intentionally small
A Javadoc page creates expectations. If an internal wire class appears in the public documentation, developers may reasonably assume that it is a supported extension point. For Core this would be misleading: the protocol helpers are allowed to change when MQTT conformance, interoperability or robustness require it. The stable customer-facing APIs live in the Client and Broker modules.
Useful Core concepts
| Concept | Why it matters |
|---|---|
| Operation result and quality | Client and Broker result objects share a PLCcom-style quality model so applications can handle success and failure consistently. |
| Localized result text | Quality values can be turned into readable English or German messages for tools, diagnostics and customer-facing status displays. |
| PKI store | The folder-based trust store follows the PLCcom family pattern with own, trusted, issuer and rejected certificate areas. |
| Certificate validation events | Rejected or newly seen certificates can be surfaced to applications and tools so operators can trust or reject them deliberately. |
| Base exceptions | Client and Broker exceptions share common ancestry for broader error handling. |
| Diagnostic events | Network, certificate, protocol and callback problems can be reported as structured events with severity information. |
| Protocol limits | Shared bounds keep MQTT packet size, string and binary handling consistent. |
When should you look at Core?
| Situation | What Core explains |
|---|---|
| A Client or Broker method returns a result object. | The common quality model, result text and inner exception pattern. |
A TLS connection places a certificate in rejected. | The PLCcom PKI folder structure and certificate trust workflow. |
| A diagnostic listener receives a warning. | The event category, severity, component and operation fields. |
| You catch a broad MQTT SDK exception. | The common exception base and specialized protocol, timeout, TLS or authentication subclasses. |
Recommended developer path
| Goal | Use this module first |
|---|---|
| Connect to an existing broker, publish and subscribe. | PLCcom MQTT Client |
| Run a broker inside your Java process. | PLCcom MQTT Broker |
| Share common exception, PKI, result or limit handling between advanced integrations. | PLCcom MQTT Core |
Back to PLCcom MQTT SDK overview.
Copyright (c) Indi.An GmbH. PLCcom is a trademark of Indi.An GmbH.
| Package | Description |
|---|---|
| com.plccom.mqtt | |
| com.plccom.mqtt.client | |
| com.plccom.mqtt.core | |
| com.plccom.mqtt.diagnostics | |
| com.plccom.mqtt.pki |