openBackhaul / MicroWaveDeviceInventory

Physical and logical inventory of the MW SDN Domain
Apache License 2.0
5 stars 2 forks source link

[LoadBalancing] All requests initiated from MWDI shall be load balanced among the mediators #734

Open ssomasundara opened 1 year ago

ssomasundara commented 1 year ago

The MWDI asyncronously pick the list of devices as per the sliding window configuration and push these requests (continuously) to controller. 3000+ requests in 1hr. These requests are not getting equally distributed among the mediators. Below situations to be regarded.

As MWDI requests are continuous, there is a situation where number of parallel requests to any mediator instance is minimum. Having minimum number of parallel requests increase the number of batches to the mediator VM which will result in long run to update the cache. (Around 12 hrs to complete cache updation of 40K devices) .

Since the requests are random, it could be possible that one mediator handling more requests and another might handle only one thenth of the number of requests. If multiple applications are also sending such asynchronous requests there is possiblity that some mediator instances are overloaded.

The proposal is to

  1. Update the cache asap and provide room for other applications.
  2. Introduce equal distribution mechanism by increasing the number of parallel requests and reducing the batch size. The equal distribution logic shall address non mediator instances (native netconf) for future.
kmohr-soprasteria commented 1 year ago

See issues #732 (shuffling the deviceList), which is a first step towards distribution of load and

511, which is the more general load balancing wrapper issue

kmohr-soprasteria commented 1 year ago

We will not be adding features on the MWDI to solve problems that could arise on the mediator.

kmohr-soprasteria commented 12 months ago

The MWDI (or applications in general) shall not have to implement features to solve problems on mediator and/or controller layer. Therefore, the MWDI definitely shall not take mediator information into account.

An overarching concept for load balancing of the architecture needs to be created.

Issue will be kept open for now, to not forget about this.