what is the use of ChainBuilder Class in gatling, can someone help me to understand this code, i am new for gatling
class TenantSimulation extends BasicSimulation {
// Call When Multiple Chains need to connect
def getChainBuilder: ChainBuilder = {
exec(getTenants())
.exec(getTenantInfo())
.exec(getTenantsConfig())
}
private def getTenantInfo(): ChainBuilder = {
exec(http(GET_TENANT_INFO)
.get(BASE_PATH + "/ABC" + "/XYZ")
.check(status.is(HttpURLConnection.HTTP_OK))
.check(jsonPath("$.tenantName").exists))
}
private def getTenantsConfig(): ChainBuilder = {
exec(http(GET_TENANT_CONFIG)
.get(BASE_PATH + "/ABC/PQR")
.check(status.is(HttpURLConnection.HTTP_OK))
.check(jsonPath("$.authenticators[0].name").exists))
}
private def getTenants(): ChainBuilder = {
exec(http(GET_TENANTS_LIST)
.get(BASE_PATH)
.check(status.is(HttpURLConnection.HTTP_OK)))
}