pubnub - Number of channels and billing -
I am looking for an app that monitors public transport buses for a major city:
I have a quick prototype using the public, GPS signal is sent to a channel near buses, and users simply have phones subscribing to channels. I have questions:
-
I'm planning for each bus route, one channel There are 50 routes in the city, so there are 50 routes. Does it follow the best practice?
- Is there an API to list the channels?
-
I am sending a message to each other that each channel assumes that there are 50 routes with 5 buses running every 24 hours. 216000000 daily messages will be charged for one day?
-
Does your Android client publish a network connection each time? I want to reduce the bandwidth used by the phone that transmits GPS signals.
-
The bus users often want to see the location of buses. I know the best practice is to subscribe to a public and a private channel What is the best way to do this?
If you can answer the above questions then I appreciate it.
full disclosure front - I work for the success of the subscriber's customer, so for the price related questions The response is only in the form of informational nature and it is not considered as a publicity, the Asker specifically mentions PubNub and the information given below is publicly available from the PubNub website.
Infinity, normally as an FYI stack overflow, it will ask that each of these questions is called as a separate thread. Going forward, do your best to follow the Community Guidelines.
1 Each implementation will be different according to the specific architecture and design pattern strategy, although your proposed approach seems to be the sensible use of channel method. PubNub does not limit the total number of channels in use, however the practical limit for most mobile development frameworks subscribing to more than 50 channels will be around the upper boundaries at the same time. Adding more than that will start displaying the performance limits of both iOS and Android, if new bus lines are added, membership can be managed only for subscribing to nearby routes etc.
Question 1 Indent with second, which can be done here with AOI now
2 PubNub charges $ 1 per million messages (without enabling SSL), so Your message fee will be $ 216 per day depending on your conceptual. It is being said that there is an important place for design pattern optimization, so whenever there is a change, just publish a new location - it is unnecessary when it is re-published, it's own optimization message usage figure Will bring down significantly, and other strategies that can be used for more optimization based on the perspective of your specific implementation. Can be found. If you anticipate that more than 1 billion messages are required per month, then a deployment on the global cloud can be understood so that they do not get the benefit of the volume discount pricing, otherwise the Go is not available on the cloud.
3 With each publication instead of opening a new connection, PubNub maintains an active socket connection until the subscription expires or disconnects due to a network connection / application force being switched off. In order to keep this connection active for several hours, bandwidth usage and other non-publication / other non-attendance activities usually take less than 1K depending on your configuration parameters. Supports Android background threading, even when the app If the focus is not on, connections can be open to facilitate data push alerts, which can be used to update any Users can be used to give the signal to get back into the application foreground Kari review.
4 This question is not clear, assuming that buses are published to the public channel, what will be the purpose of the private channel? If you mean that a private channel to receive alerts for the arrival of the user's selected bus, then yes that would be an appropriate implementation strategy if you mean something different, please clarify.
Comments
Post a Comment