-
Notifications
You must be signed in to change notification settings - Fork 265
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Orion responses with stack hang up and subscriptions with patterns #3519
Comments
I did not try threadpool though because I am not sure, if it is the rigth scenario for this. Hence, it is always good to keep the naumber of single subscriptions down and use patterns? Or will they have the same effect? |
300,000 subscriptions ... that's a lot :) |
Well, assuming a district of buildings each having about 10000 data points the number is reached quite quickly, :) if I was subscribing each data point individually for storing it with quantumleap and crate. This would give a better handling in throttling individual data points. But back to topic. Would threadpooling really help here? Since I only sent notification to my quantumleap replicas so far. What would happen with the load balancing mechanism if a keep the connections open? |
I think we are misleading two concepts: entities (representing the data points in a building) and subscriptions (the way Orion has to implement asynchronous context consumption, based on notifications). As far as I understand by your case description:
So you have 14000 entities and 18 subscriptions. Is that correct? In addition, I don't fully understand what you mean by:
What do you mean by "subscription execution"? Could you elaborate on it, please? |
Side-note: MongoDB 4.0 is not the official MongoDB version supported by Orion (check: https://fiware-orion.readthedocs.io/en/master/admin/install/index.html#requirements). Probably it doesn't have any impact in the case... but I let you know about it ;) |
With regards to:
In addition, could you attach an architecture diagram showing how they are connected, please? |
@fgalan I think, we both have the same understanding:
Since the type mapping is limited for now, I come up with 18 subscriptions in total. But in an earlier version without the data model I had to subscribe each entity individually in order to watch for updates on my active data attribute and notify one of the quantum leap replica. This means 14000 subscriptions. With the execution of a subscription I mean the execution of the notification mechanism. Architecturewise, I use docker with replicas for scalling CB and quantumleap. Hence, I use the docker DNS for distributing the load. --> The notification is always send to the same URL and Docker does the rest. I don't think the mongoDB schould not make any difference but I can also downgrade for testing. I can also provide a sketch later in the day if still needed. |
Yes, please. I think it would help to clarify the scenario. Once you do it, I'll read in deep your comment and provide feedback. |
Hi again, sorry, for not coming back to this for such a long time. dataflow: For the number of replicas I added the numbers. The whole platform runs on a 1-node docker swarm. That is also the reason why we did not replicate the databases yet. The openMuc Modul is a middleware that only ensures the communication with BACnet. For the platform it simply looks as if there were UL-iot-devices sending data on their topics. I think this issue is also related to 383 in iot-agent-ul Hence, is there any solution but tuning? I am not quite sure if tuning would solve the problem in general. I hope the skeches help for better understanding. Cheers |
Thanks for the diagram. Some additional pieces of information I'd need:
(Looking in the issue comments above, I'm afraid it's not fully clear to me... maybe I'm not remembering correctly given the time has passed ;) In the meanwhile, I'll try to provide some answers to some of the points mentioned above:
My suggestion is to test with the three notifications modes (transient, permanent and threadpool), evaluate results and use the most convenient for your case.
Throttling is evaluated per-subscription. In addition, it has some limitations in multi-CB scenario as I understand yours is. From https://fiware-orion.readthedocs.io/en/master/user/ngsiv2_implementation_notes/index.html#notification-throttling:
In general, we don't recommend to use throttling (versus implement notification flow control in the receiver element).
As far as I remember, there isn't any "pending" status for subscriptions (status are "active", "inactive",k "expired", "oneshot", etc.). A good description on how subscriptions and notification work in multi-CB scenarios is described here: https://stackoverflow.com/questions/43857300/what-would-be-the-behavior-of-subscriptions-and-notifications-in-an-orion-load-b/43873643#43873643 (if you find useful, please provide a +1 on it, so it can go higher in SOF/Google searches and be useful to more users :)
I had a look to it and provide some feedback on that isssue. |
Hello,
I am using Orion in the following in a larger scenario with docker-swarm:
I am sending about 50-60 values per seconds. Unfortunately, not all of them are handled well and my IoTA-ERROR-Log grows quite with always the same message:
After a while I find another ERROR in my log:
For my 18 subscriptions I use patterns based on the entity-type in order to manage my scenario with over 14000 data sources.
Looking like this:
Having these Errors I cannot guarantee that all subscriptions are executed correctly and that the platform will be stable in the very end:/
Is this a bug? I face the same issue without scaling the CB.
Or do I need to move it to stackoverflow? From my understanding this schouldn't be an issue for Fiware to handle thís data flow. On Stackoverflow I only found this but it is not directly helping because i would like to use the described setup:
https://stackoverflow.com/questions/53818381/how-can-i-improve-socket-hang-up-when-connecting-many-devices
Thanks in advance
The text was updated successfully, but these errors were encountered: