Make source and receiver understand the same value
Delivering 42 to a screen does not establish correct integration. Identify the quantity, unit, point and observation time. A PSI value interpreted as bar can be a serious engineering error even when every message arrives.
A data contract is a shared form with agreed meanings for fields, units and states. Establish it before coding. Version changes and handling of older formats prevent receivers from inventing their own interpretations.
Separate capture, processing and receipt times because delay can occur at different stages. These timestamps identify bottlenecks and data age rather than leaving users to guess whether a newly received value is current.
Scroll the diagram horizontally to inspect all details.
1. Agree on a data contract before integration
A protocol describes transport; a contract describes meaning. Agree on reading identity, unit, scale, numerical type, time and quality. Sharing MQTT or OPC UA does not establish identical interpretation.
- Use asset_id and reading_point_id independent of camera IP addresses.
- Distinguish captured_at, processed_at and received_at with explicit time zones.
- Represent valid, invalid and stale with reasons rather than substituting zero.
- Include schema_version, model_version and event_id for traceability and deduplication.
2. Illustrative payload for design
This schema explains a design concept; it is not a published callable API. A null value needs status and reason. If confidence is included, define its meaning rather than presenting it as accuracy automatically.
{
"schema_version": "1",
"event_id": "example-event-001",
"reading_point_id": "example-pressure-01",
"captured_at": "2026-01-01T00:00:00Z",
"value": null,
"unit": "bar",
"quality": "invalid",
"reason": "glare",
"model_version": "example-model"
} 3. Select the required protocol behavior
- MQTT: define topics, QoS, sessions, retained values and expiry. QoS does not guarantee exactly-once business effects across the complete pipeline.
- OPC UA: test information models, timestamps, StatusCode, certificates, namespaces, types and actual server permissions.
- Modbus: agree on register maps, scaling, signedness, byte/word order and polling intervals. Receiving a number does not establish the correct unit.
- HTTP APIs: specify authentication, timeout, retry, idempotency and explicit errors; do not return success when storage fails.
- Databases and historians: verify retention, time zones, duplicate policy and backfills before confirming connector support.
4. Design for network disruption
Size buffers from observation rates and intended outage coverage. Detect full storage, retry with backoff and deduplicate using event_id. Receivers need capture time, not just message arrival time.
Late information may be useful history but must not appear current without a state. Verify ordering and latest-state selection after restart; an old retained message is not a new observation.
5. Separate permissions and network boundaries
- Begin read-only and separate monitoring from command paths.
- Limit each account to necessary topics, nodes or endpoints and rotate credentials.
- Define OT/IT zones and approved paths; do not directly expose field devices to the internet.
- Test certificate validation, expiry and key-change recovery.
- Log necessary events without secrets and restrict image access.
6. Test jointly with the receiving system
- Use known negative, zero, decimal, range-boundary and invalid cases.
- Disconnect the network and verify buffering, retries and deduplication.
- Test reordered data, clock drift, storage exhaustion and unauthorized accounts.
- Verify tag/unit mapping and stale presentation on the actual receiving screen.
- Record versions, rollback and responsibility for each boundary.
Test meaning, not merely a connection indicator
Trace known values and invalid observations through messages, storage and the actual screen. This detects unit, rounding and field-mapping errors that connection tests do not reveal.
Simulate outages and retries. A repeated event should retain its identity; recovered values belong to history with original timestamps rather than silently reverting current displays.
Document connector and receiver versions and permissions. If validation covers only a test environment, state that boundary. Standards define communication, but actual support and configuration require project-specific confirmation.