Just a second...

Introducing Diffusion

Diffusion™ from Push Technology provides realtime messaging, optimized for streaming data over the internet.

Flexibility, responsiveness and interactivity are some of the fundamental requirements for today’s application architecture. But challenges created by unreliable and congested networks stand in the way – particularly for mobile and IoT.

The answer? A realtime integration model, with better data efficiency to address these challenges, while reducing data costs at the same time.

With Push Technology’s realtime messaging products – and our unique, data-efficient approach to streaming data – developers are armed with an integration and data delivery platform optimized for today’s internet-connected world.

Why realtime messaging?

Many of today’s apps are point-in-time representations of data, refreshing information only when a user explicitly asks for an update, or continuously polling the backend. However, reactive apps are infinitely more engaging, and interactive – pushing updates in real time as new data becomes available. This allows you to scale your applications, without adding unnecessary load to back-end systems and creates a layer of decoupling that protects applications from data model changes. Realtime messaging integrates seamlessly with modern development frameworks for the web (Angular, Meteor, React, etc) delivering data updates in real time to end users. Stop focusing on point-in-time data, and instead, focus on realtime, event-driven, responsive, and engaging applications.

Benefits of Diffusion

Diffusion offers the most intelligent and data-efficient realtime messaging products available today. Designed to be easily integrated to new and existing application architecture, our technology gives you a flexible, reactive, and efficient data layer for all your business needs.

Publish-subscribe integration

The Diffusion server provides a publish-subscribe integration model. The Diffusion server stores data in a tree of topics, where each topic has a value. This value can be fetched in an ad-hoc fashion, but, more commonly, a client session subscribes to the topics that are of interest to it. The Diffusion server pushes each update to the topic to the client session as a stream of values.

Dynamic data model

Client sessions subscribe to data topics using wildcard selectors. When new topics are added, sessions with matching selectors are automatically subscribed. This avoids the need for separate topic life-cycle processes, and data objects can be frequently created and deleted without impacting existing applications.

Value-oriented programming

A value-oriented programming model is a fundamental feature of a reactive data model. Applications are built against an API that provides streams of values, rather than individual messages that need further decoding. Client SDKs provide a common programming model, making best use of the features particular to their implementation language. This frees developers to focus on application functionality, rather than data integration.

Inverted data grid

Like a data grid, Diffusion stores values in memory. Traditionally, data grids are optimized for query and primarily support a polling paradigm. In Diffusion, the data grid is optimized for a realtime, event-driven communication. Often deployed as a specialized cache, data grids offload processing from a backend system. Diffusion offers the same benefit but is designed to deliver realtime streams to a high number of subscribed clients.

Non-blocking I/O

Network communication is performed by an event-driven kernel that uses non-blocking I/O to interact efficiently with the host networking. Client sessions are partitioned and each partition is assigned to a dedicated thread that manages all subscription matching and outbound communication for that session. This lock-free design avoids contention between these sessions and allows the platform to scale linearly across CPU resources, achieving very high message rates.

Protocol optimization

Messages are serialized into a compact binary representation called CBOR. This reduces bandwidth consumption for every message – up to 30% compared with ASCII. A small binary header is used to frame each message, but this is typically only two bytes when using the default WebSocket-based protocol.

Delta streaming

Topics provide stateful streams of data to each session. Once a client session is subscribed to a topic and receives the current state, all subsequent updates are sent as a delta (the difference from the previous value). This happens transparently to the application, with the client SDK reconstructing the full data payload with the delta applied – so neither application or backend require changes.

Message queue optimization

Messages that cannot be immediately delivered to a session are queued. If the network connections fail, bandwidth is limited, or the client is simply slow, messages can back up on the queue. Diffusion can conflate the queue to remove messages that are stale or no longer relevant, or to combine multiple related messages into a single consolidated message.

Bandwidth management

The rate of messages delivered to a session can be artificially constrained by the platform. This can be used to prioritize one client session over another, to place limits on bandwidth utilization, to improve batching, or to encourage conflation. These measures might be desirable in some circumstances, but obviously lead to increased latency for the throttled sessions.

Reliable reconnection

Client connectivity is continuously monitored by the Diffusion server using a variety of bandwidth efficient mechanisms. If a client session is disconnected due to network failure, both the client and server queue messages for a period of time until that session can be re-established. Once the session is reconnected, the client and server reconcile the messages successfully received to ensure none are lost.

Assured delivery

During an active session, messages between the client and the Diffusion server are delivered without loss regardless of the protocol in use. Delivery is considered assured rather than guaranteed to account for client/server or network failures that terminate an active session.

Extensive SDK support

With simple client SDKs (Software Development Kits) available for a range of languages and environments, there are no new protocols or technologies to learn. The SDK includes a runtime library, API, documentation, and examples. The supported SDKs include JavaScript® (browser and Node.js), Apple® (iOS®, OS X®/macOS® and tvOS™), Android™, Java™, .NET, and C

Protocol fallback

By default, clients use the WebSocket protocol to establish bi-directional communication with the Diffusion server. In some cases the WebSocket protocol is not available. For example, WebSocket connections can be blocked by a firewall or load balancer, or disallowed by the network provider. In this case, clients can automatically fallback (cascade) to long polling over HTTP.

Session administration

A session with appropriate security permissions can act as a control client and instruct the Diffusion server to add and remove topics, send data updates to topics, and receive notifications about events – such as when the number of subscribers for a topic falls to zero. A control client session can also authenticate connection requests, receive notifications about new or modified sessions, modify or close sessions, and send and receive messages to and from individual sessions. Every session has session properties: a set of key-value pairs that can be modified or used to filter groups of related sessions.

Security framework

The Diffusion server has a capable security framework. Authentication can use the built-in security database or be federated to control clients that can integrate with third-party database. Authorization is declarative and based on a configurable hierarchy of roles. Each session is assigned to one or more roles. Roles are granted permissions such as the ability to access, modify, subscribe to, or update specific topics; or the ability to control other sessions. Secure communication over TLS is supported by the Diffusion server and client libraries for all protocols.