|
| 1 | +// |
| 2 | +// Copyright 2020 The Feast Authors |
| 3 | +// |
| 4 | +// Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | +// you may not use this file except in compliance with the License. |
| 6 | +// You may obtain a copy of the License at |
| 7 | +// |
| 8 | +// https://www.apache.org/licenses/LICENSE-2.0 |
| 9 | +// |
| 10 | +// Unless required by applicable law or agreed to in writing, software |
| 11 | +// distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | +// See the License for the specific language governing permissions and |
| 14 | +// limitations under the License. |
| 15 | +// |
| 16 | + |
| 17 | + |
| 18 | +syntax = "proto3"; |
| 19 | +package feast.core; |
| 20 | + |
| 21 | +option go_package = "github.com/feast-dev/feast/go/protos/feast/core"; |
| 22 | +option java_outer_classname = "StreamFeatureViewProto"; |
| 23 | +option java_package = "feast.proto.core"; |
| 24 | + |
| 25 | + |
| 26 | +import "google/protobuf/duration.proto"; |
| 27 | +import "google/protobuf/timestamp.proto"; |
| 28 | +import "feast/core/OnDemandFeatureView.proto"; |
| 29 | +import "feast/core/Feature.proto"; |
| 30 | +import "feast/core/DataSource.proto"; |
| 31 | +import "feast/core/Aggregation.proto"; |
| 32 | + |
| 33 | +message StreamFeatureView { |
| 34 | + // User-specified specifications of this feature view. |
| 35 | + StreamFeatureViewSpec spec = 1; |
| 36 | + StreamFeatureViewMeta meta = 2; |
| 37 | +} |
| 38 | + |
| 39 | +// Next available id: 17 |
| 40 | +message StreamFeatureViewSpec { |
| 41 | + // Name of the feature view. Must be unique. Not updated. |
| 42 | + string name = 1; |
| 43 | + |
| 44 | + // Name of Feast project that this feature view belongs to. |
| 45 | + string project = 2; |
| 46 | + |
| 47 | + // List of names of entities associated with this feature view. |
| 48 | + repeated string entities = 3; |
| 49 | + |
| 50 | + // List of specifications for each feature defined as part of this feature view. |
| 51 | + repeated FeatureSpecV2 features = 4; |
| 52 | + |
| 53 | + // List of specifications for each entity defined as part of this feature view. |
| 54 | + repeated FeatureSpecV2 entity_columns = 5; |
| 55 | + |
| 56 | + // Description of the feature view. |
| 57 | + string description = 6; |
| 58 | + |
| 59 | + // User defined metadata |
| 60 | + map<string,string> tags = 7; |
| 61 | + |
| 62 | + // Owner of the feature view. |
| 63 | + string owner = 8; |
| 64 | + |
| 65 | + // Features in this feature view can only be retrieved from online serving |
| 66 | + // younger than ttl. Ttl is measured as the duration of time between |
| 67 | + // the feature's event timestamp and when the feature is retrieved |
| 68 | + // Feature values outside ttl will be returned as unset values and indicated to end user |
| 69 | + google.protobuf.Duration ttl = 9; |
| 70 | + |
| 71 | + // Batch/Offline DataSource where this view can retrieve offline feature data. |
| 72 | + DataSource batch_source = 10; |
| 73 | + // Streaming DataSource from where this view can consume "online" feature data. |
| 74 | + DataSource stream_source = 11; |
| 75 | + |
| 76 | + // Whether these features should be served online or not |
| 77 | + bool online = 12; |
| 78 | + |
| 79 | + // Serialized function that is encoded in the streamfeatureview |
| 80 | + UserDefinedFunction user_defined_function = 13; |
| 81 | + |
| 82 | + // Mode of execution |
| 83 | + string mode = 14; |
| 84 | + |
| 85 | + // Aggregation definitions |
| 86 | + repeated Aggregation aggregations = 15; |
| 87 | + |
| 88 | + // Timestamp field for aggregation |
| 89 | + string timestamp_field = 16; |
| 90 | +} |
| 91 | + |
| 92 | +message StreamFeatureViewMeta { |
| 93 | + // Time where this Feature View is created |
| 94 | + google.protobuf.Timestamp created_timestamp = 1; |
| 95 | + |
| 96 | + // Time where this Feature View is last updated |
| 97 | + google.protobuf.Timestamp last_updated_timestamp = 2; |
| 98 | +} |
0 commit comments