Search in sources :

Example 6 with Tenant

use of com.linkedin.pinot.common.config.Tenant in project pinot by linkedin.

the class PerfBenchmarkDriver method startHelixResourceManager.

private void startHelixResourceManager() throws Exception {
    _helixResourceManager = new PinotHelixResourceManager(getControllerConf());
    _helixResourceManager.start();
    // Create broker tenant.
    Tenant brokerTenant = new TenantBuilder(_brokerTenantName).setRole(TenantRole.BROKER).setTotalInstances(1).build();
    _helixResourceManager.createBrokerTenant(brokerTenant);
    // Create server tenant.
    Tenant serverTenant = new TenantBuilder(_serverTenantName).setRole(TenantRole.SERVER).setTotalInstances(1).setOfflineInstances(1).build();
    _helixResourceManager.createServerTenant(serverTenant);
}
Also used : Tenant(com.linkedin.pinot.common.config.Tenant) PinotHelixResourceManager(com.linkedin.pinot.controller.helix.core.PinotHelixResourceManager) TenantBuilder(com.linkedin.pinot.common.config.Tenant.TenantBuilder)

Aggregations

Tenant (com.linkedin.pinot.common.config.Tenant)6 JSONException (org.json.JSONException)2 StringRepresentation (org.restlet.representation.StringRepresentation)2 AbstractTableConfig (com.linkedin.pinot.common.config.AbstractTableConfig)1 TenantBuilder (com.linkedin.pinot.common.config.Tenant.TenantBuilder)1 PinotHelixResourceManager (com.linkedin.pinot.controller.helix.core.PinotHelixResourceManager)1 IdealState (org.apache.helix.model.IdealState)1 JSONObject (org.json.JSONObject)1 Post (org.restlet.resource.Post)1 Put (org.restlet.resource.Put)1 Test (org.testng.annotations.Test)1