The open source components of The Things Network enable anyone to build a complete Internet of Things solution using the Low Power Wide Area Networking standard - LoRaWAN. The Things Network covers the entire stack: device libraries and gateway software, cloud routing services, software development kits along with integrations. To embrace the rapidly growing global community, we also wrote documentation, created video tutorials, curated content and hosted collaborative spaces through the forum and community pages.
This article dives deeper in the architecture describing how the network is designed and how it can be deployed to fulfill a wide range of business needs.
In the fall of 2015, Wienke and I organized several architecture sessions with early community members to design a scalable and distributed design that allows for high availability, high performance and end-to-end security, while staying fully compliant with the LoRaWAN specification. Let’s look at the key components of the network first (see Figure 1).
Figure 1: Key components of the network
- Device - A LoRaWAN enabled device that is commissioned for Over The Air Activation (OTAA) and / or Activation By Personalisation (ABP). The device may send data once in awhile (class A), receive data regularly (class B) or listens continuously for data (class C).
- Gateway - A device that receives LoRa messages and forwards it to the Router using our very own secure and remotely configurable packet forwarder.
- Router - A microservice that receives messages from the gateway and finds a Broker to forward the message to.
- Broker - A microservice that identifies the device, deduplicates traffic and forwards the packet to the Handler where the application is registered.
- Handler - A microservice that encrypts and decrypts the payload and publishes it to message brokers to be used by applications.
- Application - A piece of software, running on a server, performing some tasks for the end user.
Next to these key components, there is the Discovery Server which keeps track of various components that are registered in the network and a Network Server which contains the device registry alongside keeping track of device states (see Figure 2).
Figure 2: Open source architecture
For application developers there are Software Development Kits with libraries, tools, documentation and training material for end devices and applications. Finally, the Integrations connect the network seamlessly with Internet of Things platforms for storage, analysis, visualisation and advanced device management. These platforms enable developers to quickly create new solutions while focusing on their problem space, rather than the hassle of network infrastructure.
The Things Network Foundation hosts these components for everybody to use free of charge. Next to these open source components, The Things Industries and partners contribute additional components for ease of management, security and additional integrations. Together, this is The Things Network public community network.
Figure 3: Illustrating the entire network with open source components and additions offered by The Things Industries
As the traffic on the network increases, more gateways need to be placed by the community. Additional gateways will not only add redundancy to the network, but it will also add capacity. With more gateway, the distance between end devices and gateways is smaller. For shorter distances faster data rates can be used. This lowers airtime and thus channel utilization, having an exponential effect on network capacity. Our ADR (adaptive data rate) algorithm does this scaling automatically.
Figure 4: Illustrating Gateway Coverage
The microservices are scaled horizontally around the world for redundancy and keeping data as close to the gateways and applications as possible. In busier regions, the services are also scaled vertically. The Things Network Foundation works closely with community partners to distribute traffic to donated network infrastructure; adding even more capacity, taking dependency from the Foundation’s infrastructure and complying with regulations on data that is not allowed to leave certain countries.
Figure 5: Scaling Microservices Vertically
Next to the public community network, the components can be deployed for private networks in a hosted environment (Figure 6). This creates a platform for people and organizations to host the microservices privately, while still being able to leverage the global network. The routing services can run in private domains, and we're working hard to make these private networks exchange traffic with the public community network. This means that your network contributes packets to the public network, while leveraging it for extra coverage. Because the routing services are going to be hosted, you can also form a chain of technology where the quality and level of security can be controlled. You can even configure the components in such a way that the data packets never leave your domain.
Figure 6: Private networks in a hosted environment
Instead of running all the network components, you can also run just the handler in your application domain. This allows for the encryption and decryption of application payloads to be performed within your own domain, leveraging the end-to-end security capability of LoRaWAN. This is a unique feature of The Things Network.
Figure 7: Running Handler in Application Domain
The public community network is free to use and comes without any guarantee, even though it has been proven to be stable. Businesses migrating to commercial services using the same network components, can now get a guaranteed service level, maintenance and support. The Things Industries provides these services, both for on-premises installation as well as a fully hosted pay-as-you-go model.
The Things Network is continuously in development. If you’re interested in seeing or contributing to our codebase, take a look at https://github.com/TheThingsNetwork. Soon we will be releasing our new roadmap for 2017/2018. Keep an eye on the forum.
Join the dicussion on the Forum about our architecture or send me a mail: firstname.lastname@example.org