How does a network server know which message to send to which application server?

Hi there,

this is not a TTN specific question, but here are so many poeple with excellent LoRaWAN knowledge I feel confident it will be answered quickly :slight_smile: If the question is unappropriate in this forum please tell me so.

I was wondering about the communication between the network server and the application server(s). In many diagrams about LoRaWAN, a single network server serves multiple application servers. Which means, when the network server recieves an uplink, two things could happen:

  1. The Network server knows to which Application Server the uplink belongs. It only sends the uplink message to this AS. This means it would need to know which DevAddr belongs to which AS. I strongly guess this is the case.
  2. The Network Server sends the uplink mesage to all Application servers. Each Application Server checks if the DevAddr belongs to it.
  3. Another solution I didnt think about :slight_smile:

Thanks & Best regards
Philipp

This depends a bit on the network server implementation, but the way it works in our implementation is that devices are registered in the Network Server, and part of that registration is the ID of the application these devices belong to. The Application Server then starts a “link” with the Network Server for the application ID in order to receive traffic.

We have an open issue on GitHub for also supporting an approach without this “linking”. Instead, you’d register the address of the Application Server for an end device in the Network Server, and the Network Server will contact the Application Server when it has traffic to forward.