break; case 4: builder.setJavaExecutor(input.readBool()); break; case 5:
public Builder mergeFrom(com.dremio.exec.proto.CoordinationProtos.Roles other) { if (other == com.dremio.exec.proto.CoordinationProtos.Roles.getDefaultInstance()) return this; if (other.hasSqlQuery()) { setSqlQuery(other.getSqlQuery()); } if (other.hasLogicalPlan()) { setLogicalPlan(other.getLogicalPlan()); } if (other.hasPhysicalPlan()) { setPhysicalPlan(other.getPhysicalPlan()); } if (other.hasJavaExecutor()) { setJavaExecutor(other.getJavaExecutor()); } if (other.hasDistributedCache()) { setDistributedCache(other.getDistributedCache()); } if (other.hasMaster()) { setMaster(other.getMaster()); } this.mergeUnknownFields(other.getUnknownFields()); return this; }
public ServiceHolder(BufferAllocator allocator, Provider<Iterable<NodeEndpoint>> nodeProvider, PDFSMode mode, String name) throws Exception{ this.allocator = allocator.newChildAllocator(name, 0, Long.MAX_VALUE); pool = new CloseableThreadPool(name); fabric = new FabricServiceImpl(HOSTNAME, 9970, true, THREAD_COUNT, this.allocator, RESERVATION, MAX_ALLOCATION, TIMEOUT, pool); fabric.start(); endpoint = NodeEndpoint.newBuilder() .setAddress(fabric.getAddress()).setFabricPort(fabric.getPort()) .setRoles(Roles.newBuilder().setJavaExecutor(mode == PDFSMode.DATA)) .build(); service = new PDFSService(DirectProvider.wrap((FabricService) fabric), DirectProvider.wrap(endpoint), nodeProvider, DremioTest.DEFAULT_SABOT_CONFIG, this.allocator, mode); service.start(); fileSystem = service.createFileSystem(); }
@Override protected void updateEndpointRoles(Roles.Builder roles, boolean enable) { roles.setJavaExecutor(enable); }
/** * Create a {@link com.dremio.exec.proto.beans.NodeEndpoint} * @param address the address * @param port the control port * @return */ private static NodeEndpoint newNodeEndpoint(String address, int port) { return NodeEndpoint.newBuilder().setAddress(address).setFabricPort(port).setRoles(Roles.newBuilder().setJavaExecutor(true)).build(); }