All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.xds.data.orca.v3.OrcaLoadReport Maven / Gradle / Ivy

There is a newer version: 1.0.46
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: xds/data/orca/v3/orca_load_report.proto

package com.github.xds.data.orca.v3;

/**
 * Protobuf type {@code xds.data.orca.v3.OrcaLoadReport}
 */
public final class OrcaLoadReport extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:xds.data.orca.v3.OrcaLoadReport)
    OrcaLoadReportOrBuilder {
private static final long serialVersionUID = 0L;
  // Use OrcaLoadReport.newBuilder() to construct.
  private OrcaLoadReport(com.google.protobuf.GeneratedMessageV3.Builder builder) {
    super(builder);
  }
  private OrcaLoadReport() {
  }

  @java.lang.Override
  @SuppressWarnings({"unused"})
  protected java.lang.Object newInstance(
      UnusedPrivateParameter unused) {
    return new OrcaLoadReport();
  }

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private OrcaLoadReport(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    this();
    if (extensionRegistry == null) {
      throw new java.lang.NullPointerException();
    }
    int mutable_bitField0_ = 0;
    com.google.protobuf.UnknownFieldSet.Builder unknownFields =
        com.google.protobuf.UnknownFieldSet.newBuilder();
    try {
      boolean done = false;
      while (!done) {
        int tag = input.readTag();
        switch (tag) {
          case 0:
            done = true;
            break;
          case 9: {

            cpuUtilization_ = input.readDouble();
            break;
          }
          case 17: {

            memUtilization_ = input.readDouble();
            break;
          }
          case 24: {

            rps_ = input.readUInt64();
            break;
          }
          case 34: {
            if (!((mutable_bitField0_ & 0x00000001) != 0)) {
              requestCost_ = com.google.protobuf.MapField.newMapField(
                  RequestCostDefaultEntryHolder.defaultEntry);
              mutable_bitField0_ |= 0x00000001;
            }
            com.google.protobuf.MapEntry
            requestCost__ = input.readMessage(
                RequestCostDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
            requestCost_.getMutableMap().put(
                requestCost__.getKey(), requestCost__.getValue());
            break;
          }
          case 42: {
            if (!((mutable_bitField0_ & 0x00000002) != 0)) {
              utilization_ = com.google.protobuf.MapField.newMapField(
                  UtilizationDefaultEntryHolder.defaultEntry);
              mutable_bitField0_ |= 0x00000002;
            }
            com.google.protobuf.MapEntry
            utilization__ = input.readMessage(
                UtilizationDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
            utilization_.getMutableMap().put(
                utilization__.getKey(), utilization__.getValue());
            break;
          }
          case 49: {

            rpsFractional_ = input.readDouble();
            break;
          }
          case 57: {

            eps_ = input.readDouble();
            break;
          }
          case 66: {
            if (!((mutable_bitField0_ & 0x00000004) != 0)) {
              namedMetrics_ = com.google.protobuf.MapField.newMapField(
                  NamedMetricsDefaultEntryHolder.defaultEntry);
              mutable_bitField0_ |= 0x00000004;
            }
            com.google.protobuf.MapEntry
            namedMetrics__ = input.readMessage(
                NamedMetricsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
            namedMetrics_.getMutableMap().put(
                namedMetrics__.getKey(), namedMetrics__.getValue());
            break;
          }
          case 73: {

            applicationUtilization_ = input.readDouble();
            break;
          }
          default: {
            if (!parseUnknownField(
                input, unknownFields, extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
        }
      }
    } catch (com.google.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (com.google.protobuf.UninitializedMessageException e) {
      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new com.google.protobuf.InvalidProtocolBufferException(
          e).setUnfinishedMessage(this);
    } finally {
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }
  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_descriptor;
  }

  @SuppressWarnings({"rawtypes"})
  @java.lang.Override
  protected com.google.protobuf.MapField internalGetMapField(
      int number) {
    switch (number) {
      case 4:
        return internalGetRequestCost();
      case 5:
        return internalGetUtilization();
      case 8:
        return internalGetNamedMetrics();
      default:
        throw new RuntimeException(
            "Invalid map field number: " + number);
    }
  }
  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.github.xds.data.orca.v3.OrcaLoadReport.class, com.github.xds.data.orca.v3.OrcaLoadReport.Builder.class);
  }

  public static final int CPU_UTILIZATION_FIELD_NUMBER = 1;
  private double cpuUtilization_;
  /**
   * 
   * CPU utilization expressed as a fraction of available CPU resources. This
   * should be derived from the latest sample or measurement. The value may be
   * larger than 1.0 when the usage exceeds the reporter dependent notion of
   * soft limits.
   * 
* * double cpu_utilization = 1 [(.validate.rules) = { ... } * @return The cpuUtilization. */ @java.lang.Override public double getCpuUtilization() { return cpuUtilization_; } public static final int MEM_UTILIZATION_FIELD_NUMBER = 2; private double memUtilization_; /** *
   * Memory utilization expressed as a fraction of available memory
   * resources. This should be derived from the latest sample or measurement.
   * 
* * double mem_utilization = 2 [(.validate.rules) = { ... } * @return The memUtilization. */ @java.lang.Override public double getMemUtilization() { return memUtilization_; } public static final int RPS_FIELD_NUMBER = 3; private long rps_; /** *
   * Total RPS being served by an endpoint. This should cover all services that an endpoint is
   * responsible for.
   * Deprecated -- use ``rps_fractional`` field instead.
   * 
* * uint64 rps = 3 [deprecated = true]; * @deprecated xds.data.orca.v3.OrcaLoadReport.rps is deprecated. * See xds/data/orca/v3/orca_load_report.proto;l=28 * @return The rps. */ @java.lang.Override @java.lang.Deprecated public long getRps() { return rps_; } public static final int REQUEST_COST_FIELD_NUMBER = 4; private static final class RequestCostDefaultEntryHolder { static final com.google.protobuf.MapEntry< java.lang.String, java.lang.Double> defaultEntry = com.google.protobuf.MapEntry .newDefaultInstance( com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_RequestCostEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.DOUBLE, 0D); } private com.google.protobuf.MapField< java.lang.String, java.lang.Double> requestCost_; private com.google.protobuf.MapField internalGetRequestCost() { if (requestCost_ == null) { return com.google.protobuf.MapField.emptyMapField( RequestCostDefaultEntryHolder.defaultEntry); } return requestCost_; } public int getRequestCostCount() { return internalGetRequestCost().getMap().size(); } /** *
   * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
   * storage) associated with the request.
   * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public boolean containsRequestCost( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetRequestCost().getMap().containsKey(key); } /** * Use {@link #getRequestCostMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getRequestCost() { return getRequestCostMap(); } /** *
   * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
   * storage) associated with the request.
   * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public java.util.Map getRequestCostMap() { return internalGetRequestCost().getMap(); } /** *
   * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
   * storage) associated with the request.
   * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public double getRequestCostOrDefault( java.lang.String key, double defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetRequestCost().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
   * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
   * storage) associated with the request.
   * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public double getRequestCostOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetRequestCost().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public static final int UTILIZATION_FIELD_NUMBER = 5; private static final class UtilizationDefaultEntryHolder { static final com.google.protobuf.MapEntry< java.lang.String, java.lang.Double> defaultEntry = com.google.protobuf.MapEntry .newDefaultInstance( com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_UtilizationEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.DOUBLE, 0D); } private com.google.protobuf.MapField< java.lang.String, java.lang.Double> utilization_; private com.google.protobuf.MapField internalGetUtilization() { if (utilization_ == null) { return com.google.protobuf.MapField.emptyMapField( UtilizationDefaultEntryHolder.defaultEntry); } return utilization_; } public int getUtilizationCount() { return internalGetUtilization().getMap().size(); } /** *
   * Resource utilization values. Each value is expressed as a fraction of total resources
   * available, derived from the latest sample or measurement.
   * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public boolean containsUtilization( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetUtilization().getMap().containsKey(key); } /** * Use {@link #getUtilizationMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getUtilization() { return getUtilizationMap(); } /** *
   * Resource utilization values. Each value is expressed as a fraction of total resources
   * available, derived from the latest sample or measurement.
   * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public java.util.Map getUtilizationMap() { return internalGetUtilization().getMap(); } /** *
   * Resource utilization values. Each value is expressed as a fraction of total resources
   * available, derived from the latest sample or measurement.
   * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public double getUtilizationOrDefault( java.lang.String key, double defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetUtilization().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
   * Resource utilization values. Each value is expressed as a fraction of total resources
   * available, derived from the latest sample or measurement.
   * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public double getUtilizationOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetUtilization().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public static final int RPS_FRACTIONAL_FIELD_NUMBER = 6; private double rpsFractional_; /** *
   * Total RPS being served by an endpoint. This should cover all services that an endpoint is
   * responsible for.
   * 
* * double rps_fractional = 6 [(.validate.rules) = { ... } * @return The rpsFractional. */ @java.lang.Override public double getRpsFractional() { return rpsFractional_; } public static final int EPS_FIELD_NUMBER = 7; private double eps_; /** *
   * Total EPS (errors/second) being served by an endpoint. This should cover
   * all services that an endpoint is responsible for.
   * 
* * double eps = 7 [(.validate.rules) = { ... } * @return The eps. */ @java.lang.Override public double getEps() { return eps_; } public static final int NAMED_METRICS_FIELD_NUMBER = 8; private static final class NamedMetricsDefaultEntryHolder { static final com.google.protobuf.MapEntry< java.lang.String, java.lang.Double> defaultEntry = com.google.protobuf.MapEntry .newDefaultInstance( com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_NamedMetricsEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.DOUBLE, 0D); } private com.google.protobuf.MapField< java.lang.String, java.lang.Double> namedMetrics_; private com.google.protobuf.MapField internalGetNamedMetrics() { if (namedMetrics_ == null) { return com.google.protobuf.MapField.emptyMapField( NamedMetricsDefaultEntryHolder.defaultEntry); } return namedMetrics_; } public int getNamedMetricsCount() { return internalGetNamedMetrics().getMap().size(); } /** *
   * Application specific opaque metrics.
   * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public boolean containsNamedMetrics( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetNamedMetrics().getMap().containsKey(key); } /** * Use {@link #getNamedMetricsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getNamedMetrics() { return getNamedMetricsMap(); } /** *
   * Application specific opaque metrics.
   * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public java.util.Map getNamedMetricsMap() { return internalGetNamedMetrics().getMap(); } /** *
   * Application specific opaque metrics.
   * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public double getNamedMetricsOrDefault( java.lang.String key, double defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetNamedMetrics().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
   * Application specific opaque metrics.
   * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public double getNamedMetricsOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetNamedMetrics().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public static final int APPLICATION_UTILIZATION_FIELD_NUMBER = 9; private double applicationUtilization_; /** *
   * Application specific utilization expressed as a fraction of available
   * resources. For example, an application may report the max of CPU and memory
   * utilization for better load balancing if it is both CPU and memory bound.
   * This should be derived from the latest sample or measurement.
   * The value may be larger than 1.0 when the usage exceeds the reporter
   * dependent notion of soft limits.
   * 
* * double application_utilization = 9 [(.validate.rules) = { ... } * @return The applicationUtilization. */ @java.lang.Override public double getApplicationUtilization() { return applicationUtilization_; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (java.lang.Double.doubleToRawLongBits(cpuUtilization_) != 0) { output.writeDouble(1, cpuUtilization_); } if (java.lang.Double.doubleToRawLongBits(memUtilization_) != 0) { output.writeDouble(2, memUtilization_); } if (rps_ != 0L) { output.writeUInt64(3, rps_); } com.google.protobuf.GeneratedMessageV3 .serializeStringMapTo( output, internalGetRequestCost(), RequestCostDefaultEntryHolder.defaultEntry, 4); com.google.protobuf.GeneratedMessageV3 .serializeStringMapTo( output, internalGetUtilization(), UtilizationDefaultEntryHolder.defaultEntry, 5); if (java.lang.Double.doubleToRawLongBits(rpsFractional_) != 0) { output.writeDouble(6, rpsFractional_); } if (java.lang.Double.doubleToRawLongBits(eps_) != 0) { output.writeDouble(7, eps_); } com.google.protobuf.GeneratedMessageV3 .serializeStringMapTo( output, internalGetNamedMetrics(), NamedMetricsDefaultEntryHolder.defaultEntry, 8); if (java.lang.Double.doubleToRawLongBits(applicationUtilization_) != 0) { output.writeDouble(9, applicationUtilization_); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (java.lang.Double.doubleToRawLongBits(cpuUtilization_) != 0) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize(1, cpuUtilization_); } if (java.lang.Double.doubleToRawLongBits(memUtilization_) != 0) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize(2, memUtilization_); } if (rps_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeUInt64Size(3, rps_); } for (java.util.Map.Entry entry : internalGetRequestCost().getMap().entrySet()) { com.google.protobuf.MapEntry requestCost__ = RequestCostDefaultEntryHolder.defaultEntry.newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, requestCost__); } for (java.util.Map.Entry entry : internalGetUtilization().getMap().entrySet()) { com.google.protobuf.MapEntry utilization__ = UtilizationDefaultEntryHolder.defaultEntry.newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream .computeMessageSize(5, utilization__); } if (java.lang.Double.doubleToRawLongBits(rpsFractional_) != 0) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize(6, rpsFractional_); } if (java.lang.Double.doubleToRawLongBits(eps_) != 0) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize(7, eps_); } for (java.util.Map.Entry entry : internalGetNamedMetrics().getMap().entrySet()) { com.google.protobuf.MapEntry namedMetrics__ = NamedMetricsDefaultEntryHolder.defaultEntry.newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream .computeMessageSize(8, namedMetrics__); } if (java.lang.Double.doubleToRawLongBits(applicationUtilization_) != 0) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize(9, applicationUtilization_); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.github.xds.data.orca.v3.OrcaLoadReport)) { return super.equals(obj); } com.github.xds.data.orca.v3.OrcaLoadReport other = (com.github.xds.data.orca.v3.OrcaLoadReport) obj; if (java.lang.Double.doubleToLongBits(getCpuUtilization()) != java.lang.Double.doubleToLongBits( other.getCpuUtilization())) return false; if (java.lang.Double.doubleToLongBits(getMemUtilization()) != java.lang.Double.doubleToLongBits( other.getMemUtilization())) return false; if (getRps() != other.getRps()) return false; if (!internalGetRequestCost().equals( other.internalGetRequestCost())) return false; if (!internalGetUtilization().equals( other.internalGetUtilization())) return false; if (java.lang.Double.doubleToLongBits(getRpsFractional()) != java.lang.Double.doubleToLongBits( other.getRpsFractional())) return false; if (java.lang.Double.doubleToLongBits(getEps()) != java.lang.Double.doubleToLongBits( other.getEps())) return false; if (!internalGetNamedMetrics().equals( other.internalGetNamedMetrics())) return false; if (java.lang.Double.doubleToLongBits(getApplicationUtilization()) != java.lang.Double.doubleToLongBits( other.getApplicationUtilization())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + CPU_UTILIZATION_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getCpuUtilization())); hash = (37 * hash) + MEM_UTILIZATION_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getMemUtilization())); hash = (37 * hash) + RPS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getRps()); if (!internalGetRequestCost().getMap().isEmpty()) { hash = (37 * hash) + REQUEST_COST_FIELD_NUMBER; hash = (53 * hash) + internalGetRequestCost().hashCode(); } if (!internalGetUtilization().getMap().isEmpty()) { hash = (37 * hash) + UTILIZATION_FIELD_NUMBER; hash = (53 * hash) + internalGetUtilization().hashCode(); } hash = (37 * hash) + RPS_FRACTIONAL_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getRpsFractional())); hash = (37 * hash) + EPS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getEps())); if (!internalGetNamedMetrics().getMap().isEmpty()) { hash = (37 * hash) + NAMED_METRICS_FIELD_NUMBER; hash = (53 * hash) + internalGetNamedMetrics().hashCode(); } hash = (37 * hash) + APPLICATION_UTILIZATION_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getApplicationUtilization())); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.github.xds.data.orca.v3.OrcaLoadReport parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.github.xds.data.orca.v3.OrcaLoadReport prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code xds.data.orca.v3.OrcaLoadReport} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:xds.data.orca.v3.OrcaLoadReport) com.github.xds.data.orca.v3.OrcaLoadReportOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_descriptor; } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapField internalGetMapField( int number) { switch (number) { case 4: return internalGetRequestCost(); case 5: return internalGetUtilization(); case 8: return internalGetNamedMetrics(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapField internalGetMutableMapField( int number) { switch (number) { case 4: return internalGetMutableRequestCost(); case 5: return internalGetMutableUtilization(); case 8: return internalGetMutableNamedMetrics(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_fieldAccessorTable .ensureFieldAccessorsInitialized( com.github.xds.data.orca.v3.OrcaLoadReport.class, com.github.xds.data.orca.v3.OrcaLoadReport.Builder.class); } // Construct using com.github.xds.data.orca.v3.OrcaLoadReport.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } @java.lang.Override public Builder clear() { super.clear(); cpuUtilization_ = 0D; memUtilization_ = 0D; rps_ = 0L; internalGetMutableRequestCost().clear(); internalGetMutableUtilization().clear(); rpsFractional_ = 0D; eps_ = 0D; internalGetMutableNamedMetrics().clear(); applicationUtilization_ = 0D; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.github.xds.data.orca.v3.OrcaLoadReportProto.internal_static_xds_data_orca_v3_OrcaLoadReport_descriptor; } @java.lang.Override public com.github.xds.data.orca.v3.OrcaLoadReport getDefaultInstanceForType() { return com.github.xds.data.orca.v3.OrcaLoadReport.getDefaultInstance(); } @java.lang.Override public com.github.xds.data.orca.v3.OrcaLoadReport build() { com.github.xds.data.orca.v3.OrcaLoadReport result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.github.xds.data.orca.v3.OrcaLoadReport buildPartial() { com.github.xds.data.orca.v3.OrcaLoadReport result = new com.github.xds.data.orca.v3.OrcaLoadReport(this); int from_bitField0_ = bitField0_; result.cpuUtilization_ = cpuUtilization_; result.memUtilization_ = memUtilization_; result.rps_ = rps_; result.requestCost_ = internalGetRequestCost(); result.requestCost_.makeImmutable(); result.utilization_ = internalGetUtilization(); result.utilization_.makeImmutable(); result.rpsFractional_ = rpsFractional_; result.eps_ = eps_; result.namedMetrics_ = internalGetNamedMetrics(); result.namedMetrics_.makeImmutable(); result.applicationUtilization_ = applicationUtilization_; onBuilt(); return result; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.github.xds.data.orca.v3.OrcaLoadReport) { return mergeFrom((com.github.xds.data.orca.v3.OrcaLoadReport)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.github.xds.data.orca.v3.OrcaLoadReport other) { if (other == com.github.xds.data.orca.v3.OrcaLoadReport.getDefaultInstance()) return this; if (other.getCpuUtilization() != 0D) { setCpuUtilization(other.getCpuUtilization()); } if (other.getMemUtilization() != 0D) { setMemUtilization(other.getMemUtilization()); } if (other.getRps() != 0L) { setRps(other.getRps()); } internalGetMutableRequestCost().mergeFrom( other.internalGetRequestCost()); internalGetMutableUtilization().mergeFrom( other.internalGetUtilization()); if (other.getRpsFractional() != 0D) { setRpsFractional(other.getRpsFractional()); } if (other.getEps() != 0D) { setEps(other.getEps()); } internalGetMutableNamedMetrics().mergeFrom( other.internalGetNamedMetrics()); if (other.getApplicationUtilization() != 0D) { setApplicationUtilization(other.getApplicationUtilization()); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.github.xds.data.orca.v3.OrcaLoadReport parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.github.xds.data.orca.v3.OrcaLoadReport) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int bitField0_; private double cpuUtilization_ ; /** *
     * CPU utilization expressed as a fraction of available CPU resources. This
     * should be derived from the latest sample or measurement. The value may be
     * larger than 1.0 when the usage exceeds the reporter dependent notion of
     * soft limits.
     * 
* * double cpu_utilization = 1 [(.validate.rules) = { ... } * @return The cpuUtilization. */ @java.lang.Override public double getCpuUtilization() { return cpuUtilization_; } /** *
     * CPU utilization expressed as a fraction of available CPU resources. This
     * should be derived from the latest sample or measurement. The value may be
     * larger than 1.0 when the usage exceeds the reporter dependent notion of
     * soft limits.
     * 
* * double cpu_utilization = 1 [(.validate.rules) = { ... } * @param value The cpuUtilization to set. * @return This builder for chaining. */ public Builder setCpuUtilization(double value) { cpuUtilization_ = value; onChanged(); return this; } /** *
     * CPU utilization expressed as a fraction of available CPU resources. This
     * should be derived from the latest sample or measurement. The value may be
     * larger than 1.0 when the usage exceeds the reporter dependent notion of
     * soft limits.
     * 
* * double cpu_utilization = 1 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearCpuUtilization() { cpuUtilization_ = 0D; onChanged(); return this; } private double memUtilization_ ; /** *
     * Memory utilization expressed as a fraction of available memory
     * resources. This should be derived from the latest sample or measurement.
     * 
* * double mem_utilization = 2 [(.validate.rules) = { ... } * @return The memUtilization. */ @java.lang.Override public double getMemUtilization() { return memUtilization_; } /** *
     * Memory utilization expressed as a fraction of available memory
     * resources. This should be derived from the latest sample or measurement.
     * 
* * double mem_utilization = 2 [(.validate.rules) = { ... } * @param value The memUtilization to set. * @return This builder for chaining. */ public Builder setMemUtilization(double value) { memUtilization_ = value; onChanged(); return this; } /** *
     * Memory utilization expressed as a fraction of available memory
     * resources. This should be derived from the latest sample or measurement.
     * 
* * double mem_utilization = 2 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearMemUtilization() { memUtilization_ = 0D; onChanged(); return this; } private long rps_ ; /** *
     * Total RPS being served by an endpoint. This should cover all services that an endpoint is
     * responsible for.
     * Deprecated -- use ``rps_fractional`` field instead.
     * 
* * uint64 rps = 3 [deprecated = true]; * @deprecated xds.data.orca.v3.OrcaLoadReport.rps is deprecated. * See xds/data/orca/v3/orca_load_report.proto;l=28 * @return The rps. */ @java.lang.Override @java.lang.Deprecated public long getRps() { return rps_; } /** *
     * Total RPS being served by an endpoint. This should cover all services that an endpoint is
     * responsible for.
     * Deprecated -- use ``rps_fractional`` field instead.
     * 
* * uint64 rps = 3 [deprecated = true]; * @deprecated xds.data.orca.v3.OrcaLoadReport.rps is deprecated. * See xds/data/orca/v3/orca_load_report.proto;l=28 * @param value The rps to set. * @return This builder for chaining. */ @java.lang.Deprecated public Builder setRps(long value) { rps_ = value; onChanged(); return this; } /** *
     * Total RPS being served by an endpoint. This should cover all services that an endpoint is
     * responsible for.
     * Deprecated -- use ``rps_fractional`` field instead.
     * 
* * uint64 rps = 3 [deprecated = true]; * @deprecated xds.data.orca.v3.OrcaLoadReport.rps is deprecated. * See xds/data/orca/v3/orca_load_report.proto;l=28 * @return This builder for chaining. */ @java.lang.Deprecated public Builder clearRps() { rps_ = 0L; onChanged(); return this; } private com.google.protobuf.MapField< java.lang.String, java.lang.Double> requestCost_; private com.google.protobuf.MapField internalGetRequestCost() { if (requestCost_ == null) { return com.google.protobuf.MapField.emptyMapField( RequestCostDefaultEntryHolder.defaultEntry); } return requestCost_; } private com.google.protobuf.MapField internalGetMutableRequestCost() { onChanged();; if (requestCost_ == null) { requestCost_ = com.google.protobuf.MapField.newMapField( RequestCostDefaultEntryHolder.defaultEntry); } if (!requestCost_.isMutable()) { requestCost_ = requestCost_.copy(); } return requestCost_; } public int getRequestCostCount() { return internalGetRequestCost().getMap().size(); } /** *
     * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
     * storage) associated with the request.
     * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public boolean containsRequestCost( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetRequestCost().getMap().containsKey(key); } /** * Use {@link #getRequestCostMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getRequestCost() { return getRequestCostMap(); } /** *
     * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
     * storage) associated with the request.
     * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public java.util.Map getRequestCostMap() { return internalGetRequestCost().getMap(); } /** *
     * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
     * storage) associated with the request.
     * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public double getRequestCostOrDefault( java.lang.String key, double defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetRequestCost().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
     * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
     * storage) associated with the request.
     * 
* * map<string, double> request_cost = 4; */ @java.lang.Override public double getRequestCostOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetRequestCost().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public Builder clearRequestCost() { internalGetMutableRequestCost().getMutableMap() .clear(); return this; } /** *
     * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
     * storage) associated with the request.
     * 
* * map<string, double> request_cost = 4; */ public Builder removeRequestCost( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableRequestCost().getMutableMap() .remove(key); return this; } /** * Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableRequestCost() { return internalGetMutableRequestCost().getMutableMap(); } /** *
     * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
     * storage) associated with the request.
     * 
* * map<string, double> request_cost = 4; */ public Builder putRequestCost( java.lang.String key, double value) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableRequestCost().getMutableMap() .put(key, value); return this; } /** *
     * Application specific requests costs. Each value is an absolute cost (e.g. 3487 bytes of
     * storage) associated with the request.
     * 
* * map<string, double> request_cost = 4; */ public Builder putAllRequestCost( java.util.Map values) { internalGetMutableRequestCost().getMutableMap() .putAll(values); return this; } private com.google.protobuf.MapField< java.lang.String, java.lang.Double> utilization_; private com.google.protobuf.MapField internalGetUtilization() { if (utilization_ == null) { return com.google.protobuf.MapField.emptyMapField( UtilizationDefaultEntryHolder.defaultEntry); } return utilization_; } private com.google.protobuf.MapField internalGetMutableUtilization() { onChanged();; if (utilization_ == null) { utilization_ = com.google.protobuf.MapField.newMapField( UtilizationDefaultEntryHolder.defaultEntry); } if (!utilization_.isMutable()) { utilization_ = utilization_.copy(); } return utilization_; } public int getUtilizationCount() { return internalGetUtilization().getMap().size(); } /** *
     * Resource utilization values. Each value is expressed as a fraction of total resources
     * available, derived from the latest sample or measurement.
     * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public boolean containsUtilization( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetUtilization().getMap().containsKey(key); } /** * Use {@link #getUtilizationMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getUtilization() { return getUtilizationMap(); } /** *
     * Resource utilization values. Each value is expressed as a fraction of total resources
     * available, derived from the latest sample or measurement.
     * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public java.util.Map getUtilizationMap() { return internalGetUtilization().getMap(); } /** *
     * Resource utilization values. Each value is expressed as a fraction of total resources
     * available, derived from the latest sample or measurement.
     * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public double getUtilizationOrDefault( java.lang.String key, double defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetUtilization().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
     * Resource utilization values. Each value is expressed as a fraction of total resources
     * available, derived from the latest sample or measurement.
     * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ @java.lang.Override public double getUtilizationOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetUtilization().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public Builder clearUtilization() { internalGetMutableUtilization().getMutableMap() .clear(); return this; } /** *
     * Resource utilization values. Each value is expressed as a fraction of total resources
     * available, derived from the latest sample or measurement.
     * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ public Builder removeUtilization( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableUtilization().getMutableMap() .remove(key); return this; } /** * Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableUtilization() { return internalGetMutableUtilization().getMutableMap(); } /** *
     * Resource utilization values. Each value is expressed as a fraction of total resources
     * available, derived from the latest sample or measurement.
     * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ public Builder putUtilization( java.lang.String key, double value) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableUtilization().getMutableMap() .put(key, value); return this; } /** *
     * Resource utilization values. Each value is expressed as a fraction of total resources
     * available, derived from the latest sample or measurement.
     * 
* * map<string, double> utilization = 5 [(.validate.rules) = { ... } */ public Builder putAllUtilization( java.util.Map values) { internalGetMutableUtilization().getMutableMap() .putAll(values); return this; } private double rpsFractional_ ; /** *
     * Total RPS being served by an endpoint. This should cover all services that an endpoint is
     * responsible for.
     * 
* * double rps_fractional = 6 [(.validate.rules) = { ... } * @return The rpsFractional. */ @java.lang.Override public double getRpsFractional() { return rpsFractional_; } /** *
     * Total RPS being served by an endpoint. This should cover all services that an endpoint is
     * responsible for.
     * 
* * double rps_fractional = 6 [(.validate.rules) = { ... } * @param value The rpsFractional to set. * @return This builder for chaining. */ public Builder setRpsFractional(double value) { rpsFractional_ = value; onChanged(); return this; } /** *
     * Total RPS being served by an endpoint. This should cover all services that an endpoint is
     * responsible for.
     * 
* * double rps_fractional = 6 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearRpsFractional() { rpsFractional_ = 0D; onChanged(); return this; } private double eps_ ; /** *
     * Total EPS (errors/second) being served by an endpoint. This should cover
     * all services that an endpoint is responsible for.
     * 
* * double eps = 7 [(.validate.rules) = { ... } * @return The eps. */ @java.lang.Override public double getEps() { return eps_; } /** *
     * Total EPS (errors/second) being served by an endpoint. This should cover
     * all services that an endpoint is responsible for.
     * 
* * double eps = 7 [(.validate.rules) = { ... } * @param value The eps to set. * @return This builder for chaining. */ public Builder setEps(double value) { eps_ = value; onChanged(); return this; } /** *
     * Total EPS (errors/second) being served by an endpoint. This should cover
     * all services that an endpoint is responsible for.
     * 
* * double eps = 7 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearEps() { eps_ = 0D; onChanged(); return this; } private com.google.protobuf.MapField< java.lang.String, java.lang.Double> namedMetrics_; private com.google.protobuf.MapField internalGetNamedMetrics() { if (namedMetrics_ == null) { return com.google.protobuf.MapField.emptyMapField( NamedMetricsDefaultEntryHolder.defaultEntry); } return namedMetrics_; } private com.google.protobuf.MapField internalGetMutableNamedMetrics() { onChanged();; if (namedMetrics_ == null) { namedMetrics_ = com.google.protobuf.MapField.newMapField( NamedMetricsDefaultEntryHolder.defaultEntry); } if (!namedMetrics_.isMutable()) { namedMetrics_ = namedMetrics_.copy(); } return namedMetrics_; } public int getNamedMetricsCount() { return internalGetNamedMetrics().getMap().size(); } /** *
     * Application specific opaque metrics.
     * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public boolean containsNamedMetrics( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetNamedMetrics().getMap().containsKey(key); } /** * Use {@link #getNamedMetricsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getNamedMetrics() { return getNamedMetricsMap(); } /** *
     * Application specific opaque metrics.
     * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public java.util.Map getNamedMetricsMap() { return internalGetNamedMetrics().getMap(); } /** *
     * Application specific opaque metrics.
     * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public double getNamedMetricsOrDefault( java.lang.String key, double defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetNamedMetrics().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
     * Application specific opaque metrics.
     * 
* * map<string, double> named_metrics = 8; */ @java.lang.Override public double getNamedMetricsOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetNamedMetrics().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public Builder clearNamedMetrics() { internalGetMutableNamedMetrics().getMutableMap() .clear(); return this; } /** *
     * Application specific opaque metrics.
     * 
* * map<string, double> named_metrics = 8; */ public Builder removeNamedMetrics( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableNamedMetrics().getMutableMap() .remove(key); return this; } /** * Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableNamedMetrics() { return internalGetMutableNamedMetrics().getMutableMap(); } /** *
     * Application specific opaque metrics.
     * 
* * map<string, double> named_metrics = 8; */ public Builder putNamedMetrics( java.lang.String key, double value) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableNamedMetrics().getMutableMap() .put(key, value); return this; } /** *
     * Application specific opaque metrics.
     * 
* * map<string, double> named_metrics = 8; */ public Builder putAllNamedMetrics( java.util.Map values) { internalGetMutableNamedMetrics().getMutableMap() .putAll(values); return this; } private double applicationUtilization_ ; /** *
     * Application specific utilization expressed as a fraction of available
     * resources. For example, an application may report the max of CPU and memory
     * utilization for better load balancing if it is both CPU and memory bound.
     * This should be derived from the latest sample or measurement.
     * The value may be larger than 1.0 when the usage exceeds the reporter
     * dependent notion of soft limits.
     * 
* * double application_utilization = 9 [(.validate.rules) = { ... } * @return The applicationUtilization. */ @java.lang.Override public double getApplicationUtilization() { return applicationUtilization_; } /** *
     * Application specific utilization expressed as a fraction of available
     * resources. For example, an application may report the max of CPU and memory
     * utilization for better load balancing if it is both CPU and memory bound.
     * This should be derived from the latest sample or measurement.
     * The value may be larger than 1.0 when the usage exceeds the reporter
     * dependent notion of soft limits.
     * 
* * double application_utilization = 9 [(.validate.rules) = { ... } * @param value The applicationUtilization to set. * @return This builder for chaining. */ public Builder setApplicationUtilization(double value) { applicationUtilization_ = value; onChanged(); return this; } /** *
     * Application specific utilization expressed as a fraction of available
     * resources. For example, an application may report the max of CPU and memory
     * utilization for better load balancing if it is both CPU and memory bound.
     * This should be derived from the latest sample or measurement.
     * The value may be larger than 1.0 when the usage exceeds the reporter
     * dependent notion of soft limits.
     * 
* * double application_utilization = 9 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearApplicationUtilization() { applicationUtilization_ = 0D; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:xds.data.orca.v3.OrcaLoadReport) } // @@protoc_insertion_point(class_scope:xds.data.orca.v3.OrcaLoadReport) private static final com.github.xds.data.orca.v3.OrcaLoadReport DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.github.xds.data.orca.v3.OrcaLoadReport(); } public static com.github.xds.data.orca.v3.OrcaLoadReport getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public OrcaLoadReport parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new OrcaLoadReport(input, extensionRegistry); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.github.xds.data.orca.v3.OrcaLoadReport getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy