Files
threshold/internal/proxy/proxy.pb.go
T
hashicorp-copywrite[bot]andJohan Brandhorst-Satzkorn 29da0bcb92 [COMPLIANCE] License changes (#3567)
* Adding explicit MPL license for sub-package.

This directory and its subdirectories (packages) contain files licensed with the MPLv2 `LICENSE` file in this directory and are intentionally licensed separately from the BSL `LICENSE` file at the root of this repository.

* Adding explicit MPL license for sub-package

This directory and its subdirectories (packages) contain files licensed with the MPLv2 `LICENSE` file in this directory and are intentionally licensed separately from the BSL `LICENSE` file at the root of this repository.

* Updating the license from MPL to Business Source License

Going forward, this project will be licensed under the Business Source License v1.1. Please see our blog post for more details at https://hashi.co/bsl-blog, FAQ at www.hashicorp.com/licensing-faq, and details of the license at www.hashicorp.com/bsl.

* Update copyright file headers to BUS-1.1

* Rerun make gen

This will pick up the last of the license changes

* Revert "Rerun make gen"

This reverts commit dbe0968bffd92745d8663c6940debae098395a6b.

* Remove copywrite from generation script

The current version of copywrite is not sophisticated enough
to only apply the copywrite changes to certain subdirectories,
so to avoid accidentally relicensing our api and sdk modules,
we will stop running the copywrite script until such time
that it can do the right thing.

* License protobuf API as MPL

The protobuf API files are used to generate the SDK,
since we want the SDK to be MPL, the protobuf files
must also be MPL. This extends to all protobuf files
whose sources end up in the SDK directory, including:

- internal/proto/controller/api
- internal/proto/controller/custom_options
- internal/proto/plugin

It also includes the generated service directory in
internal/gen/controller/api/services, since they are
generated from the protobuf sources used for the SDK.

* Change website license file name

This makes the naming scheme consistent with the rest
of the repository.

* Add note on licensing to README

* Set copywrite license to BUSL

* Revert "Add note on licensing to README"

This reverts commit 4d865a91a7a4f11605f0dc4609355d7e3c3cfffe.

---------

Co-authored-by: hashicorp-copywrite[bot] <110428419+hashicorp-copywrite[bot]@users.noreply.github.com>
Co-authored-by: Johan Brandhorst-Satzkorn <johan.brandhorst@gmail.com>
2023-08-11 10:31:53 -07:00

311 lines
11 KiB
Go

// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: BUSL-1.1
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.30.0
// protoc (unknown)
// source: worker/proxy/v1/proxy.proto
package proxy
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
reflect "reflect"
sync "sync"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type HANDSHAKECOMMAND int32
const (
// Note: Unspecified is the desired zero value based on protolint, but for
// our purposes it simply means a normal connection.
HANDSHAKECOMMAND_HANDSHAKECOMMAND_UNSPECIFIED HANDSHAKECOMMAND = 0
HANDSHAKECOMMAND_HANDSHAKECOMMAND_SESSION_CANCEL HANDSHAKECOMMAND = 1
)
// Enum value maps for HANDSHAKECOMMAND.
var (
HANDSHAKECOMMAND_name = map[int32]string{
0: "HANDSHAKECOMMAND_UNSPECIFIED",
1: "HANDSHAKECOMMAND_SESSION_CANCEL",
}
HANDSHAKECOMMAND_value = map[string]int32{
"HANDSHAKECOMMAND_UNSPECIFIED": 0,
"HANDSHAKECOMMAND_SESSION_CANCEL": 1,
}
)
func (x HANDSHAKECOMMAND) Enum() *HANDSHAKECOMMAND {
p := new(HANDSHAKECOMMAND)
*p = x
return p
}
func (x HANDSHAKECOMMAND) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (HANDSHAKECOMMAND) Descriptor() protoreflect.EnumDescriptor {
return file_worker_proxy_v1_proxy_proto_enumTypes[0].Descriptor()
}
func (HANDSHAKECOMMAND) Type() protoreflect.EnumType {
return &file_worker_proxy_v1_proxy_proto_enumTypes[0]
}
func (x HANDSHAKECOMMAND) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use HANDSHAKECOMMAND.Descriptor instead.
func (HANDSHAKECOMMAND) EnumDescriptor() ([]byte, []int) {
return file_worker_proxy_v1_proxy_proto_rawDescGZIP(), []int{0}
}
type ClientHandshake struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
TofuToken string `protobuf:"bytes,10,opt,name=tofu_token,json=tofuToken,proto3" json:"tofu_token,omitempty"`
Command HANDSHAKECOMMAND `protobuf:"varint,20,opt,name=command,proto3,enum=worker.proxy.v1.HANDSHAKECOMMAND" json:"command,omitempty"`
}
func (x *ClientHandshake) Reset() {
*x = ClientHandshake{}
if protoimpl.UnsafeEnabled {
mi := &file_worker_proxy_v1_proxy_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *ClientHandshake) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ClientHandshake) ProtoMessage() {}
func (x *ClientHandshake) ProtoReflect() protoreflect.Message {
mi := &file_worker_proxy_v1_proxy_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ClientHandshake.ProtoReflect.Descriptor instead.
func (*ClientHandshake) Descriptor() ([]byte, []int) {
return file_worker_proxy_v1_proxy_proto_rawDescGZIP(), []int{0}
}
func (x *ClientHandshake) GetTofuToken() string {
if x != nil {
return x.TofuToken
}
return ""
}
func (x *ClientHandshake) GetCommand() HANDSHAKECOMMAND {
if x != nil {
return x.Command
}
return HANDSHAKECOMMAND_HANDSHAKECOMMAND_UNSPECIFIED
}
type HandshakeResult struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Expiration *timestamppb.Timestamp `protobuf:"bytes,10,opt,name=expiration,proto3" json:"expiration,omitempty"`
ConnectionLimit int32 `protobuf:"varint,20,opt,name=connection_limit,json=connectionLimit,proto3" json:"connection_limit,omitempty"`
ConnectionsLeft int32 `protobuf:"varint,30,opt,name=connections_left,json=connectionsLeft,proto3" json:"connections_left,omitempty"`
}
func (x *HandshakeResult) Reset() {
*x = HandshakeResult{}
if protoimpl.UnsafeEnabled {
mi := &file_worker_proxy_v1_proxy_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *HandshakeResult) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*HandshakeResult) ProtoMessage() {}
func (x *HandshakeResult) ProtoReflect() protoreflect.Message {
mi := &file_worker_proxy_v1_proxy_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use HandshakeResult.ProtoReflect.Descriptor instead.
func (*HandshakeResult) Descriptor() ([]byte, []int) {
return file_worker_proxy_v1_proxy_proto_rawDescGZIP(), []int{1}
}
func (x *HandshakeResult) GetExpiration() *timestamppb.Timestamp {
if x != nil {
return x.Expiration
}
return nil
}
func (x *HandshakeResult) GetConnectionLimit() int32 {
if x != nil {
return x.ConnectionLimit
}
return 0
}
func (x *HandshakeResult) GetConnectionsLeft() int32 {
if x != nil {
return x.ConnectionsLeft
}
return 0
}
var File_worker_proxy_v1_proxy_proto protoreflect.FileDescriptor
var file_worker_proxy_v1_proxy_proto_rawDesc = []byte{
0x0a, 0x1b, 0x77, 0x6f, 0x72, 0x6b, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2f, 0x76,
0x31, 0x2f, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, 0x77,
0x6f, 0x72, 0x6b, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x76, 0x31, 0x1a, 0x1f,
0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f,
0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22,
0x6d, 0x0a, 0x0f, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x6e, 0x64, 0x73, 0x68, 0x61,
0x6b, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x74, 0x6f, 0x66, 0x75, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e,
0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x74, 0x6f, 0x66, 0x75, 0x54, 0x6f, 0x6b, 0x65,
0x6e, 0x12, 0x3b, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x18, 0x14, 0x20, 0x01,
0x28, 0x0e, 0x32, 0x21, 0x2e, 0x77, 0x6f, 0x72, 0x6b, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x78,
0x79, 0x2e, 0x76, 0x31, 0x2e, 0x48, 0x41, 0x4e, 0x44, 0x53, 0x48, 0x41, 0x4b, 0x45, 0x43, 0x4f,
0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x22, 0xa3,
0x01, 0x0a, 0x0f, 0x48, 0x61, 0x6e, 0x64, 0x73, 0x68, 0x61, 0x6b, 0x65, 0x52, 0x65, 0x73, 0x75,
0x6c, 0x74, 0x12, 0x3a, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e,
0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61,
0x6d, 0x70, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x29,
0x0a, 0x10, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6c, 0x69, 0x6d,
0x69, 0x74, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63,
0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x29, 0x0a, 0x10, 0x63, 0x6f, 0x6e,
0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x6c, 0x65, 0x66, 0x74, 0x18, 0x1e, 0x20,
0x01, 0x28, 0x05, 0x52, 0x0f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73,
0x4c, 0x65, 0x66, 0x74, 0x2a, 0x59, 0x0a, 0x10, 0x48, 0x41, 0x4e, 0x44, 0x53, 0x48, 0x41, 0x4b,
0x45, 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x12, 0x20, 0x0a, 0x1c, 0x48, 0x41, 0x4e, 0x44,
0x53, 0x48, 0x41, 0x4b, 0x45, 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x5f, 0x55, 0x4e, 0x53,
0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x23, 0x0a, 0x1f, 0x48, 0x41,
0x4e, 0x44, 0x53, 0x48, 0x41, 0x4b, 0x45, 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x5f, 0x53,
0x45, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x43, 0x41, 0x4e, 0x43, 0x45, 0x4c, 0x10, 0x01, 0x42,
0x34, 0x5a, 0x32, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x68, 0x61,
0x73, 0x68, 0x69, 0x63, 0x6f, 0x72, 0x70, 0x2f, 0x62, 0x6f, 0x75, 0x6e, 0x64, 0x61, 0x72, 0x79,
0x2f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2f, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x3b,
0x70, 0x72, 0x6f, 0x78, 0x79, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
file_worker_proxy_v1_proxy_proto_rawDescOnce sync.Once
file_worker_proxy_v1_proxy_proto_rawDescData = file_worker_proxy_v1_proxy_proto_rawDesc
)
func file_worker_proxy_v1_proxy_proto_rawDescGZIP() []byte {
file_worker_proxy_v1_proxy_proto_rawDescOnce.Do(func() {
file_worker_proxy_v1_proxy_proto_rawDescData = protoimpl.X.CompressGZIP(file_worker_proxy_v1_proxy_proto_rawDescData)
})
return file_worker_proxy_v1_proxy_proto_rawDescData
}
var file_worker_proxy_v1_proxy_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_worker_proxy_v1_proxy_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
var file_worker_proxy_v1_proxy_proto_goTypes = []interface{}{
(HANDSHAKECOMMAND)(0), // 0: worker.proxy.v1.HANDSHAKECOMMAND
(*ClientHandshake)(nil), // 1: worker.proxy.v1.ClientHandshake
(*HandshakeResult)(nil), // 2: worker.proxy.v1.HandshakeResult
(*timestamppb.Timestamp)(nil), // 3: google.protobuf.Timestamp
}
var file_worker_proxy_v1_proxy_proto_depIdxs = []int32{
0, // 0: worker.proxy.v1.ClientHandshake.command:type_name -> worker.proxy.v1.HANDSHAKECOMMAND
3, // 1: worker.proxy.v1.HandshakeResult.expiration:type_name -> google.protobuf.Timestamp
2, // [2:2] is the sub-list for method output_type
2, // [2:2] is the sub-list for method input_type
2, // [2:2] is the sub-list for extension type_name
2, // [2:2] is the sub-list for extension extendee
0, // [0:2] is the sub-list for field type_name
}
func init() { file_worker_proxy_v1_proxy_proto_init() }
func file_worker_proxy_v1_proxy_proto_init() {
if File_worker_proxy_v1_proxy_proto != nil {
return
}
if !protoimpl.UnsafeEnabled {
file_worker_proxy_v1_proxy_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*ClientHandshake); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_worker_proxy_v1_proxy_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*HandshakeResult); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_worker_proxy_v1_proxy_proto_rawDesc,
NumEnums: 1,
NumMessages: 2,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_worker_proxy_v1_proxy_proto_goTypes,
DependencyIndexes: file_worker_proxy_v1_proxy_proto_depIdxs,
EnumInfos: file_worker_proxy_v1_proxy_proto_enumTypes,
MessageInfos: file_worker_proxy_v1_proxy_proto_msgTypes,
}.Build()
File_worker_proxy_v1_proxy_proto = out.File
file_worker_proxy_v1_proxy_proto_rawDesc = nil
file_worker_proxy_v1_proxy_proto_goTypes = nil
file_worker_proxy_v1_proxy_proto_depIdxs = nil
}