I am using Pub/Sub
i am facing issue
Error processing a message BackendlessFault{ code: 'null', message: '{code=0, details={limit=5}, message=Reached Limit: you can not have more then 5 subscriptions per one connection}', detail: 'null', extendedData: '{}' }
Case:
I have implemented the code in 2 android apps
App A
App B
App A sends a message and App B is receiving the message
when App B sends the message the message gets published but App A never receive the message
Hello @Saad_Zahoor2
We will investigate the issue and report the result as soon as possible.
Regards,
Inna
@Saad_Zahoor2
Unfortunately, I was unable to reproduce your problem.
I have a few questions for you:
- Is the problem reproducible for you?
- Provide your App ID.
- On what devices have you tested the messenger?
- When AppB sends a message, does it show as successfully sent?
- Have you tried sending messages from the Backendless Console (Messaging >> Messages)? If so, is it for AppB?
Hi @Saad_Zahoor2,
Whenever your code uses any of the following methods, a real-time subscription is created. Depending on the pricing plan your app is on, there is a limit for the number of real-time subscriptions. Make sure to check the app logic that you properly remove subscriptions to ensure you do not run into the limit:
-
addCreateListener
- can be removed with this.
-
addUpdateListener
- can be removed with this.
-
addDeleteListener
- can be removed with this.
Regards,
Mark
I am keep getting this error
{message=Reached Limit: you can not have more then 5 subscriptions per one connection, code=0, details={limit=5}}
I have a listener in my service
int token = App.getAppInstance().getIncomingOutgoingRideDetails().getInt(Constants.TOKEN, 0);
whereClause = Constants.TOKEN + " = " + token;
rtHandler.addBulkUpdateListener(whereClause, new AsyncCallback<BulkEvent>() {
@Override
public void handleResponse(BulkEvent response) {
DataQueryBuilder queryBuilder = DataQueryBuilder.create();
queryBuilder.setWhereClause(whereClause);
Log.i("ServicePPP", "I am inside the backendless listener !! successfully whereclause -> " + whereClause);
Backendless.Data.of(PassengerChauffeurConnection.class).find(queryBuilder, new AsyncCallback<List<PassengerChauffeurConnection>>() {
@Override
public void handleResponse(List<PassengerChauffeurConnection> response) {
if (response.size() == 1) {
}
}
@Override
public void handleFault(BackendlessFault fault) {
}
});
}
@Override
public void handleFault(BackendlessFault fault) {
}
});
and when I destroy the service i am calling
rtHandler.removeBulkUpdateListeners(whereClause);
but still, I am getting the error
plus i want to ask one more thing your real-time SDK does not even make sense, I wanted to ask this question long before but things were working fine so that why I did not
I want to listen to 1 object from a table where token=123 so why I am using bulk listener, does not bulk stands for many ???
and is there any way to check out the subscriptions limit from backendless console?
Hi @Saad_Zahoor2
I want to listen to 1 object from a table where token=123
Then why do you use bulk listener? You should use single update listener in this case:
https://backendless.com/docs/android/rt_conditional_delivery_update.html
I am keep getting this error
{message=Reached Limit: you can not have more then 5 subscriptions per one connection, code=0, details={limit=5}}
Try to create simple listener within your app and check if the problem persists.
There may be a lot of causes. I can suggest to check the following:
- do you create one listener per service?
- do you create one service at the time?
- can you check if service is destroyed correctly?
Best Regards,
Maksym
I am trying to solve this error but I am still getting the same error
E/RTClient: got error {message=Reached Limit: you can not have more then 5 subscriptions per one connection, code=0, details={limit=5}}
I have several questions:
-
How can I know how many subscriptions are active?
-
What is the meaning of subscriptions??
-
Does this subscription related to pub/sub?
-
How one should make the subscriptions 0, by removing the listeners?
-
What I understand from a subscription that on the free plan I can have 5 instances to listen to the back endless real-time database. Am I right?
-
Sometimes the value gets updated in the console but the trigger does not get triggered. I have manually go and update the value then code working fine.