blob: 001606061223361f9fab98bd5244e6240d255bd7 [file] [log] [blame]
// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. The ASF licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you may not use this file except in compliance
// with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing,
// software distributed under the License is distributed on an
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
// KIND, either express or implied. See the License for the
// specific language governing permissions and limitations
// under the License.
syntax = "proto2";
package heron.proto.system;
option java_package = "org.apache.heron.proto.system";
option java_outer_classname = "PackingPlans";
// This file defines the packing plan of a topology.
// It reflects the the instances and containers of a topology.
message Resource {
required double cpu = 1;
required int64 ram = 2;
required int64 disk = 3;
}
message InstancePlan {
required string component_name = 1;
required int32 task_id = 2; // global
required int32 component_index = 3; // specific to this component
required Resource resource = 4;
}
message ContainerPlan {
required int32 id = 1;
repeated InstancePlan instance_plans = 2;
required Resource requiredResource = 3;
optional Resource scheduledResource = 4;
}
message PackingPlan {
required string id = 1;
repeated ContainerPlan container_plans = 2;
}