This topic discusses the load balancing and routing requests from Studio nodes to the Dgraph nodes in Oracle Big Data Discovery.
Depending on your deployment strategy, to the external clients, the entry point of contact with the on-premise deployment of the Big Data Discovery cluster could be either any Studio-hosting node in the cluster, or an external load balancer configured in front of Studio instances.
If you use an external load balancer, it receives all requests and distributes them across all of the nodes in the Big Data Discovery cluster deployment that host the Studio application. Once a request is received from a Studio node, it is routed by BDD to the appropriate Dgraph node.
If you don't use an external load balancer, external requests can be sent to any Studio node. They are then load-balanced between the nodes hosting the Dgraph.
The Big Data Discovery cluster automatically directs requests to the subset of the cluster nodes hosting the Dgraph instances.
Requests are submitted from either Studio or Data Processing to any Dgraph Gateway instance in the cluster, which in turn routes them to an appropriate Dgraph node. For example, an update request (such as a data loading request or a configuration update) is routed to the leader Dgraph for the Dgraph database that needs to be updated. Non-updating requests can be routed to any available Dgraph node. These are load-balanced between the Dgraph nodes using a round-robin algorithm.
The BDD cluster utilizes session affinity for all requests arriving from Studio to the Dgraph, by relying on the session ID in the header of each Studio request. Requests from the same session ID are always routed to the same Dgraph node in the cluster. This improves query processing performance by efficiently utilizing the Dgraph cache, and improves performance of caching for Studio's views.