Examples of MetadataResponse


Examples of org.apache.kafka.common.requests.MetadataResponse

        }
    }

    private void handleMetadataResponse(RequestHeader header, Struct body, long now) {
        this.metadataFetchInProgress = false;
        MetadataResponse response = new MetadataResponse(body);
        Cluster cluster = response.cluster();
        // don't update the cluster if there are no valid nodes...the topic we want may still be in the process of being
        // created which means we will get errors and no nodes until it exists
        if (cluster.nodes().size() > 0)
            this.metadata.update(cluster, now);
        else
View Full Code Here

Examples of org.apache.phoenix.coprocessor.generated.MetaDataProtos.MetaDataResponse

                                }
                            });
                if(results.isEmpty()){
                    throw new IOException("Didn't get expected result size");
                }
                MetaDataResponse tmpResponse = results.values().iterator().next();
                MetaDataMutationResult result = MetaDataMutationResult.constructFromProto(tmpResponse);               
               
                if (result.getMutationCode() != MutationCode.TABLE_ALREADY_EXISTS) {
                    LOG.warn("Attempt to disable index " + indexTableName + " failed with code = " + result.getMutationCode() + ". Will use default failure policy instead.");
                    throw new DoNotRetryIOException("Attemp to disable " + indexTableName + " failed.");
View Full Code Here

Examples of org.apache.phoenix.coprocessor.generated.MetaDataProtos.MetaDataResponse

                try {
                    final Map<byte[], MetaDataResponse> results =
                            ht.coprocessorService(MetaDataService.class, tableKey, tableKey, callable);

                    assert(results.size() == 1);
                    MetaDataResponse result = results.values().iterator().next();
                    if (result.getReturnCode() == MetaDataProtos.MutationCode.TABLE_NOT_IN_REGION) {
                        if (retried) return MetaDataMutationResult.constructFromProto(result);
                        retried = true;
                        continue;
                    }
                    return MetaDataMutationResult.constructFromProto(result);
View Full Code Here

Examples of org.apache.phoenix.coprocessor.generated.MetaDataProtos.MetaDataResponse

                HTableInterface ht = this.getTable(PhoenixDatabaseMetaData.SYSTEM_CATALOG_NAME_BYTES);
                final Map<byte[], MetaDataResponse> results =
                        ht.coprocessorService(MetaDataService.class, tableKey, tableKey, callable);
               
                assert(results.size() == 1);
                MetaDataResponse result = results.values().iterator().next();
                if (result.getReturnCode() == MetaDataProtos.MutationCode.TABLE_NOT_IN_REGION) {
                    if (retried) return MetaDataMutationResult.constructFromProto(result);
                    retried = true;
                    continue;
                }
                return MetaDataMutationResult.constructFromProto(result);
View Full Code Here

Examples of org.apache.phoenix.coprocessor.generated.MetaDataProtos.MetaDataResponse

                                }
                            });
                if(results.isEmpty()){
                    throw new IOException("Didn't get expected result size");
                }
                MetaDataResponse tmpResponse = results.values().iterator().next();
                MetaDataMutationResult result = MetaDataMutationResult.constructFromProto(tmpResponse);               
               
                if (result.getMutationCode() != MutationCode.TABLE_ALREADY_EXISTS) {
                    LOG.warn("Attempt to disable index " + indexTableName + " failed with code = " + result.getMutationCode() + ". Will use default failure policy instead.");
                    super.handleFailure(attempted, cause);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.