diff --git a/flyteidl/clients/go/admin/authtype_enumer.go b/flyteidl/clients/go/admin/authtype_enumer.go
new file mode 100644
index 0000000000..0367a3345e
--- /dev/null
+++ b/flyteidl/clients/go/admin/authtype_enumer.go
@@ -0,0 +1,85 @@
+// Code generated by "enumer --type=AuthType -json -yaml -trimprefix=AuthType"; DO NOT EDIT.
+
+//
+package admin
+
+import (
+ "encoding/json"
+ "fmt"
+)
+
+const _AuthTypeName = "ClientSecretPkce"
+
+var _AuthTypeIndex = [...]uint8{0, 12, 16}
+
+func (i AuthType) String() string {
+ if i >= AuthType(len(_AuthTypeIndex)-1) {
+ return fmt.Sprintf("AuthType(%d)", i)
+ }
+ return _AuthTypeName[_AuthTypeIndex[i]:_AuthTypeIndex[i+1]]
+}
+
+var _AuthTypeValues = []AuthType{0, 1}
+
+var _AuthTypeNameToValueMap = map[string]AuthType{
+ _AuthTypeName[0:12]: 0,
+ _AuthTypeName[12:16]: 1,
+}
+
+// AuthTypeString retrieves an enum value from the enum constants string name.
+// Throws an error if the param is not part of the enum.
+func AuthTypeString(s string) (AuthType, error) {
+ if val, ok := _AuthTypeNameToValueMap[s]; ok {
+ return val, nil
+ }
+ return 0, fmt.Errorf("%s does not belong to AuthType values", s)
+}
+
+// AuthTypeValues returns all values of the enum
+func AuthTypeValues() []AuthType {
+ return _AuthTypeValues
+}
+
+// IsAAuthType returns "true" if the value is listed in the enum definition. "false" otherwise
+func (i AuthType) IsAAuthType() bool {
+ for _, v := range _AuthTypeValues {
+ if i == v {
+ return true
+ }
+ }
+ return false
+}
+
+// MarshalJSON implements the json.Marshaler interface for AuthType
+func (i AuthType) MarshalJSON() ([]byte, error) {
+ return json.Marshal(i.String())
+}
+
+// UnmarshalJSON implements the json.Unmarshaler interface for AuthType
+func (i *AuthType) UnmarshalJSON(data []byte) error {
+ var s string
+ if err := json.Unmarshal(data, &s); err != nil {
+ return fmt.Errorf("AuthType should be a string, got %s", data)
+ }
+
+ var err error
+ *i, err = AuthTypeString(s)
+ return err
+}
+
+// MarshalYAML implements a YAML Marshaler for AuthType
+func (i AuthType) MarshalYAML() (interface{}, error) {
+ return i.String(), nil
+}
+
+// UnmarshalYAML implements a YAML Unmarshaler for AuthType
+func (i *AuthType) UnmarshalYAML(unmarshal func(interface{}) error) error {
+ var s string
+ if err := unmarshal(&s); err != nil {
+ return err
+ }
+
+ var err error
+ *i, err = AuthTypeString(s)
+ return err
+}
diff --git a/flyteidl/clients/go/admin/client.go b/flyteidl/clients/go/admin/client.go
index 965ba41805..717cc9a001 100644
--- a/flyteidl/clients/go/admin/client.go
+++ b/flyteidl/clients/go/admin/client.go
@@ -2,20 +2,20 @@ package admin
import (
"context"
- "errors"
"fmt"
"io/ioutil"
- "net/http"
"strings"
"sync"
- "github.com/coreos/go-oidc"
"github.com/flyteorg/flyteidl/clients/go/admin/mocks"
+ "github.com/flyteorg/flyteidl/clients/go/admin/pkce"
"github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
"github.com/flyteorg/flytestdlib/logger"
- grpc_middleware "github.com/grpc-ecosystem/go-grpc-middleware"
- grpc_retry "github.com/grpc-ecosystem/go-grpc-middleware/retry"
- grpc_prometheus "github.com/grpc-ecosystem/go-grpc-prometheus"
+
+ grpcMiddleware "github.com/grpc-ecosystem/go-grpc-middleware"
+ grpcRetry "github.com/grpc-ecosystem/go-grpc-middleware/retry"
+ grpcPrometheus "github.com/grpc-ecosystem/go-grpc-prometheus"
+ "golang.org/x/oauth2"
"golang.org/x/oauth2/clientcredentials"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
@@ -24,26 +24,53 @@ import (
var (
once = sync.Once{}
adminConnection *grpc.ClientConn
+
+ // A new connection just for auth metadata service since it will be used to retrieve auth
+ // related information that's needed to initialize the Clientset.
+ onceAuthMetadata = sync.Once{}
+ authMetadataConnection *grpc.ClientConn
)
+// Clientset contains the clients exposed to communicate with various admin services.
+type Clientset struct {
+ adminServiceClient service.AdminServiceClient
+ authMetadataServiceClient service.AuthMetadataServiceClient
+ identityServiceClient service.IdentityServiceClient
+}
+
+// AdminClient retrieves the AdminServiceClient
+func (c Clientset) AdminClient() service.AdminServiceClient {
+ return c.adminServiceClient
+}
+
+// AuthMetadataClient retrieves the AuthMetadataServiceClient
+func (c Clientset) AuthMetadataClient() service.AuthMetadataServiceClient {
+ return c.authMetadataServiceClient
+}
+
+func (c Clientset) IdentityClient() service.IdentityServiceClient {
+ return c.identityServiceClient
+}
+
func NewAdminClient(ctx context.Context, conn *grpc.ClientConn) service.AdminServiceClient {
logger.Infof(ctx, "Initialized Admin client")
return service.NewAdminServiceClient(conn)
}
-func GetAdditionalAdminClientConfigOptions(cfg Config) []grpc.DialOption {
+func GetAdditionalAdminClientConfigOptions(cfg *Config) []grpc.DialOption {
opts := make([]grpc.DialOption, 0, 2)
backoffConfig := grpc.BackoffConfig{
MaxDelay: cfg.MaxBackoffDelay.Duration,
}
+
opts = append(opts, grpc.WithBackoffConfig(backoffConfig))
- timeoutDialOption := grpc_retry.WithPerRetryTimeout(cfg.PerRetryTimeout.Duration)
- maxRetriesOption := grpc_retry.WithMax(uint(cfg.MaxRetries))
+ timeoutDialOption := grpcRetry.WithPerRetryTimeout(cfg.PerRetryTimeout.Duration)
+ maxRetriesOption := grpcRetry.WithMax(uint(cfg.MaxRetries))
- retryInterceptor := grpc_retry.UnaryClientInterceptor(timeoutDialOption, maxRetriesOption)
- finalUnaryInterceptor := grpc_middleware.ChainUnaryClient(
- grpc_prometheus.UnaryClientInterceptor,
+ retryInterceptor := grpcRetry.UnaryClientInterceptor(timeoutDialOption, maxRetriesOption)
+ finalUnaryInterceptor := grpcMiddleware.ChainUnaryClient(
+ grpcPrometheus.UnaryClientInterceptor,
retryInterceptor,
)
@@ -54,62 +81,116 @@ func GetAdditionalAdminClientConfigOptions(cfg Config) []grpc.DialOption {
return opts
}
-// This function assumes that the authorization server supports the OAuth metadata standard, and uses the oidc
-// library to retrieve the token endpoint.
-func getTokenEndpointFromAuthServer(ctx context.Context, authorizationServer string) (string, error) {
- if authorizationServer == "" {
- logger.Errorf(ctx, "Attempting to construct provider with empty authorizationServer")
- return "", errors.New("cannot get token URL from empty authorizationServer")
+// This retrieves a DialOption that contains a source for generating JWTs for authentication with Flyte Admin. If
+// the token endpoint is set in the config, that will be used, otherwise it'll attempt to make a metadata call.
+func getAuthenticationDialOption(ctx context.Context, cfg *Config, tokenCache pkce.TokenCache,
+ authClient service.AuthMetadataServiceClient) (grpc.DialOption, error) {
+
+ tokenURL := cfg.TokenURL
+ if len(tokenURL) == 0 {
+ metadata, err := authClient.GetOAuth2Metadata(ctx, &service.OAuth2MetadataRequest{})
+ if err != nil {
+ return nil, fmt.Errorf("failed to fetch auth metadata. Error: %v", err)
+ }
+
+ tokenURL = metadata.TokenEndpoint
}
- oidcCtx := oidc.ClientContext(ctx, &http.Client{})
- provider, err := oidc.NewProvider(oidcCtx, authorizationServer)
+ clientMetadata, err := authClient.GetPublicClientConfig(ctx, &service.PublicClientAuthConfigRequest{})
if err != nil {
- logger.Errorf(ctx, "Error when constructing new OIDC Provider")
- return "", err
+ return nil, fmt.Errorf("failed to fetch client metadata. Error: %v", err)
}
- logger.Infof(ctx, "Constructing Admin client with token endpoint %s", provider.Endpoint().TokenURL)
-
- return provider.Endpoint().TokenURL, nil
-}
-// This retrieves a DialOption that contains a source for generating JWTs for authentication with Flyte Admin.
-// It will first attempt to retrieve the token endpoint by making a metadata call. If that fails, but the token endpoint
-// is set in the config, that will be used instead.
-func getAuthenticationDialOption(ctx context.Context, cfg Config) (grpc.DialOption, error) {
- var tokenURL string
- tokenURL, err := getTokenEndpointFromAuthServer(ctx, cfg.AuthorizationServerURL)
- if err != nil || tokenURL == "" {
- logger.Infof(ctx, "No token URL found from configuration Issuer, looking for token endpoint directly")
+ var tSource oauth2.TokenSource
+ if cfg.AuthType == AuthTypeClientSecret {
+ tSource, err = getClientCredentialsTokenSource(ctx, cfg, clientMetadata, tokenURL)
if err != nil {
- logger.Errorf(ctx, "Err is %s", err)
+ return nil, err
}
- tokenURL = cfg.TokenURL
- if tokenURL == "" {
- return nil, errors.New("no token endpoint could be found")
+ } else if cfg.AuthType == AuthTypePkce {
+ tokenOrchestrator, err := pkce.NewTokenOrchestrator(ctx, cfg.PkceConfig, tokenCache, authClient)
+ if err != nil {
+ return nil, err
}
+
+ tSource, err = getPkceAuthTokenSource(ctx, tokenOrchestrator)
+ if err != nil {
+ return nil, err
+ }
+ } else {
+ return nil, fmt.Errorf("unsupported type %v", cfg.AuthType)
}
+ oauthTokenSource := NewCustomHeaderTokenSource(tSource, cfg.UseInsecureConnection, clientMetadata.AuthorizationMetadataKey)
+ return grpc.WithPerRPCCredentials(oauthTokenSource), nil
+}
+
+// Returns the client credentials token source to be used eg by flytepropeller to communicate with admin/ by CI
+func getClientCredentialsTokenSource(ctx context.Context, cfg *Config,
+ clientMetadata *service.PublicClientAuthConfigResponse, tokenURL string) (oauth2.TokenSource, error) {
+
secretBytes, err := ioutil.ReadFile(cfg.ClientSecretLocation)
if err != nil {
logger.Errorf(ctx, "Error reading secret from location %s", cfg.ClientSecretLocation)
return nil, err
}
+
secret := strings.TrimSpace(string(secretBytes))
+ scopes := cfg.Scopes
+ if len(scopes) == 0 {
+ scopes = clientMetadata.Scopes
+ }
ccConfig := clientcredentials.Config{
ClientID: cfg.ClientID,
ClientSecret: secret,
TokenURL: tokenURL,
- Scopes: cfg.Scopes,
+ Scopes: scopes,
}
- tSource := ccConfig.TokenSource(ctx)
- oauthTokenSource := NewCustomHeaderTokenSource(tSource, cfg.AuthorizationHeader)
- return grpc.WithPerRPCCredentials(oauthTokenSource), nil
+
+ return ccConfig.TokenSource(ctx), nil
}
-func NewAdminConnection(ctx context.Context, cfg Config) (*grpc.ClientConn, error) {
- var opts []grpc.DialOption
+// Returns the token source which would be used for three legged oauth. eg : for admin to authorize access to flytectl
+func getPkceAuthTokenSource(ctx context.Context, tokenOrchestrator pkce.TokenOrchestrator) (oauth2.TokenSource, error) {
+ // explicitly ignore error while fetching token from cache.
+ authToken, err := tokenOrchestrator.FetchTokenFromCacheOrRefreshIt(ctx)
+ if err != nil {
+ logger.Warnf(ctx, "Failed fetching from cache. Will restart the flow. Error: %v", err)
+ }
+
+ if authToken == nil {
+ // Fetch using auth flow
+ if authToken, err = tokenOrchestrator.FetchTokenFromAuthFlow(ctx); err != nil {
+ logger.Errorf(ctx, "Error fetching token using auth flow due to %v", err)
+ return nil, err
+ }
+ }
+
+ return &pkce.SimpleTokenSource{
+ CachedToken: authToken,
+ }, nil
+}
+
+// InitializeAuthMetadataClient creates a new anonymously Auth Metadata Service client.
+func InitializeAuthMetadataClient(ctx context.Context, cfg *Config) (client service.AuthMetadataServiceClient, err error) {
+ onceAuthMetadata.Do(func() {
+ authMetadataConnection, err = NewAdminConnection(ctx, cfg)
+ })
+
+ if err != nil {
+ return nil, fmt.Errorf("failed to initialize admin connection. Error: %w", err)
+ }
+
+ return service.NewAuthMetadataServiceClient(authMetadataConnection), nil
+}
+
+func NewAdminConnection(_ context.Context, cfg *Config, opts ...grpc.DialOption) (*grpc.ClientConn, error) {
+ if opts == nil {
+ // Initialize opts list to the potential number of options we will add. Initialization optimizes memory
+ // allocation.
+ opts = make([]grpc.DialOption, 0, 5)
+ }
if cfg.UseInsecureConnection {
opts = append(opts, grpc.WithInsecure())
@@ -117,42 +198,78 @@ func NewAdminConnection(ctx context.Context, cfg Config) (*grpc.ClientConn, erro
// TODO: as of Go 1.11.4, this is not supported on Windows. https://github.com/golang/go/issues/16736
creds := credentials.NewClientTLSFromCert(nil, "")
opts = append(opts, grpc.WithTransportCredentials(creds))
- if cfg.UseAuth {
- logger.Infof(ctx, "Instantiating a token source to authenticate against Admin, ID: %s", cfg.ClientID)
- jwtDialOption, err := getAuthenticationDialOption(ctx, cfg)
- if err != nil {
- return nil, err
- }
- opts = append(opts, jwtDialOption)
- }
}
opts = append(opts, GetAdditionalAdminClientConfigOptions(cfg)...)
+
return grpc.Dial(cfg.Endpoint.String(), opts...)
}
// Create an AdminClient with a shared Admin connection for the process
-func InitializeAdminClient(ctx context.Context, cfg Config) service.AdminServiceClient {
+// Deprecated: Please use initializeClients instead.
+func InitializeAdminClient(ctx context.Context, cfg *Config, opts ...grpc.DialOption) service.AdminServiceClient {
+ set, err := initializeClients(ctx, cfg, nil, opts...)
+ if err != nil {
+ logger.Panicf(ctx, "Failed to initialize client. Error: %v", err)
+ return nil
+ }
+
+ return set.AdminClient()
+}
+
+// initializeClients creates an AdminClient, AuthServiceClient and IdentityServiceClient with a shared Admin connection
+// for the process. Note that if called with different cfg/dialoptions, it will not refresh the connection.
+func initializeClients(ctx context.Context, cfg *Config, tokenCache pkce.TokenCache, opts ...grpc.DialOption) (*Clientset, error) {
once.Do(func() {
- var err error
- adminConnection, err = NewAdminConnection(ctx, cfg)
+ authMetadataClient, err := InitializeAuthMetadataClient(ctx, cfg)
+ if err != nil {
+ logger.Panicf(ctx, "failed to initialize Auth Metadata Client. Error: %v", err)
+ }
+
+ // If auth is enabled, this call will return the required information to use to authenticate, otherwise,
+ // start the client without authentication.
+ opt, err := getAuthenticationDialOption(ctx, cfg, tokenCache, authMetadataClient)
+ if err != nil {
+ logger.Warnf(ctx, "Starting an unauthenticated client because: %v", err)
+ }
+
+ if opt != nil {
+ opts = append(opts, opt)
+ }
+
+ adminConnection, err = NewAdminConnection(ctx, cfg, opts...)
if err != nil {
logger.Panicf(ctx, "failed to initialize Admin connection. Err: %s", err.Error())
}
})
- return NewAdminClient(ctx, adminConnection)
+ var cs Clientset
+ cs.adminServiceClient = NewAdminClient(ctx, adminConnection)
+ cs.authMetadataServiceClient = service.NewAuthMetadataServiceClient(adminConnection)
+ cs.identityServiceClient = service.NewIdentityServiceClient(adminConnection)
+ return &cs, nil
}
-func InitializeAdminClientFromConfig(ctx context.Context) (service.AdminServiceClient, error) {
- cfg := GetConfig(ctx)
- if cfg == nil {
- return nil, fmt.Errorf("retrieved Nil config for [%s] key", configSectionKey)
+// Deprecated: Please use NewClientsetBuilder() instead.
+func InitializeAdminClientFromConfig(ctx context.Context, tokenCache pkce.TokenCache, opts ...grpc.DialOption) (service.AdminServiceClient, error) {
+ clientSet, err := initializeClients(ctx, GetConfig(ctx), tokenCache, opts...)
+ if err != nil {
+ return nil, err
}
- return InitializeAdminClient(ctx, *cfg), nil
+
+ return clientSet.AdminClient(), nil
}
func InitializeMockAdminClient() service.AdminServiceClient {
logger.Infof(context.TODO(), "Initialized Mock Admin client")
return &mocks.AdminServiceClient{}
}
+
+func InitializeMockClientset() *Clientset {
+ logger.Infof(context.TODO(), "Initialized Mock Clientset")
+ return &Clientset{
+ adminServiceClient: &mocks.AdminServiceClient{},
+ authMetadataServiceClient: &mocks.AuthMetadataServiceClient{},
+ identityServiceClient: &mocks.IdentityServiceClient{},
+ }
+}
diff --git a/flyteidl/clients/go/admin/client_builder.go b/flyteidl/clients/go/admin/client_builder.go
new file mode 100644
index 0000000000..11a5098c7f
--- /dev/null
+++ b/flyteidl/clients/go/admin/client_builder.go
@@ -0,0 +1,55 @@
+package admin
+
+import (
+ "context"
+
+ "google.golang.org/grpc"
+
+ "github.com/flyteorg/flyteidl/clients/go/admin/pkce"
+)
+
+// ClientsetBuilder is used to build the clientset. This allows custom token cache implementations to be plugged in.
+type ClientsetBuilder struct {
+ config *Config
+ tokenCache pkce.TokenCache
+ opts []grpc.DialOption
+}
+
+// ClientSetBuilder is constructor function to be used by the clients in interacting with the builder
+func ClientSetBuilder() *ClientsetBuilder {
+ return &ClientsetBuilder{}
+}
+
+// WithConfig provides the admin config to be used for constructing the clientset
+func (cb *ClientsetBuilder) WithConfig(config *Config) *ClientsetBuilder {
+ cb.config = config
+ return cb
+}
+
+// WithTokenCache allows pluggable token cache implemetations. eg; flytectl uses keyring as tokenCache
+func (cb *ClientsetBuilder) WithTokenCache(tokenCache pkce.TokenCache) *ClientsetBuilder {
+ cb.tokenCache = tokenCache
+ return cb
+}
+
+func (cb *ClientsetBuilder) WithDialOptions(opts ...grpc.DialOption) *ClientsetBuilder {
+ cb.opts = opts
+ return cb
+}
+
+// Build the clientset using the current state of the ClientsetBuilder
+func (cb *ClientsetBuilder) Build(ctx context.Context) (*Clientset, error) {
+ if cb.tokenCache == nil {
+ cb.tokenCache = &pkce.TokenCacheInMemoryProvider{}
+ }
+
+ if cb.config == nil {
+ cb.config = GetConfig(ctx)
+ }
+
+ return initializeClients(ctx, cb.config, cb.tokenCache, cb.opts...)
+}
+
+func NewClientsetBuilder() *ClientsetBuilder {
+ return &ClientsetBuilder{}
+}
diff --git a/flyteidl/clients/go/admin/client_builder_test.go b/flyteidl/clients/go/admin/client_builder_test.go
new file mode 100644
index 0000000000..8cca17639b
--- /dev/null
+++ b/flyteidl/clients/go/admin/client_builder_test.go
@@ -0,0 +1,19 @@
+package admin
+
+import (
+ "context"
+ "reflect"
+ "testing"
+
+ "github.com/flyteorg/flyteidl/clients/go/admin/pkce"
+ "github.com/stretchr/testify/assert"
+)
+
+func TestClientsetBuilder_Build(t *testing.T) {
+ cb := NewClientsetBuilder().WithConfig(&Config{
+ UseInsecureConnection: true,
+ }).WithTokenCache(&pkce.TokenCacheInMemoryProvider{})
+ _, err := cb.Build(context.Background())
+ assert.NoError(t, err)
+ assert.True(t, reflect.TypeOf(cb.tokenCache) == reflect.TypeOf(&pkce.TokenCacheInMemoryProvider{}))
+}
diff --git a/flyteidl/clients/go/admin/client_test.go b/flyteidl/clients/go/admin/client_test.go
index 4efad36bc1..b8c5866e0a 100644
--- a/flyteidl/clients/go/admin/client_test.go
+++ b/flyteidl/clients/go/admin/client_test.go
@@ -2,13 +2,25 @@ package admin
import (
"context"
+ "encoding/json"
+ "fmt"
+ "io/ioutil"
+ "net/http"
"net/url"
"sync"
"testing"
"time"
+ "github.com/flyteorg/flyteidl/clients/go/admin/mocks"
+ "github.com/flyteorg/flyteidl/clients/go/admin/pkce"
+ pkcemocks "github.com/flyteorg/flyteidl/clients/go/admin/pkce/mocks"
+ "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
"github.com/flyteorg/flytestdlib/config"
+ "github.com/flyteorg/flytestdlib/logger"
+
"github.com/stretchr/testify/assert"
+ "github.com/stretchr/testify/mock"
+ "golang.org/x/oauth2"
)
func TestInitializeAndGetAdminClient(t *testing.T) {
@@ -17,18 +29,24 @@ func TestInitializeAndGetAdminClient(t *testing.T) {
t.Run("legal", func(t *testing.T) {
u, err := url.Parse("http://localhost:8089")
assert.NoError(t, err)
- assert.NotNil(t, InitializeAdminClient(ctx, Config{
+ assert.NotNil(t, InitializeAdminClient(ctx, &Config{
Endpoint: config.URL{URL: *u},
}))
})
t.Run("illegal", func(t *testing.T) {
- adminConnection = nil
once = sync.Once{}
- assert.NotNil(t, InitializeAdminClient(ctx, Config{}))
+ assert.NotNil(t, InitializeAdminClient(ctx, &Config{}))
})
}
+func TestInitializeMockClientset(t *testing.T) {
+ c := InitializeMockClientset()
+ assert.NotNil(t, c)
+ assert.NotNil(t, c.adminServiceClient)
+ assert.NotNil(t, c.authMetadataServiceClient)
+}
+
func TestInitializeMockAdminClient(t *testing.T) {
c := InitializeMockAdminClient()
assert.NotNil(t, c)
@@ -36,12 +54,200 @@ func TestInitializeMockAdminClient(t *testing.T) {
func TestGetAdditionalAdminClientConfigOptions(t *testing.T) {
u, _ := url.Parse("localhost:8089")
- adminServiceConfig := Config{
+ adminServiceConfig := &Config{
+ Endpoint: config.URL{URL: *u},
+ UseInsecureConnection: true,
+ PerRetryTimeout: config.Duration{Duration: 1 * time.Second},
+ }
+
+ assert.NoError(t, SetConfig(adminServiceConfig))
+
+ ctx := context.Background()
+ t.Run("legal", func(t *testing.T) {
+ u, err := url.Parse("http://localhost:8089")
+ assert.NoError(t, err)
+ clientSet, err := ClientSetBuilder().WithConfig(&Config{Endpoint: config.URL{URL: *u}}).Build(ctx)
+ assert.NoError(t, err)
+ assert.NotNil(t, clientSet)
+ assert.NotNil(t, clientSet.AdminClient())
+ assert.NotNil(t, clientSet.AuthMetadataClient())
+ assert.NotNil(t, clientSet.IdentityClient())
+ })
+
+ t.Run("legal-from-config", func(t *testing.T) {
+ clientSet, err := initializeClients(ctx, &Config{}, nil)
+ assert.NoError(t, err)
+ assert.NotNil(t, clientSet)
+ assert.NotNil(t, clientSet.AuthMetadataClient())
+ assert.NotNil(t, clientSet.AdminClient())
+ })
+}
+
+func TestGetAuthenticationDialOptionClientSecret(t *testing.T) {
+ ctx := context.Background()
+
+ u, _ := url.Parse("localhost:8089")
+ adminServiceConfig := &Config{
+ ClientSecretLocation: "testdata/secret_key",
+ Endpoint: config.URL{URL: *u},
+ UseInsecureConnection: true,
+ AuthType: AuthTypeClientSecret,
+ PerRetryTimeout: config.Duration{Duration: 1 * time.Second},
+ }
+ t.Run("legal", func(t *testing.T) {
+ metatdata := &service.OAuth2MetadataResponse{
+ TokenEndpoint: "http://localhost:8089/token",
+ ScopesSupported: []string{"code", "all"},
+ }
+ clientMetatadata := &service.PublicClientAuthConfigResponse{
+ AuthorizationMetadataKey: "flyte_authorization",
+ }
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(clientMetatadata, nil)
+ dialOption, err := getAuthenticationDialOption(ctx, adminServiceConfig, nil, mockAuthClient)
+ assert.NotNil(t, dialOption)
+ assert.Nil(t, err)
+ })
+ t.Run("error during oauth2Metatdata", func(t *testing.T) {
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(nil, fmt.Errorf("failed"))
+ dialOption, err := getAuthenticationDialOption(ctx, adminServiceConfig, nil, mockAuthClient)
+ assert.Nil(t, dialOption)
+ assert.NotNil(t, err)
+ })
+ t.Run("error during flyte client", func(t *testing.T) {
+ metatdata := &service.OAuth2MetadataResponse{
+ TokenEndpoint: "/token",
+ ScopesSupported: []string{"code", "all"},
+ }
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(nil, fmt.Errorf("failed"))
+ dialOption, err := getAuthenticationDialOption(ctx, adminServiceConfig, nil, mockAuthClient)
+ assert.Nil(t, dialOption)
+ assert.NotNil(t, err)
+ })
+ incorrectSecretLocConfig := &Config{
+ ClientSecretLocation: "testdata/secret_key_invalid",
+ Endpoint: config.URL{URL: *u},
+ UseInsecureConnection: true,
+ AuthType: AuthTypeClientSecret,
+ PerRetryTimeout: config.Duration{Duration: 1 * time.Second},
+ }
+ t.Run("incorrect client secret loc", func(t *testing.T) {
+ metatdata := &service.OAuth2MetadataResponse{
+ TokenEndpoint: "http://localhost:8089/token",
+ ScopesSupported: []string{"code", "all"},
+ }
+ clientMetatadata := &service.PublicClientAuthConfigResponse{
+ AuthorizationMetadataKey: "flyte_authorization",
+ }
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(clientMetatadata, nil)
+ dialOption, err := getAuthenticationDialOption(ctx, incorrectSecretLocConfig, nil, mockAuthClient)
+ assert.Nil(t, dialOption)
+ assert.NotNil(t, err)
+ })
+}
+
+func TestGetAuthenticationDialOptionPkce(t *testing.T) {
+ ctx := context.Background()
+
+ u, _ := url.Parse("localhost:8089")
+ adminServiceConfig := &Config{
Endpoint: config.URL{URL: *u},
UseInsecureConnection: true,
+ AuthType: AuthTypePkce,
PerRetryTimeout: config.Duration{Duration: 1 * time.Second},
- MaxRetries: 1,
}
- opts := GetAdditionalAdminClientConfigOptions(adminServiceConfig)
- assert.Equal(t, 2, len(opts))
+ metatdata := &service.OAuth2MetadataResponse{
+ TokenEndpoint: "http://localhost:8089/token",
+ ScopesSupported: []string{"code", "all"},
+ }
+ clientMetatadata := &service.PublicClientAuthConfigResponse{
+ AuthorizationMetadataKey: "flyte_authorization",
+ RedirectUri: "http://localhost:54545/callback",
+ }
+ http.DefaultServeMux = http.NewServeMux()
+ plan, _ := ioutil.ReadFile("pkce/testdata/token.json")
+ var tokenData oauth2.Token
+ err := json.Unmarshal(plan, &tokenData)
+ assert.NoError(t, err)
+ tokenData.Expiry = time.Now().Add(time.Minute)
+ t.Run("cache hit", func(t *testing.T) {
+ mockTokenCache := new(pkcemocks.TokenCache)
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockTokenCache.OnGetTokenMatch().Return(&tokenData, nil)
+ mockTokenCache.OnSaveTokenMatch(mock.Anything).Return(nil)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(clientMetatadata, nil)
+ dialOption, err := getAuthenticationDialOption(ctx, adminServiceConfig, mockTokenCache, mockAuthClient)
+ assert.NotNil(t, dialOption)
+ assert.Nil(t, err)
+ })
+ tokenData.Expiry = time.Now().Add(-time.Minute)
+ t.Run("cache miss auth failure", func(t *testing.T) {
+ mockTokenCache := new(pkcemocks.TokenCache)
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockTokenCache.OnGetTokenMatch().Return(&tokenData, nil)
+ mockTokenCache.OnSaveTokenMatch(mock.Anything).Return(nil)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(clientMetatadata, nil)
+ dialOption, err := getAuthenticationDialOption(ctx, adminServiceConfig, mockTokenCache, mockAuthClient)
+ assert.Nil(t, dialOption)
+ assert.NotNil(t, err)
+ })
+}
+
+func Test_getPkceAuthTokenSource(t *testing.T) {
+ ctx := context.Background()
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ metatdata := &service.OAuth2MetadataResponse{
+ TokenEndpoint: "http://localhost:8089/token",
+ ScopesSupported: []string{"code", "all"},
+ }
+
+ clientMetatadata := &service.PublicClientAuthConfigResponse{
+ AuthorizationMetadataKey: "flyte_authorization",
+ RedirectUri: "http://localhost:54546/callback",
+ }
+
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(clientMetatadata, nil)
+
+ t.Run("cached token expired", func(t *testing.T) {
+ plan, _ := ioutil.ReadFile("pkce/testdata/token.json")
+ var tokenData oauth2.Token
+ err := json.Unmarshal(plan, &tokenData)
+ assert.NoError(t, err)
+
+ // populate the cache
+ tokenCache := &pkce.TokenCacheInMemoryProvider{}
+ assert.NoError(t, tokenCache.SaveToken(&tokenData))
+
+ orchestrator, err := pkce.NewTokenOrchestrator(ctx, pkce.Config{}, tokenCache, mockAuthClient)
+ assert.NoError(t, err)
+
+ http.DefaultServeMux = http.NewServeMux()
+ dialOption, err := getPkceAuthTokenSource(ctx, orchestrator)
+ assert.Nil(t, dialOption)
+ assert.Error(t, err)
+ })
+}
+
+func ExampleClientSetBuilder() {
+ ctx := context.Background()
+ // Create a client set that initializes the connection with flyte admin and sets up Auth (if needed).
+ // See AuthType for a list of supported authentication types.
+ clientSet, err := NewClientsetBuilder().WithConfig(GetConfig(ctx)).Build(ctx)
+ if err != nil {
+ logger.Fatalf(ctx, "failed to initialize clientSet from config. Error: %v", err)
+ }
+
+ // Access and use the desired client:
+ _ = clientSet.AdminClient()
+ _ = clientSet.AuthMetadataClient()
+ _ = clientSet.IdentityClient()
}
diff --git a/flyteidl/clients/go/admin/config.go b/flyteidl/clients/go/admin/config.go
index 4aebc82b40..af1d4f9fbe 100644
--- a/flyteidl/clients/go/admin/config.go
+++ b/flyteidl/clients/go/admin/config.go
@@ -1,16 +1,38 @@
+// Initializes an Admin Client that exposes all implemented services by FlyteAdmin server. The library supports different
+// authentication flows (see AuthType). It initializes the grpc connection once and reuses it. The gRPC connection is
+// sticky (it hogs one server and keeps the connection alive). For better load balancing against the server, place a
+// proxy service in between instead.
package admin
import (
"context"
+ "path/filepath"
"time"
+ "github.com/flyteorg/flyteidl/clients/go/admin/pkce"
+
"github.com/flyteorg/flytestdlib/config"
"github.com/flyteorg/flytestdlib/logger"
)
//go:generate pflags Config --default-var=defaultConfig
-const configSectionKey = "admin"
+const (
+ configSectionKey = "admin"
+ DefaultClientID = "flytepropeller"
+)
+
+var DefaultClientSecretLocation = filepath.Join(string(filepath.Separator), "etc", "secrets", "client_secret")
+
+//go:generate enumer --type=AuthType -json -yaml -trimprefix=AuthType
+type AuthType uint8
+
+const (
+ // Chooses Client Secret OAuth2 protocol (ref: https://tools.ietf.org/html/rfc6749#section-4.4)
+ AuthTypeClientSecret AuthType = iota
+ // Chooses Proof Key Code Exchange OAuth2 extension protocol (ref: https://tools.ietf.org/html/rfc7636)
+ AuthTypePkce
+)
type Config struct {
Endpoint config.URL `json:"endpoint" pflag:",For admin types, specify where the uri of the service is located."`
@@ -18,39 +40,47 @@ type Config struct {
MaxBackoffDelay config.Duration `json:"maxBackoffDelay" pflag:",Max delay for grpc backoff"`
PerRetryTimeout config.Duration `json:"perRetryTimeout" pflag:",gRPC per retry timeout"`
MaxRetries int `json:"maxRetries" pflag:",Max number of gRPC retries"`
-
- // Auth can only be used if also running with a secure connection. If UseInsecureConnection is set to true, none
- // of the following options will even be referenced.
- UseAuth bool `json:"useAuth" pflag:",Whether or not to try to authenticate with options below"`
+ AuthType AuthType `json:"authType" pflag:"-,Type of OAuth2 flow used for communicating with admin."`
+ // Deprecated: settings will be discovered dynamically
+ DeprecatedUseAuth bool `json:"useAuth" pflag:",Deprecated: Auth will be enabled/disabled based on admin's dynamically discovered information."`
ClientID string `json:"clientId" pflag:",Client ID"`
ClientSecretLocation string `json:"clientSecretLocation" pflag:",File containing the client secret"`
Scopes []string `json:"scopes" pflag:",List of scopes to request"`
// There are two ways to get the token URL. If the authorization server url is provided, the client will try to use RFC 8414 to
// try to get the token URL. Or it can be specified directly through TokenURL config.
- AuthorizationServerURL string `json:"authorizationServerUrl" pflag:",This is the URL to your IDP's authorization server'"`
- TokenURL string `json:"tokenUrl" pflag:",Your IDPs token endpoint"`
+ // Deprecated: This will now be discovered through admin's anonymously accessible metadata.
+ DeprecatedAuthorizationServerURL string `json:"authorizationServerUrl" pflag:",This is the URL to your IdP's authorization server. It'll default to Endpoint"`
+ // If not provided, it'll be discovered through admin's anonymously accessible metadata endpoint.
+ TokenURL string `json:"tokenUrl" pflag:",OPTIONAL: Your IdP's token endpoint. It'll be discovered from flyte admin's OAuth Metadata endpoint if not provided."`
// See the implementation of the 'grpcAuthorizationHeader' option in Flyte Admin for more information. But
// basically we want to be able to use a different string to pass the token from this client to the the Admin service
// because things might be running in a service mesh (like Envoy) that already uses the default 'authorization' header
- AuthorizationHeader string `json:"authorizationHeader" pflag:",Custom metadata header to pass JWT"`
+ // Deprecated: It will automatically be discovered through an anonymously accessible auth metadata service.
+ DeprecatedAuthorizationHeader string `json:"authorizationHeader" pflag:",Custom metadata header to pass JWT"`
+
+ PkceConfig pkce.Config `json:"pkceConfig" pflag:",Config for Pkce authentication flow."`
}
var (
defaultConfig = Config{
- MaxBackoffDelay: config.Duration{Duration: 8 * time.Second},
- PerRetryTimeout: config.Duration{Duration: 15 * time.Second},
- MaxRetries: 4,
+ MaxBackoffDelay: config.Duration{Duration: 8 * time.Second},
+ PerRetryTimeout: config.Duration{Duration: 15 * time.Second},
+ MaxRetries: 4,
+ ClientID: DefaultClientID,
+ AuthType: AuthTypeClientSecret,
+ ClientSecretLocation: DefaultClientSecretLocation,
+ PkceConfig: pkce.Config{
+ TokenRefreshGracePeriod: config.Duration{Duration: 5 * time.Minute},
+ BrowserSessionTimeout: config.Duration{Duration: 15 * time.Second},
+ },
}
+
configSection = config.MustRegisterSectionWithUpdates(configSectionKey, &defaultConfig, func(ctx context.Context, newValue config.Config) {
if newValue.(*Config).MaxRetries < 0 {
logger.Panicf(ctx, "Admin configuration given with negative gRPC retry value.")
}
-
- if newValue.(*Config).UseAuth {
- logger.Warnf(ctx, "Admin client config has authentication ON with server %s", newValue.(*Config).AuthorizationServerURL)
- }
})
)
@@ -62,3 +92,7 @@ func GetConfig(ctx context.Context) *Config {
logger.Warnf(ctx, "Failed to retrieve config section [%v].", configSectionKey)
return nil
}
+
+func SetConfig(cfg *Config) error {
+ return configSection.SetConfig(cfg)
+}
diff --git a/flyteidl/clients/go/admin/config_flags.go b/flyteidl/clients/go/admin/config_flags.go
index 541634d86f..45772e8ad5 100755
--- a/flyteidl/clients/go/admin/config_flags.go
+++ b/flyteidl/clients/go/admin/config_flags.go
@@ -46,12 +46,12 @@ func (cfg Config) GetPFlagSet(prefix string) *pflag.FlagSet {
cmdFlags.String(fmt.Sprintf("%v%v", prefix, "maxBackoffDelay"), defaultConfig.MaxBackoffDelay.String(), "Max delay for grpc backoff")
cmdFlags.String(fmt.Sprintf("%v%v", prefix, "perRetryTimeout"), defaultConfig.PerRetryTimeout.String(), "gRPC per retry timeout")
cmdFlags.Int(fmt.Sprintf("%v%v", prefix, "maxRetries"), defaultConfig.MaxRetries, "Max number of gRPC retries")
- cmdFlags.Bool(fmt.Sprintf("%v%v", prefix, "useAuth"), defaultConfig.UseAuth, "Whether or not to try to authenticate with options below")
+ cmdFlags.Bool(fmt.Sprintf("%v%v", prefix, "useAuth"), defaultConfig.DeprecatedUseAuth, "Deprecated: Auth will be enabled/disabled based on admin's dynamically discovered information.")
cmdFlags.String(fmt.Sprintf("%v%v", prefix, "clientId"), defaultConfig.ClientID, "Client ID")
cmdFlags.String(fmt.Sprintf("%v%v", prefix, "clientSecretLocation"), defaultConfig.ClientSecretLocation, "File containing the client secret")
cmdFlags.StringSlice(fmt.Sprintf("%v%v", prefix, "scopes"), []string{}, "List of scopes to request")
- cmdFlags.String(fmt.Sprintf("%v%v", prefix, "authorizationServerUrl"), defaultConfig.AuthorizationServerURL, "This is the URL to your IDP's authorization server'")
- cmdFlags.String(fmt.Sprintf("%v%v", prefix, "tokenUrl"), defaultConfig.TokenURL, "Your IDPs token endpoint")
- cmdFlags.String(fmt.Sprintf("%v%v", prefix, "authorizationHeader"), defaultConfig.AuthorizationHeader, "Custom metadata header to pass JWT")
+ cmdFlags.String(fmt.Sprintf("%v%v", prefix, "authorizationServerUrl"), defaultConfig.DeprecatedAuthorizationServerURL, "This is the URL to your IdP's authorization server. It'll default to Endpoint")
+ cmdFlags.String(fmt.Sprintf("%v%v", prefix, "tokenUrl"), defaultConfig.TokenURL, "OPTIONAL: Your IdP's token endpoint. It'll be discovered from flyte admin's OAuth Metadata endpoint if not provided.")
+ cmdFlags.String(fmt.Sprintf("%v%v", prefix, "authorizationHeader"), defaultConfig.DeprecatedAuthorizationHeader, "Custom metadata header to pass JWT")
return cmdFlags
}
diff --git a/flyteidl/clients/go/admin/config_flags_test.go b/flyteidl/clients/go/admin/config_flags_test.go
index 4a7440c8a9..e33b5caa9c 100755
--- a/flyteidl/clients/go/admin/config_flags_test.go
+++ b/flyteidl/clients/go/admin/config_flags_test.go
@@ -213,7 +213,7 @@ func TestConfig_SetFlags(t *testing.T) {
t.Run("DefaultValue", func(t *testing.T) {
// Test that default value is set properly
if vBool, err := cmdFlags.GetBool("useAuth"); err == nil {
- assert.Equal(t, bool(defaultConfig.UseAuth), vBool)
+ assert.Equal(t, bool(defaultConfig.DeprecatedUseAuth), vBool)
} else {
assert.FailNow(t, err.Error())
}
@@ -224,7 +224,7 @@ func TestConfig_SetFlags(t *testing.T) {
cmdFlags.Set("useAuth", testValue)
if vBool, err := cmdFlags.GetBool("useAuth"); err == nil {
- testDecodeJson_Config(t, fmt.Sprintf("%v", vBool), &actual.UseAuth)
+ testDecodeJson_Config(t, fmt.Sprintf("%v", vBool), &actual.DeprecatedUseAuth)
} else {
assert.FailNow(t, err.Error())
@@ -301,7 +301,7 @@ func TestConfig_SetFlags(t *testing.T) {
t.Run("DefaultValue", func(t *testing.T) {
// Test that default value is set properly
if vString, err := cmdFlags.GetString("authorizationServerUrl"); err == nil {
- assert.Equal(t, string(defaultConfig.AuthorizationServerURL), vString)
+ assert.Equal(t, string(defaultConfig.DeprecatedAuthorizationServerURL), vString)
} else {
assert.FailNow(t, err.Error())
}
@@ -312,7 +312,7 @@ func TestConfig_SetFlags(t *testing.T) {
cmdFlags.Set("authorizationServerUrl", testValue)
if vString, err := cmdFlags.GetString("authorizationServerUrl"); err == nil {
- testDecodeJson_Config(t, fmt.Sprintf("%v", vString), &actual.AuthorizationServerURL)
+ testDecodeJson_Config(t, fmt.Sprintf("%v", vString), &actual.DeprecatedAuthorizationServerURL)
} else {
assert.FailNow(t, err.Error())
@@ -345,7 +345,7 @@ func TestConfig_SetFlags(t *testing.T) {
t.Run("DefaultValue", func(t *testing.T) {
// Test that default value is set properly
if vString, err := cmdFlags.GetString("authorizationHeader"); err == nil {
- assert.Equal(t, string(defaultConfig.AuthorizationHeader), vString)
+ assert.Equal(t, string(defaultConfig.DeprecatedAuthorizationHeader), vString)
} else {
assert.FailNow(t, err.Error())
}
@@ -356,7 +356,7 @@ func TestConfig_SetFlags(t *testing.T) {
cmdFlags.Set("authorizationHeader", testValue)
if vString, err := cmdFlags.GetString("authorizationHeader"); err == nil {
- testDecodeJson_Config(t, fmt.Sprintf("%v", vString), &actual.AuthorizationHeader)
+ testDecodeJson_Config(t, fmt.Sprintf("%v", vString), &actual.DeprecatedAuthorizationHeader)
} else {
assert.FailNow(t, err.Error())
diff --git a/flyteidl/clients/go/admin/integration_test.go b/flyteidl/clients/go/admin/integration_test.go
index 64beb265ea..3349bbe203 100644
--- a/flyteidl/clients/go/admin/integration_test.go
+++ b/flyteidl/clients/go/admin/integration_test.go
@@ -9,6 +9,8 @@ import (
"testing"
"time"
+ "google.golang.org/grpc"
+
"golang.org/x/oauth2/clientcredentials"
"github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/admin"
@@ -22,14 +24,14 @@ func TestLiveAdminClient(t *testing.T) {
u, err := url.Parse("dns:///flyte.lyft.net")
assert.NoError(t, err)
client := InitializeAdminClient(ctx, Config{
- Endpoint: config.URL{URL: *u},
- UseInsecureConnection: false,
- UseAuth: true,
- ClientId: "0oacmtueinpXk72Af1t7",
- ClientSecretLocation: "/Users/username/.ssh/admin/propeller_secret",
- AuthorizationServerURL: "https://lyft.okta.com/oauth2/ausc5wmjw96cRKvTd1t7",
- Scopes: []string{"svc"},
- AuthorizationHeader: "Flyte-Authorization",
+ Endpoint: config.URL{URL: *u},
+ UseInsecureConnection: false,
+ UseAuth: true,
+ ClientID: "0oacmtueinpXk72Af1t7",
+ ClientSecretLocation: "/Users/username/.ssh/admin/propeller_secret",
+ DeprecatedAuthorizationServerURL: "https://lyft.okta.com/oauth2/ausc5wmjw96cRKvTd1t7",
+ Scopes: []string{"svc"},
+ DeprecatedAuthorizationHeader: "Flyte-Authorization",
})
resp, err := client.ListProjects(ctx, &admin.ProjectListRequest{})
@@ -40,21 +42,14 @@ func TestLiveAdminClient(t *testing.T) {
fmt.Printf("Response: %v\n", resp)
}
-func TestGetTokenEndpoint(t *testing.T) {
- ctx := context.Background()
-
- endpoint, err := getTokenEndpointFromAuthServer(ctx, "https://flyte-staging.lyft.net")
- assert.NoError(t, err)
- assert.NotEmpty(t, endpoint)
-}
-
func TestGetDialOption(t *testing.T) {
ctx := context.Background()
cfg := Config{
- AuthorizationServerURL: "https://lyft.okta.com/oauth2/ausc5wmjw96cRKvTd1t7",
+ DeprecatedAuthorizationServerURL: "https://lyft.okta.com/oauth2/ausc5wmjw96cRKvTd1t7",
}
- dialOption, err := getAuthenticationDialOption(ctx, cfg)
+
+ dialOption, err := getAuthenticationDialOption(ctx, cfg, []grpc.DialOption{})
assert.NoError(t, err)
assert.NotNil(t, dialOption)
}
diff --git a/flyteidl/clients/go/admin/mocks/AdminServiceServer.go b/flyteidl/clients/go/admin/mocks/AdminServiceServer.go
new file mode 100644
index 0000000000..27aeecc87f
--- /dev/null
+++ b/flyteidl/clients/go/admin/mocks/AdminServiceServer.go
@@ -0,0 +1,1861 @@
+// Code generated by mockery v1.0.1. DO NOT EDIT.
+
+package mocks
+
+import (
+ context "context"
+
+ admin "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/admin"
+
+ mock "github.com/stretchr/testify/mock"
+)
+
+// AdminServiceServer is an autogenerated mock type for the AdminServiceServer type
+type AdminServiceServer struct {
+ mock.Mock
+}
+
+type AdminServiceServer_CreateExecution struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_CreateExecution) Return(_a0 *admin.ExecutionCreateResponse, _a1 error) *AdminServiceServer_CreateExecution {
+ return &AdminServiceServer_CreateExecution{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnCreateExecution(_a0 context.Context, _a1 *admin.ExecutionCreateRequest) *AdminServiceServer_CreateExecution {
+ c := _m.On("CreateExecution", _a0, _a1)
+ return &AdminServiceServer_CreateExecution{Call: c}
+}
+
+func (_m *AdminServiceServer) OnCreateExecutionMatch(matchers ...interface{}) *AdminServiceServer_CreateExecution {
+ c := _m.On("CreateExecution", matchers...)
+ return &AdminServiceServer_CreateExecution{Call: c}
+}
+
+// CreateExecution provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) CreateExecution(_a0 context.Context, _a1 *admin.ExecutionCreateRequest) (*admin.ExecutionCreateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ExecutionCreateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ExecutionCreateRequest) *admin.ExecutionCreateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ExecutionCreateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ExecutionCreateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_CreateLaunchPlan struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_CreateLaunchPlan) Return(_a0 *admin.LaunchPlanCreateResponse, _a1 error) *AdminServiceServer_CreateLaunchPlan {
+ return &AdminServiceServer_CreateLaunchPlan{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnCreateLaunchPlan(_a0 context.Context, _a1 *admin.LaunchPlanCreateRequest) *AdminServiceServer_CreateLaunchPlan {
+ c := _m.On("CreateLaunchPlan", _a0, _a1)
+ return &AdminServiceServer_CreateLaunchPlan{Call: c}
+}
+
+func (_m *AdminServiceServer) OnCreateLaunchPlanMatch(matchers ...interface{}) *AdminServiceServer_CreateLaunchPlan {
+ c := _m.On("CreateLaunchPlan", matchers...)
+ return &AdminServiceServer_CreateLaunchPlan{Call: c}
+}
+
+// CreateLaunchPlan provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) CreateLaunchPlan(_a0 context.Context, _a1 *admin.LaunchPlanCreateRequest) (*admin.LaunchPlanCreateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.LaunchPlanCreateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.LaunchPlanCreateRequest) *admin.LaunchPlanCreateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.LaunchPlanCreateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.LaunchPlanCreateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_CreateNodeEvent struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_CreateNodeEvent) Return(_a0 *admin.NodeExecutionEventResponse, _a1 error) *AdminServiceServer_CreateNodeEvent {
+ return &AdminServiceServer_CreateNodeEvent{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnCreateNodeEvent(_a0 context.Context, _a1 *admin.NodeExecutionEventRequest) *AdminServiceServer_CreateNodeEvent {
+ c := _m.On("CreateNodeEvent", _a0, _a1)
+ return &AdminServiceServer_CreateNodeEvent{Call: c}
+}
+
+func (_m *AdminServiceServer) OnCreateNodeEventMatch(matchers ...interface{}) *AdminServiceServer_CreateNodeEvent {
+ c := _m.On("CreateNodeEvent", matchers...)
+ return &AdminServiceServer_CreateNodeEvent{Call: c}
+}
+
+// CreateNodeEvent provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) CreateNodeEvent(_a0 context.Context, _a1 *admin.NodeExecutionEventRequest) (*admin.NodeExecutionEventResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NodeExecutionEventResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NodeExecutionEventRequest) *admin.NodeExecutionEventResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NodeExecutionEventResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NodeExecutionEventRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_CreateTask struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_CreateTask) Return(_a0 *admin.TaskCreateResponse, _a1 error) *AdminServiceServer_CreateTask {
+ return &AdminServiceServer_CreateTask{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnCreateTask(_a0 context.Context, _a1 *admin.TaskCreateRequest) *AdminServiceServer_CreateTask {
+ c := _m.On("CreateTask", _a0, _a1)
+ return &AdminServiceServer_CreateTask{Call: c}
+}
+
+func (_m *AdminServiceServer) OnCreateTaskMatch(matchers ...interface{}) *AdminServiceServer_CreateTask {
+ c := _m.On("CreateTask", matchers...)
+ return &AdminServiceServer_CreateTask{Call: c}
+}
+
+// CreateTask provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) CreateTask(_a0 context.Context, _a1 *admin.TaskCreateRequest) (*admin.TaskCreateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.TaskCreateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.TaskCreateRequest) *admin.TaskCreateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.TaskCreateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.TaskCreateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_CreateTaskEvent struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_CreateTaskEvent) Return(_a0 *admin.TaskExecutionEventResponse, _a1 error) *AdminServiceServer_CreateTaskEvent {
+ return &AdminServiceServer_CreateTaskEvent{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnCreateTaskEvent(_a0 context.Context, _a1 *admin.TaskExecutionEventRequest) *AdminServiceServer_CreateTaskEvent {
+ c := _m.On("CreateTaskEvent", _a0, _a1)
+ return &AdminServiceServer_CreateTaskEvent{Call: c}
+}
+
+func (_m *AdminServiceServer) OnCreateTaskEventMatch(matchers ...interface{}) *AdminServiceServer_CreateTaskEvent {
+ c := _m.On("CreateTaskEvent", matchers...)
+ return &AdminServiceServer_CreateTaskEvent{Call: c}
+}
+
+// CreateTaskEvent provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) CreateTaskEvent(_a0 context.Context, _a1 *admin.TaskExecutionEventRequest) (*admin.TaskExecutionEventResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.TaskExecutionEventResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.TaskExecutionEventRequest) *admin.TaskExecutionEventResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.TaskExecutionEventResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.TaskExecutionEventRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_CreateWorkflow struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_CreateWorkflow) Return(_a0 *admin.WorkflowCreateResponse, _a1 error) *AdminServiceServer_CreateWorkflow {
+ return &AdminServiceServer_CreateWorkflow{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnCreateWorkflow(_a0 context.Context, _a1 *admin.WorkflowCreateRequest) *AdminServiceServer_CreateWorkflow {
+ c := _m.On("CreateWorkflow", _a0, _a1)
+ return &AdminServiceServer_CreateWorkflow{Call: c}
+}
+
+func (_m *AdminServiceServer) OnCreateWorkflowMatch(matchers ...interface{}) *AdminServiceServer_CreateWorkflow {
+ c := _m.On("CreateWorkflow", matchers...)
+ return &AdminServiceServer_CreateWorkflow{Call: c}
+}
+
+// CreateWorkflow provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) CreateWorkflow(_a0 context.Context, _a1 *admin.WorkflowCreateRequest) (*admin.WorkflowCreateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.WorkflowCreateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.WorkflowCreateRequest) *admin.WorkflowCreateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.WorkflowCreateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.WorkflowCreateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_CreateWorkflowEvent struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_CreateWorkflowEvent) Return(_a0 *admin.WorkflowExecutionEventResponse, _a1 error) *AdminServiceServer_CreateWorkflowEvent {
+ return &AdminServiceServer_CreateWorkflowEvent{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnCreateWorkflowEvent(_a0 context.Context, _a1 *admin.WorkflowExecutionEventRequest) *AdminServiceServer_CreateWorkflowEvent {
+ c := _m.On("CreateWorkflowEvent", _a0, _a1)
+ return &AdminServiceServer_CreateWorkflowEvent{Call: c}
+}
+
+func (_m *AdminServiceServer) OnCreateWorkflowEventMatch(matchers ...interface{}) *AdminServiceServer_CreateWorkflowEvent {
+ c := _m.On("CreateWorkflowEvent", matchers...)
+ return &AdminServiceServer_CreateWorkflowEvent{Call: c}
+}
+
+// CreateWorkflowEvent provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) CreateWorkflowEvent(_a0 context.Context, _a1 *admin.WorkflowExecutionEventRequest) (*admin.WorkflowExecutionEventResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.WorkflowExecutionEventResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.WorkflowExecutionEventRequest) *admin.WorkflowExecutionEventResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.WorkflowExecutionEventResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.WorkflowExecutionEventRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_DeleteProjectDomainAttributes struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_DeleteProjectDomainAttributes) Return(_a0 *admin.ProjectDomainAttributesDeleteResponse, _a1 error) *AdminServiceServer_DeleteProjectDomainAttributes {
+ return &AdminServiceServer_DeleteProjectDomainAttributes{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnDeleteProjectDomainAttributes(_a0 context.Context, _a1 *admin.ProjectDomainAttributesDeleteRequest) *AdminServiceServer_DeleteProjectDomainAttributes {
+ c := _m.On("DeleteProjectDomainAttributes", _a0, _a1)
+ return &AdminServiceServer_DeleteProjectDomainAttributes{Call: c}
+}
+
+func (_m *AdminServiceServer) OnDeleteProjectDomainAttributesMatch(matchers ...interface{}) *AdminServiceServer_DeleteProjectDomainAttributes {
+ c := _m.On("DeleteProjectDomainAttributes", matchers...)
+ return &AdminServiceServer_DeleteProjectDomainAttributes{Call: c}
+}
+
+// DeleteProjectDomainAttributes provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) DeleteProjectDomainAttributes(_a0 context.Context, _a1 *admin.ProjectDomainAttributesDeleteRequest) (*admin.ProjectDomainAttributesDeleteResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ProjectDomainAttributesDeleteResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ProjectDomainAttributesDeleteRequest) *admin.ProjectDomainAttributesDeleteResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ProjectDomainAttributesDeleteResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ProjectDomainAttributesDeleteRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_DeleteWorkflowAttributes struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_DeleteWorkflowAttributes) Return(_a0 *admin.WorkflowAttributesDeleteResponse, _a1 error) *AdminServiceServer_DeleteWorkflowAttributes {
+ return &AdminServiceServer_DeleteWorkflowAttributes{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnDeleteWorkflowAttributes(_a0 context.Context, _a1 *admin.WorkflowAttributesDeleteRequest) *AdminServiceServer_DeleteWorkflowAttributes {
+ c := _m.On("DeleteWorkflowAttributes", _a0, _a1)
+ return &AdminServiceServer_DeleteWorkflowAttributes{Call: c}
+}
+
+func (_m *AdminServiceServer) OnDeleteWorkflowAttributesMatch(matchers ...interface{}) *AdminServiceServer_DeleteWorkflowAttributes {
+ c := _m.On("DeleteWorkflowAttributes", matchers...)
+ return &AdminServiceServer_DeleteWorkflowAttributes{Call: c}
+}
+
+// DeleteWorkflowAttributes provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) DeleteWorkflowAttributes(_a0 context.Context, _a1 *admin.WorkflowAttributesDeleteRequest) (*admin.WorkflowAttributesDeleteResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.WorkflowAttributesDeleteResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.WorkflowAttributesDeleteRequest) *admin.WorkflowAttributesDeleteResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.WorkflowAttributesDeleteResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.WorkflowAttributesDeleteRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetActiveLaunchPlan struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetActiveLaunchPlan) Return(_a0 *admin.LaunchPlan, _a1 error) *AdminServiceServer_GetActiveLaunchPlan {
+ return &AdminServiceServer_GetActiveLaunchPlan{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetActiveLaunchPlan(_a0 context.Context, _a1 *admin.ActiveLaunchPlanRequest) *AdminServiceServer_GetActiveLaunchPlan {
+ c := _m.On("GetActiveLaunchPlan", _a0, _a1)
+ return &AdminServiceServer_GetActiveLaunchPlan{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetActiveLaunchPlanMatch(matchers ...interface{}) *AdminServiceServer_GetActiveLaunchPlan {
+ c := _m.On("GetActiveLaunchPlan", matchers...)
+ return &AdminServiceServer_GetActiveLaunchPlan{Call: c}
+}
+
+// GetActiveLaunchPlan provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetActiveLaunchPlan(_a0 context.Context, _a1 *admin.ActiveLaunchPlanRequest) (*admin.LaunchPlan, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.LaunchPlan
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ActiveLaunchPlanRequest) *admin.LaunchPlan); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.LaunchPlan)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ActiveLaunchPlanRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetExecution struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetExecution) Return(_a0 *admin.Execution, _a1 error) *AdminServiceServer_GetExecution {
+ return &AdminServiceServer_GetExecution{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetExecution(_a0 context.Context, _a1 *admin.WorkflowExecutionGetRequest) *AdminServiceServer_GetExecution {
+ c := _m.On("GetExecution", _a0, _a1)
+ return &AdminServiceServer_GetExecution{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetExecutionMatch(matchers ...interface{}) *AdminServiceServer_GetExecution {
+ c := _m.On("GetExecution", matchers...)
+ return &AdminServiceServer_GetExecution{Call: c}
+}
+
+// GetExecution provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetExecution(_a0 context.Context, _a1 *admin.WorkflowExecutionGetRequest) (*admin.Execution, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.Execution
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.WorkflowExecutionGetRequest) *admin.Execution); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.Execution)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.WorkflowExecutionGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetExecutionData struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetExecutionData) Return(_a0 *admin.WorkflowExecutionGetDataResponse, _a1 error) *AdminServiceServer_GetExecutionData {
+ return &AdminServiceServer_GetExecutionData{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetExecutionData(_a0 context.Context, _a1 *admin.WorkflowExecutionGetDataRequest) *AdminServiceServer_GetExecutionData {
+ c := _m.On("GetExecutionData", _a0, _a1)
+ return &AdminServiceServer_GetExecutionData{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetExecutionDataMatch(matchers ...interface{}) *AdminServiceServer_GetExecutionData {
+ c := _m.On("GetExecutionData", matchers...)
+ return &AdminServiceServer_GetExecutionData{Call: c}
+}
+
+// GetExecutionData provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetExecutionData(_a0 context.Context, _a1 *admin.WorkflowExecutionGetDataRequest) (*admin.WorkflowExecutionGetDataResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.WorkflowExecutionGetDataResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.WorkflowExecutionGetDataRequest) *admin.WorkflowExecutionGetDataResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.WorkflowExecutionGetDataResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.WorkflowExecutionGetDataRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetLaunchPlan struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetLaunchPlan) Return(_a0 *admin.LaunchPlan, _a1 error) *AdminServiceServer_GetLaunchPlan {
+ return &AdminServiceServer_GetLaunchPlan{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetLaunchPlan(_a0 context.Context, _a1 *admin.ObjectGetRequest) *AdminServiceServer_GetLaunchPlan {
+ c := _m.On("GetLaunchPlan", _a0, _a1)
+ return &AdminServiceServer_GetLaunchPlan{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetLaunchPlanMatch(matchers ...interface{}) *AdminServiceServer_GetLaunchPlan {
+ c := _m.On("GetLaunchPlan", matchers...)
+ return &AdminServiceServer_GetLaunchPlan{Call: c}
+}
+
+// GetLaunchPlan provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetLaunchPlan(_a0 context.Context, _a1 *admin.ObjectGetRequest) (*admin.LaunchPlan, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.LaunchPlan
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ObjectGetRequest) *admin.LaunchPlan); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.LaunchPlan)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ObjectGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetNamedEntity struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetNamedEntity) Return(_a0 *admin.NamedEntity, _a1 error) *AdminServiceServer_GetNamedEntity {
+ return &AdminServiceServer_GetNamedEntity{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetNamedEntity(_a0 context.Context, _a1 *admin.NamedEntityGetRequest) *AdminServiceServer_GetNamedEntity {
+ c := _m.On("GetNamedEntity", _a0, _a1)
+ return &AdminServiceServer_GetNamedEntity{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetNamedEntityMatch(matchers ...interface{}) *AdminServiceServer_GetNamedEntity {
+ c := _m.On("GetNamedEntity", matchers...)
+ return &AdminServiceServer_GetNamedEntity{Call: c}
+}
+
+// GetNamedEntity provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetNamedEntity(_a0 context.Context, _a1 *admin.NamedEntityGetRequest) (*admin.NamedEntity, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NamedEntity
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NamedEntityGetRequest) *admin.NamedEntity); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NamedEntity)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NamedEntityGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetNodeExecution struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetNodeExecution) Return(_a0 *admin.NodeExecution, _a1 error) *AdminServiceServer_GetNodeExecution {
+ return &AdminServiceServer_GetNodeExecution{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetNodeExecution(_a0 context.Context, _a1 *admin.NodeExecutionGetRequest) *AdminServiceServer_GetNodeExecution {
+ c := _m.On("GetNodeExecution", _a0, _a1)
+ return &AdminServiceServer_GetNodeExecution{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetNodeExecutionMatch(matchers ...interface{}) *AdminServiceServer_GetNodeExecution {
+ c := _m.On("GetNodeExecution", matchers...)
+ return &AdminServiceServer_GetNodeExecution{Call: c}
+}
+
+// GetNodeExecution provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetNodeExecution(_a0 context.Context, _a1 *admin.NodeExecutionGetRequest) (*admin.NodeExecution, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NodeExecution
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NodeExecutionGetRequest) *admin.NodeExecution); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NodeExecution)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NodeExecutionGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetNodeExecutionData struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetNodeExecutionData) Return(_a0 *admin.NodeExecutionGetDataResponse, _a1 error) *AdminServiceServer_GetNodeExecutionData {
+ return &AdminServiceServer_GetNodeExecutionData{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetNodeExecutionData(_a0 context.Context, _a1 *admin.NodeExecutionGetDataRequest) *AdminServiceServer_GetNodeExecutionData {
+ c := _m.On("GetNodeExecutionData", _a0, _a1)
+ return &AdminServiceServer_GetNodeExecutionData{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetNodeExecutionDataMatch(matchers ...interface{}) *AdminServiceServer_GetNodeExecutionData {
+ c := _m.On("GetNodeExecutionData", matchers...)
+ return &AdminServiceServer_GetNodeExecutionData{Call: c}
+}
+
+// GetNodeExecutionData provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetNodeExecutionData(_a0 context.Context, _a1 *admin.NodeExecutionGetDataRequest) (*admin.NodeExecutionGetDataResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NodeExecutionGetDataResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NodeExecutionGetDataRequest) *admin.NodeExecutionGetDataResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NodeExecutionGetDataResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NodeExecutionGetDataRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetProjectDomainAttributes struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetProjectDomainAttributes) Return(_a0 *admin.ProjectDomainAttributesGetResponse, _a1 error) *AdminServiceServer_GetProjectDomainAttributes {
+ return &AdminServiceServer_GetProjectDomainAttributes{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetProjectDomainAttributes(_a0 context.Context, _a1 *admin.ProjectDomainAttributesGetRequest) *AdminServiceServer_GetProjectDomainAttributes {
+ c := _m.On("GetProjectDomainAttributes", _a0, _a1)
+ return &AdminServiceServer_GetProjectDomainAttributes{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetProjectDomainAttributesMatch(matchers ...interface{}) *AdminServiceServer_GetProjectDomainAttributes {
+ c := _m.On("GetProjectDomainAttributes", matchers...)
+ return &AdminServiceServer_GetProjectDomainAttributes{Call: c}
+}
+
+// GetProjectDomainAttributes provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetProjectDomainAttributes(_a0 context.Context, _a1 *admin.ProjectDomainAttributesGetRequest) (*admin.ProjectDomainAttributesGetResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ProjectDomainAttributesGetResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ProjectDomainAttributesGetRequest) *admin.ProjectDomainAttributesGetResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ProjectDomainAttributesGetResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ProjectDomainAttributesGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetTask struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetTask) Return(_a0 *admin.Task, _a1 error) *AdminServiceServer_GetTask {
+ return &AdminServiceServer_GetTask{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetTask(_a0 context.Context, _a1 *admin.ObjectGetRequest) *AdminServiceServer_GetTask {
+ c := _m.On("GetTask", _a0, _a1)
+ return &AdminServiceServer_GetTask{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetTaskMatch(matchers ...interface{}) *AdminServiceServer_GetTask {
+ c := _m.On("GetTask", matchers...)
+ return &AdminServiceServer_GetTask{Call: c}
+}
+
+// GetTask provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetTask(_a0 context.Context, _a1 *admin.ObjectGetRequest) (*admin.Task, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.Task
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ObjectGetRequest) *admin.Task); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.Task)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ObjectGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetTaskExecution struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetTaskExecution) Return(_a0 *admin.TaskExecution, _a1 error) *AdminServiceServer_GetTaskExecution {
+ return &AdminServiceServer_GetTaskExecution{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetTaskExecution(_a0 context.Context, _a1 *admin.TaskExecutionGetRequest) *AdminServiceServer_GetTaskExecution {
+ c := _m.On("GetTaskExecution", _a0, _a1)
+ return &AdminServiceServer_GetTaskExecution{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetTaskExecutionMatch(matchers ...interface{}) *AdminServiceServer_GetTaskExecution {
+ c := _m.On("GetTaskExecution", matchers...)
+ return &AdminServiceServer_GetTaskExecution{Call: c}
+}
+
+// GetTaskExecution provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetTaskExecution(_a0 context.Context, _a1 *admin.TaskExecutionGetRequest) (*admin.TaskExecution, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.TaskExecution
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.TaskExecutionGetRequest) *admin.TaskExecution); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.TaskExecution)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.TaskExecutionGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetTaskExecutionData struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetTaskExecutionData) Return(_a0 *admin.TaskExecutionGetDataResponse, _a1 error) *AdminServiceServer_GetTaskExecutionData {
+ return &AdminServiceServer_GetTaskExecutionData{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetTaskExecutionData(_a0 context.Context, _a1 *admin.TaskExecutionGetDataRequest) *AdminServiceServer_GetTaskExecutionData {
+ c := _m.On("GetTaskExecutionData", _a0, _a1)
+ return &AdminServiceServer_GetTaskExecutionData{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetTaskExecutionDataMatch(matchers ...interface{}) *AdminServiceServer_GetTaskExecutionData {
+ c := _m.On("GetTaskExecutionData", matchers...)
+ return &AdminServiceServer_GetTaskExecutionData{Call: c}
+}
+
+// GetTaskExecutionData provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetTaskExecutionData(_a0 context.Context, _a1 *admin.TaskExecutionGetDataRequest) (*admin.TaskExecutionGetDataResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.TaskExecutionGetDataResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.TaskExecutionGetDataRequest) *admin.TaskExecutionGetDataResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.TaskExecutionGetDataResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.TaskExecutionGetDataRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetVersion struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetVersion) Return(_a0 *admin.GetVersionResponse, _a1 error) *AdminServiceServer_GetVersion {
+ return &AdminServiceServer_GetVersion{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetVersion(_a0 context.Context, _a1 *admin.GetVersionRequest) *AdminServiceServer_GetVersion {
+ c := _m.On("GetVersion", _a0, _a1)
+ return &AdminServiceServer_GetVersion{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetVersionMatch(matchers ...interface{}) *AdminServiceServer_GetVersion {
+ c := _m.On("GetVersion", matchers...)
+ return &AdminServiceServer_GetVersion{Call: c}
+}
+
+// GetVersion provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetVersion(_a0 context.Context, _a1 *admin.GetVersionRequest) (*admin.GetVersionResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.GetVersionResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.GetVersionRequest) *admin.GetVersionResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.GetVersionResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.GetVersionRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetWorkflow struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetWorkflow) Return(_a0 *admin.Workflow, _a1 error) *AdminServiceServer_GetWorkflow {
+ return &AdminServiceServer_GetWorkflow{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetWorkflow(_a0 context.Context, _a1 *admin.ObjectGetRequest) *AdminServiceServer_GetWorkflow {
+ c := _m.On("GetWorkflow", _a0, _a1)
+ return &AdminServiceServer_GetWorkflow{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetWorkflowMatch(matchers ...interface{}) *AdminServiceServer_GetWorkflow {
+ c := _m.On("GetWorkflow", matchers...)
+ return &AdminServiceServer_GetWorkflow{Call: c}
+}
+
+// GetWorkflow provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetWorkflow(_a0 context.Context, _a1 *admin.ObjectGetRequest) (*admin.Workflow, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.Workflow
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ObjectGetRequest) *admin.Workflow); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.Workflow)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ObjectGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_GetWorkflowAttributes struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_GetWorkflowAttributes) Return(_a0 *admin.WorkflowAttributesGetResponse, _a1 error) *AdminServiceServer_GetWorkflowAttributes {
+ return &AdminServiceServer_GetWorkflowAttributes{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnGetWorkflowAttributes(_a0 context.Context, _a1 *admin.WorkflowAttributesGetRequest) *AdminServiceServer_GetWorkflowAttributes {
+ c := _m.On("GetWorkflowAttributes", _a0, _a1)
+ return &AdminServiceServer_GetWorkflowAttributes{Call: c}
+}
+
+func (_m *AdminServiceServer) OnGetWorkflowAttributesMatch(matchers ...interface{}) *AdminServiceServer_GetWorkflowAttributes {
+ c := _m.On("GetWorkflowAttributes", matchers...)
+ return &AdminServiceServer_GetWorkflowAttributes{Call: c}
+}
+
+// GetWorkflowAttributes provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) GetWorkflowAttributes(_a0 context.Context, _a1 *admin.WorkflowAttributesGetRequest) (*admin.WorkflowAttributesGetResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.WorkflowAttributesGetResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.WorkflowAttributesGetRequest) *admin.WorkflowAttributesGetResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.WorkflowAttributesGetResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.WorkflowAttributesGetRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListActiveLaunchPlans struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListActiveLaunchPlans) Return(_a0 *admin.LaunchPlanList, _a1 error) *AdminServiceServer_ListActiveLaunchPlans {
+ return &AdminServiceServer_ListActiveLaunchPlans{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListActiveLaunchPlans(_a0 context.Context, _a1 *admin.ActiveLaunchPlanListRequest) *AdminServiceServer_ListActiveLaunchPlans {
+ c := _m.On("ListActiveLaunchPlans", _a0, _a1)
+ return &AdminServiceServer_ListActiveLaunchPlans{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListActiveLaunchPlansMatch(matchers ...interface{}) *AdminServiceServer_ListActiveLaunchPlans {
+ c := _m.On("ListActiveLaunchPlans", matchers...)
+ return &AdminServiceServer_ListActiveLaunchPlans{Call: c}
+}
+
+// ListActiveLaunchPlans provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListActiveLaunchPlans(_a0 context.Context, _a1 *admin.ActiveLaunchPlanListRequest) (*admin.LaunchPlanList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.LaunchPlanList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ActiveLaunchPlanListRequest) *admin.LaunchPlanList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.LaunchPlanList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ActiveLaunchPlanListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListExecutions struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListExecutions) Return(_a0 *admin.ExecutionList, _a1 error) *AdminServiceServer_ListExecutions {
+ return &AdminServiceServer_ListExecutions{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListExecutions(_a0 context.Context, _a1 *admin.ResourceListRequest) *AdminServiceServer_ListExecutions {
+ c := _m.On("ListExecutions", _a0, _a1)
+ return &AdminServiceServer_ListExecutions{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListExecutionsMatch(matchers ...interface{}) *AdminServiceServer_ListExecutions {
+ c := _m.On("ListExecutions", matchers...)
+ return &AdminServiceServer_ListExecutions{Call: c}
+}
+
+// ListExecutions provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListExecutions(_a0 context.Context, _a1 *admin.ResourceListRequest) (*admin.ExecutionList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ExecutionList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ResourceListRequest) *admin.ExecutionList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ExecutionList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ResourceListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListLaunchPlanIds struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListLaunchPlanIds) Return(_a0 *admin.NamedEntityIdentifierList, _a1 error) *AdminServiceServer_ListLaunchPlanIds {
+ return &AdminServiceServer_ListLaunchPlanIds{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListLaunchPlanIds(_a0 context.Context, _a1 *admin.NamedEntityIdentifierListRequest) *AdminServiceServer_ListLaunchPlanIds {
+ c := _m.On("ListLaunchPlanIds", _a0, _a1)
+ return &AdminServiceServer_ListLaunchPlanIds{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListLaunchPlanIdsMatch(matchers ...interface{}) *AdminServiceServer_ListLaunchPlanIds {
+ c := _m.On("ListLaunchPlanIds", matchers...)
+ return &AdminServiceServer_ListLaunchPlanIds{Call: c}
+}
+
+// ListLaunchPlanIds provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListLaunchPlanIds(_a0 context.Context, _a1 *admin.NamedEntityIdentifierListRequest) (*admin.NamedEntityIdentifierList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NamedEntityIdentifierList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NamedEntityIdentifierListRequest) *admin.NamedEntityIdentifierList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NamedEntityIdentifierList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NamedEntityIdentifierListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListLaunchPlans struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListLaunchPlans) Return(_a0 *admin.LaunchPlanList, _a1 error) *AdminServiceServer_ListLaunchPlans {
+ return &AdminServiceServer_ListLaunchPlans{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListLaunchPlans(_a0 context.Context, _a1 *admin.ResourceListRequest) *AdminServiceServer_ListLaunchPlans {
+ c := _m.On("ListLaunchPlans", _a0, _a1)
+ return &AdminServiceServer_ListLaunchPlans{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListLaunchPlansMatch(matchers ...interface{}) *AdminServiceServer_ListLaunchPlans {
+ c := _m.On("ListLaunchPlans", matchers...)
+ return &AdminServiceServer_ListLaunchPlans{Call: c}
+}
+
+// ListLaunchPlans provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListLaunchPlans(_a0 context.Context, _a1 *admin.ResourceListRequest) (*admin.LaunchPlanList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.LaunchPlanList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ResourceListRequest) *admin.LaunchPlanList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.LaunchPlanList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ResourceListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListMatchableAttributes struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListMatchableAttributes) Return(_a0 *admin.ListMatchableAttributesResponse, _a1 error) *AdminServiceServer_ListMatchableAttributes {
+ return &AdminServiceServer_ListMatchableAttributes{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListMatchableAttributes(_a0 context.Context, _a1 *admin.ListMatchableAttributesRequest) *AdminServiceServer_ListMatchableAttributes {
+ c := _m.On("ListMatchableAttributes", _a0, _a1)
+ return &AdminServiceServer_ListMatchableAttributes{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListMatchableAttributesMatch(matchers ...interface{}) *AdminServiceServer_ListMatchableAttributes {
+ c := _m.On("ListMatchableAttributes", matchers...)
+ return &AdminServiceServer_ListMatchableAttributes{Call: c}
+}
+
+// ListMatchableAttributes provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListMatchableAttributes(_a0 context.Context, _a1 *admin.ListMatchableAttributesRequest) (*admin.ListMatchableAttributesResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ListMatchableAttributesResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ListMatchableAttributesRequest) *admin.ListMatchableAttributesResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ListMatchableAttributesResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ListMatchableAttributesRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListNamedEntities struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListNamedEntities) Return(_a0 *admin.NamedEntityList, _a1 error) *AdminServiceServer_ListNamedEntities {
+ return &AdminServiceServer_ListNamedEntities{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListNamedEntities(_a0 context.Context, _a1 *admin.NamedEntityListRequest) *AdminServiceServer_ListNamedEntities {
+ c := _m.On("ListNamedEntities", _a0, _a1)
+ return &AdminServiceServer_ListNamedEntities{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListNamedEntitiesMatch(matchers ...interface{}) *AdminServiceServer_ListNamedEntities {
+ c := _m.On("ListNamedEntities", matchers...)
+ return &AdminServiceServer_ListNamedEntities{Call: c}
+}
+
+// ListNamedEntities provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListNamedEntities(_a0 context.Context, _a1 *admin.NamedEntityListRequest) (*admin.NamedEntityList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NamedEntityList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NamedEntityListRequest) *admin.NamedEntityList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NamedEntityList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NamedEntityListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListNodeExecutions struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListNodeExecutions) Return(_a0 *admin.NodeExecutionList, _a1 error) *AdminServiceServer_ListNodeExecutions {
+ return &AdminServiceServer_ListNodeExecutions{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListNodeExecutions(_a0 context.Context, _a1 *admin.NodeExecutionListRequest) *AdminServiceServer_ListNodeExecutions {
+ c := _m.On("ListNodeExecutions", _a0, _a1)
+ return &AdminServiceServer_ListNodeExecutions{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListNodeExecutionsMatch(matchers ...interface{}) *AdminServiceServer_ListNodeExecutions {
+ c := _m.On("ListNodeExecutions", matchers...)
+ return &AdminServiceServer_ListNodeExecutions{Call: c}
+}
+
+// ListNodeExecutions provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListNodeExecutions(_a0 context.Context, _a1 *admin.NodeExecutionListRequest) (*admin.NodeExecutionList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NodeExecutionList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NodeExecutionListRequest) *admin.NodeExecutionList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NodeExecutionList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NodeExecutionListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListNodeExecutionsForTask struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListNodeExecutionsForTask) Return(_a0 *admin.NodeExecutionList, _a1 error) *AdminServiceServer_ListNodeExecutionsForTask {
+ return &AdminServiceServer_ListNodeExecutionsForTask{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListNodeExecutionsForTask(_a0 context.Context, _a1 *admin.NodeExecutionForTaskListRequest) *AdminServiceServer_ListNodeExecutionsForTask {
+ c := _m.On("ListNodeExecutionsForTask", _a0, _a1)
+ return &AdminServiceServer_ListNodeExecutionsForTask{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListNodeExecutionsForTaskMatch(matchers ...interface{}) *AdminServiceServer_ListNodeExecutionsForTask {
+ c := _m.On("ListNodeExecutionsForTask", matchers...)
+ return &AdminServiceServer_ListNodeExecutionsForTask{Call: c}
+}
+
+// ListNodeExecutionsForTask provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListNodeExecutionsForTask(_a0 context.Context, _a1 *admin.NodeExecutionForTaskListRequest) (*admin.NodeExecutionList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NodeExecutionList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NodeExecutionForTaskListRequest) *admin.NodeExecutionList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NodeExecutionList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NodeExecutionForTaskListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListProjects struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListProjects) Return(_a0 *admin.Projects, _a1 error) *AdminServiceServer_ListProjects {
+ return &AdminServiceServer_ListProjects{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListProjects(_a0 context.Context, _a1 *admin.ProjectListRequest) *AdminServiceServer_ListProjects {
+ c := _m.On("ListProjects", _a0, _a1)
+ return &AdminServiceServer_ListProjects{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListProjectsMatch(matchers ...interface{}) *AdminServiceServer_ListProjects {
+ c := _m.On("ListProjects", matchers...)
+ return &AdminServiceServer_ListProjects{Call: c}
+}
+
+// ListProjects provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListProjects(_a0 context.Context, _a1 *admin.ProjectListRequest) (*admin.Projects, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.Projects
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ProjectListRequest) *admin.Projects); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.Projects)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ProjectListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListTaskExecutions struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListTaskExecutions) Return(_a0 *admin.TaskExecutionList, _a1 error) *AdminServiceServer_ListTaskExecutions {
+ return &AdminServiceServer_ListTaskExecutions{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListTaskExecutions(_a0 context.Context, _a1 *admin.TaskExecutionListRequest) *AdminServiceServer_ListTaskExecutions {
+ c := _m.On("ListTaskExecutions", _a0, _a1)
+ return &AdminServiceServer_ListTaskExecutions{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListTaskExecutionsMatch(matchers ...interface{}) *AdminServiceServer_ListTaskExecutions {
+ c := _m.On("ListTaskExecutions", matchers...)
+ return &AdminServiceServer_ListTaskExecutions{Call: c}
+}
+
+// ListTaskExecutions provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListTaskExecutions(_a0 context.Context, _a1 *admin.TaskExecutionListRequest) (*admin.TaskExecutionList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.TaskExecutionList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.TaskExecutionListRequest) *admin.TaskExecutionList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.TaskExecutionList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.TaskExecutionListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListTaskIds struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListTaskIds) Return(_a0 *admin.NamedEntityIdentifierList, _a1 error) *AdminServiceServer_ListTaskIds {
+ return &AdminServiceServer_ListTaskIds{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListTaskIds(_a0 context.Context, _a1 *admin.NamedEntityIdentifierListRequest) *AdminServiceServer_ListTaskIds {
+ c := _m.On("ListTaskIds", _a0, _a1)
+ return &AdminServiceServer_ListTaskIds{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListTaskIdsMatch(matchers ...interface{}) *AdminServiceServer_ListTaskIds {
+ c := _m.On("ListTaskIds", matchers...)
+ return &AdminServiceServer_ListTaskIds{Call: c}
+}
+
+// ListTaskIds provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListTaskIds(_a0 context.Context, _a1 *admin.NamedEntityIdentifierListRequest) (*admin.NamedEntityIdentifierList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NamedEntityIdentifierList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NamedEntityIdentifierListRequest) *admin.NamedEntityIdentifierList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NamedEntityIdentifierList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NamedEntityIdentifierListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListTasks struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListTasks) Return(_a0 *admin.TaskList, _a1 error) *AdminServiceServer_ListTasks {
+ return &AdminServiceServer_ListTasks{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListTasks(_a0 context.Context, _a1 *admin.ResourceListRequest) *AdminServiceServer_ListTasks {
+ c := _m.On("ListTasks", _a0, _a1)
+ return &AdminServiceServer_ListTasks{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListTasksMatch(matchers ...interface{}) *AdminServiceServer_ListTasks {
+ c := _m.On("ListTasks", matchers...)
+ return &AdminServiceServer_ListTasks{Call: c}
+}
+
+// ListTasks provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListTasks(_a0 context.Context, _a1 *admin.ResourceListRequest) (*admin.TaskList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.TaskList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ResourceListRequest) *admin.TaskList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.TaskList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ResourceListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListWorkflowIds struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListWorkflowIds) Return(_a0 *admin.NamedEntityIdentifierList, _a1 error) *AdminServiceServer_ListWorkflowIds {
+ return &AdminServiceServer_ListWorkflowIds{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListWorkflowIds(_a0 context.Context, _a1 *admin.NamedEntityIdentifierListRequest) *AdminServiceServer_ListWorkflowIds {
+ c := _m.On("ListWorkflowIds", _a0, _a1)
+ return &AdminServiceServer_ListWorkflowIds{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListWorkflowIdsMatch(matchers ...interface{}) *AdminServiceServer_ListWorkflowIds {
+ c := _m.On("ListWorkflowIds", matchers...)
+ return &AdminServiceServer_ListWorkflowIds{Call: c}
+}
+
+// ListWorkflowIds provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListWorkflowIds(_a0 context.Context, _a1 *admin.NamedEntityIdentifierListRequest) (*admin.NamedEntityIdentifierList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NamedEntityIdentifierList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NamedEntityIdentifierListRequest) *admin.NamedEntityIdentifierList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NamedEntityIdentifierList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NamedEntityIdentifierListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_ListWorkflows struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_ListWorkflows) Return(_a0 *admin.WorkflowList, _a1 error) *AdminServiceServer_ListWorkflows {
+ return &AdminServiceServer_ListWorkflows{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnListWorkflows(_a0 context.Context, _a1 *admin.ResourceListRequest) *AdminServiceServer_ListWorkflows {
+ c := _m.On("ListWorkflows", _a0, _a1)
+ return &AdminServiceServer_ListWorkflows{Call: c}
+}
+
+func (_m *AdminServiceServer) OnListWorkflowsMatch(matchers ...interface{}) *AdminServiceServer_ListWorkflows {
+ c := _m.On("ListWorkflows", matchers...)
+ return &AdminServiceServer_ListWorkflows{Call: c}
+}
+
+// ListWorkflows provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) ListWorkflows(_a0 context.Context, _a1 *admin.ResourceListRequest) (*admin.WorkflowList, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.WorkflowList
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ResourceListRequest) *admin.WorkflowList); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.WorkflowList)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ResourceListRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_RegisterProject struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_RegisterProject) Return(_a0 *admin.ProjectRegisterResponse, _a1 error) *AdminServiceServer_RegisterProject {
+ return &AdminServiceServer_RegisterProject{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnRegisterProject(_a0 context.Context, _a1 *admin.ProjectRegisterRequest) *AdminServiceServer_RegisterProject {
+ c := _m.On("RegisterProject", _a0, _a1)
+ return &AdminServiceServer_RegisterProject{Call: c}
+}
+
+func (_m *AdminServiceServer) OnRegisterProjectMatch(matchers ...interface{}) *AdminServiceServer_RegisterProject {
+ c := _m.On("RegisterProject", matchers...)
+ return &AdminServiceServer_RegisterProject{Call: c}
+}
+
+// RegisterProject provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) RegisterProject(_a0 context.Context, _a1 *admin.ProjectRegisterRequest) (*admin.ProjectRegisterResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ProjectRegisterResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ProjectRegisterRequest) *admin.ProjectRegisterResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ProjectRegisterResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ProjectRegisterRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_RelaunchExecution struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_RelaunchExecution) Return(_a0 *admin.ExecutionCreateResponse, _a1 error) *AdminServiceServer_RelaunchExecution {
+ return &AdminServiceServer_RelaunchExecution{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnRelaunchExecution(_a0 context.Context, _a1 *admin.ExecutionRelaunchRequest) *AdminServiceServer_RelaunchExecution {
+ c := _m.On("RelaunchExecution", _a0, _a1)
+ return &AdminServiceServer_RelaunchExecution{Call: c}
+}
+
+func (_m *AdminServiceServer) OnRelaunchExecutionMatch(matchers ...interface{}) *AdminServiceServer_RelaunchExecution {
+ c := _m.On("RelaunchExecution", matchers...)
+ return &AdminServiceServer_RelaunchExecution{Call: c}
+}
+
+// RelaunchExecution provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) RelaunchExecution(_a0 context.Context, _a1 *admin.ExecutionRelaunchRequest) (*admin.ExecutionCreateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ExecutionCreateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ExecutionRelaunchRequest) *admin.ExecutionCreateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ExecutionCreateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ExecutionRelaunchRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_TerminateExecution struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_TerminateExecution) Return(_a0 *admin.ExecutionTerminateResponse, _a1 error) *AdminServiceServer_TerminateExecution {
+ return &AdminServiceServer_TerminateExecution{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnTerminateExecution(_a0 context.Context, _a1 *admin.ExecutionTerminateRequest) *AdminServiceServer_TerminateExecution {
+ c := _m.On("TerminateExecution", _a0, _a1)
+ return &AdminServiceServer_TerminateExecution{Call: c}
+}
+
+func (_m *AdminServiceServer) OnTerminateExecutionMatch(matchers ...interface{}) *AdminServiceServer_TerminateExecution {
+ c := _m.On("TerminateExecution", matchers...)
+ return &AdminServiceServer_TerminateExecution{Call: c}
+}
+
+// TerminateExecution provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) TerminateExecution(_a0 context.Context, _a1 *admin.ExecutionTerminateRequest) (*admin.ExecutionTerminateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ExecutionTerminateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ExecutionTerminateRequest) *admin.ExecutionTerminateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ExecutionTerminateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ExecutionTerminateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_UpdateLaunchPlan struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_UpdateLaunchPlan) Return(_a0 *admin.LaunchPlanUpdateResponse, _a1 error) *AdminServiceServer_UpdateLaunchPlan {
+ return &AdminServiceServer_UpdateLaunchPlan{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnUpdateLaunchPlan(_a0 context.Context, _a1 *admin.LaunchPlanUpdateRequest) *AdminServiceServer_UpdateLaunchPlan {
+ c := _m.On("UpdateLaunchPlan", _a0, _a1)
+ return &AdminServiceServer_UpdateLaunchPlan{Call: c}
+}
+
+func (_m *AdminServiceServer) OnUpdateLaunchPlanMatch(matchers ...interface{}) *AdminServiceServer_UpdateLaunchPlan {
+ c := _m.On("UpdateLaunchPlan", matchers...)
+ return &AdminServiceServer_UpdateLaunchPlan{Call: c}
+}
+
+// UpdateLaunchPlan provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) UpdateLaunchPlan(_a0 context.Context, _a1 *admin.LaunchPlanUpdateRequest) (*admin.LaunchPlanUpdateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.LaunchPlanUpdateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.LaunchPlanUpdateRequest) *admin.LaunchPlanUpdateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.LaunchPlanUpdateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.LaunchPlanUpdateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_UpdateNamedEntity struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_UpdateNamedEntity) Return(_a0 *admin.NamedEntityUpdateResponse, _a1 error) *AdminServiceServer_UpdateNamedEntity {
+ return &AdminServiceServer_UpdateNamedEntity{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnUpdateNamedEntity(_a0 context.Context, _a1 *admin.NamedEntityUpdateRequest) *AdminServiceServer_UpdateNamedEntity {
+ c := _m.On("UpdateNamedEntity", _a0, _a1)
+ return &AdminServiceServer_UpdateNamedEntity{Call: c}
+}
+
+func (_m *AdminServiceServer) OnUpdateNamedEntityMatch(matchers ...interface{}) *AdminServiceServer_UpdateNamedEntity {
+ c := _m.On("UpdateNamedEntity", matchers...)
+ return &AdminServiceServer_UpdateNamedEntity{Call: c}
+}
+
+// UpdateNamedEntity provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) UpdateNamedEntity(_a0 context.Context, _a1 *admin.NamedEntityUpdateRequest) (*admin.NamedEntityUpdateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.NamedEntityUpdateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.NamedEntityUpdateRequest) *admin.NamedEntityUpdateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.NamedEntityUpdateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.NamedEntityUpdateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_UpdateProject struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_UpdateProject) Return(_a0 *admin.ProjectUpdateResponse, _a1 error) *AdminServiceServer_UpdateProject {
+ return &AdminServiceServer_UpdateProject{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnUpdateProject(_a0 context.Context, _a1 *admin.Project) *AdminServiceServer_UpdateProject {
+ c := _m.On("UpdateProject", _a0, _a1)
+ return &AdminServiceServer_UpdateProject{Call: c}
+}
+
+func (_m *AdminServiceServer) OnUpdateProjectMatch(matchers ...interface{}) *AdminServiceServer_UpdateProject {
+ c := _m.On("UpdateProject", matchers...)
+ return &AdminServiceServer_UpdateProject{Call: c}
+}
+
+// UpdateProject provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) UpdateProject(_a0 context.Context, _a1 *admin.Project) (*admin.ProjectUpdateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ProjectUpdateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.Project) *admin.ProjectUpdateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ProjectUpdateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.Project) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_UpdateProjectDomainAttributes struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_UpdateProjectDomainAttributes) Return(_a0 *admin.ProjectDomainAttributesUpdateResponse, _a1 error) *AdminServiceServer_UpdateProjectDomainAttributes {
+ return &AdminServiceServer_UpdateProjectDomainAttributes{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnUpdateProjectDomainAttributes(_a0 context.Context, _a1 *admin.ProjectDomainAttributesUpdateRequest) *AdminServiceServer_UpdateProjectDomainAttributes {
+ c := _m.On("UpdateProjectDomainAttributes", _a0, _a1)
+ return &AdminServiceServer_UpdateProjectDomainAttributes{Call: c}
+}
+
+func (_m *AdminServiceServer) OnUpdateProjectDomainAttributesMatch(matchers ...interface{}) *AdminServiceServer_UpdateProjectDomainAttributes {
+ c := _m.On("UpdateProjectDomainAttributes", matchers...)
+ return &AdminServiceServer_UpdateProjectDomainAttributes{Call: c}
+}
+
+// UpdateProjectDomainAttributes provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) UpdateProjectDomainAttributes(_a0 context.Context, _a1 *admin.ProjectDomainAttributesUpdateRequest) (*admin.ProjectDomainAttributesUpdateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.ProjectDomainAttributesUpdateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.ProjectDomainAttributesUpdateRequest) *admin.ProjectDomainAttributesUpdateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.ProjectDomainAttributesUpdateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.ProjectDomainAttributesUpdateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AdminServiceServer_UpdateWorkflowAttributes struct {
+ *mock.Call
+}
+
+func (_m AdminServiceServer_UpdateWorkflowAttributes) Return(_a0 *admin.WorkflowAttributesUpdateResponse, _a1 error) *AdminServiceServer_UpdateWorkflowAttributes {
+ return &AdminServiceServer_UpdateWorkflowAttributes{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AdminServiceServer) OnUpdateWorkflowAttributes(_a0 context.Context, _a1 *admin.WorkflowAttributesUpdateRequest) *AdminServiceServer_UpdateWorkflowAttributes {
+ c := _m.On("UpdateWorkflowAttributes", _a0, _a1)
+ return &AdminServiceServer_UpdateWorkflowAttributes{Call: c}
+}
+
+func (_m *AdminServiceServer) OnUpdateWorkflowAttributesMatch(matchers ...interface{}) *AdminServiceServer_UpdateWorkflowAttributes {
+ c := _m.On("UpdateWorkflowAttributes", matchers...)
+ return &AdminServiceServer_UpdateWorkflowAttributes{Call: c}
+}
+
+// UpdateWorkflowAttributes provides a mock function with given fields: _a0, _a1
+func (_m *AdminServiceServer) UpdateWorkflowAttributes(_a0 context.Context, _a1 *admin.WorkflowAttributesUpdateRequest) (*admin.WorkflowAttributesUpdateResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *admin.WorkflowAttributesUpdateResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *admin.WorkflowAttributesUpdateRequest) *admin.WorkflowAttributesUpdateResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*admin.WorkflowAttributesUpdateResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *admin.WorkflowAttributesUpdateRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
diff --git a/flyteidl/clients/go/admin/mocks/AuthMetadataServiceClient.go b/flyteidl/clients/go/admin/mocks/AuthMetadataServiceClient.go
new file mode 100644
index 0000000000..ecb6b6485c
--- /dev/null
+++ b/flyteidl/clients/go/admin/mocks/AuthMetadataServiceClient.go
@@ -0,0 +1,114 @@
+// Code generated by mockery v1.0.1. DO NOT EDIT.
+
+package mocks
+
+import (
+ context "context"
+
+ grpc "google.golang.org/grpc"
+
+ mock "github.com/stretchr/testify/mock"
+
+ service "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+)
+
+// AuthMetadataServiceClient is an autogenerated mock type for the AuthMetadataServiceClient type
+type AuthMetadataServiceClient struct {
+ mock.Mock
+}
+
+type AuthMetadataServiceClient_GetOAuth2Metadata struct {
+ *mock.Call
+}
+
+func (_m AuthMetadataServiceClient_GetOAuth2Metadata) Return(_a0 *service.OAuth2MetadataResponse, _a1 error) *AuthMetadataServiceClient_GetOAuth2Metadata {
+ return &AuthMetadataServiceClient_GetOAuth2Metadata{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AuthMetadataServiceClient) OnGetOAuth2Metadata(ctx context.Context, in *service.OAuth2MetadataRequest, opts ...grpc.CallOption) *AuthMetadataServiceClient_GetOAuth2Metadata {
+ c := _m.On("GetOAuth2Metadata", ctx, in, opts)
+ return &AuthMetadataServiceClient_GetOAuth2Metadata{Call: c}
+}
+
+func (_m *AuthMetadataServiceClient) OnGetOAuth2MetadataMatch(matchers ...interface{}) *AuthMetadataServiceClient_GetOAuth2Metadata {
+ c := _m.On("GetOAuth2Metadata", matchers...)
+ return &AuthMetadataServiceClient_GetOAuth2Metadata{Call: c}
+}
+
+// GetOAuth2Metadata provides a mock function with given fields: ctx, in, opts
+func (_m *AuthMetadataServiceClient) GetOAuth2Metadata(ctx context.Context, in *service.OAuth2MetadataRequest, opts ...grpc.CallOption) (*service.OAuth2MetadataResponse, error) {
+ _va := make([]interface{}, len(opts))
+ for _i := range opts {
+ _va[_i] = opts[_i]
+ }
+ var _ca []interface{}
+ _ca = append(_ca, ctx, in)
+ _ca = append(_ca, _va...)
+ ret := _m.Called(_ca...)
+
+ var r0 *service.OAuth2MetadataResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *service.OAuth2MetadataRequest, ...grpc.CallOption) *service.OAuth2MetadataResponse); ok {
+ r0 = rf(ctx, in, opts...)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*service.OAuth2MetadataResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *service.OAuth2MetadataRequest, ...grpc.CallOption) error); ok {
+ r1 = rf(ctx, in, opts...)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AuthMetadataServiceClient_GetPublicClientConfig struct {
+ *mock.Call
+}
+
+func (_m AuthMetadataServiceClient_GetPublicClientConfig) Return(_a0 *service.PublicClientAuthConfigResponse, _a1 error) *AuthMetadataServiceClient_GetPublicClientConfig {
+ return &AuthMetadataServiceClient_GetPublicClientConfig{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AuthMetadataServiceClient) OnGetPublicClientConfig(ctx context.Context, in *service.PublicClientAuthConfigRequest, opts ...grpc.CallOption) *AuthMetadataServiceClient_GetPublicClientConfig {
+ c := _m.On("GetPublicClientConfig", ctx, in, opts)
+ return &AuthMetadataServiceClient_GetPublicClientConfig{Call: c}
+}
+
+func (_m *AuthMetadataServiceClient) OnGetPublicClientConfigMatch(matchers ...interface{}) *AuthMetadataServiceClient_GetPublicClientConfig {
+ c := _m.On("GetPublicClientConfig", matchers...)
+ return &AuthMetadataServiceClient_GetPublicClientConfig{Call: c}
+}
+
+// GetPublicClientConfig provides a mock function with given fields: ctx, in, opts
+func (_m *AuthMetadataServiceClient) GetPublicClientConfig(ctx context.Context, in *service.PublicClientAuthConfigRequest, opts ...grpc.CallOption) (*service.PublicClientAuthConfigResponse, error) {
+ _va := make([]interface{}, len(opts))
+ for _i := range opts {
+ _va[_i] = opts[_i]
+ }
+ var _ca []interface{}
+ _ca = append(_ca, ctx, in)
+ _ca = append(_ca, _va...)
+ ret := _m.Called(_ca...)
+
+ var r0 *service.PublicClientAuthConfigResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *service.PublicClientAuthConfigRequest, ...grpc.CallOption) *service.PublicClientAuthConfigResponse); ok {
+ r0 = rf(ctx, in, opts...)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*service.PublicClientAuthConfigResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *service.PublicClientAuthConfigRequest, ...grpc.CallOption) error); ok {
+ r1 = rf(ctx, in, opts...)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
diff --git a/flyteidl/clients/go/admin/mocks/AuthMetadataServiceServer.go b/flyteidl/clients/go/admin/mocks/AuthMetadataServiceServer.go
new file mode 100644
index 0000000000..8816beea23
--- /dev/null
+++ b/flyteidl/clients/go/admin/mocks/AuthMetadataServiceServer.go
@@ -0,0 +1,97 @@
+// Code generated by mockery v1.0.1. DO NOT EDIT.
+
+package mocks
+
+import (
+ context "context"
+
+ service "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+ mock "github.com/stretchr/testify/mock"
+)
+
+// AuthMetadataServiceServer is an autogenerated mock type for the AuthMetadataServiceServer type
+type AuthMetadataServiceServer struct {
+ mock.Mock
+}
+
+type AuthMetadataServiceServer_GetOAuth2Metadata struct {
+ *mock.Call
+}
+
+func (_m AuthMetadataServiceServer_GetOAuth2Metadata) Return(_a0 *service.OAuth2MetadataResponse, _a1 error) *AuthMetadataServiceServer_GetOAuth2Metadata {
+ return &AuthMetadataServiceServer_GetOAuth2Metadata{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AuthMetadataServiceServer) OnGetOAuth2Metadata(_a0 context.Context, _a1 *service.OAuth2MetadataRequest) *AuthMetadataServiceServer_GetOAuth2Metadata {
+ c := _m.On("GetOAuth2Metadata", _a0, _a1)
+ return &AuthMetadataServiceServer_GetOAuth2Metadata{Call: c}
+}
+
+func (_m *AuthMetadataServiceServer) OnGetOAuth2MetadataMatch(matchers ...interface{}) *AuthMetadataServiceServer_GetOAuth2Metadata {
+ c := _m.On("GetOAuth2Metadata", matchers...)
+ return &AuthMetadataServiceServer_GetOAuth2Metadata{Call: c}
+}
+
+// GetOAuth2Metadata provides a mock function with given fields: _a0, _a1
+func (_m *AuthMetadataServiceServer) GetOAuth2Metadata(_a0 context.Context, _a1 *service.OAuth2MetadataRequest) (*service.OAuth2MetadataResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *service.OAuth2MetadataResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *service.OAuth2MetadataRequest) *service.OAuth2MetadataResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*service.OAuth2MetadataResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *service.OAuth2MetadataRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type AuthMetadataServiceServer_GetPublicClientConfig struct {
+ *mock.Call
+}
+
+func (_m AuthMetadataServiceServer_GetPublicClientConfig) Return(_a0 *service.PublicClientAuthConfigResponse, _a1 error) *AuthMetadataServiceServer_GetPublicClientConfig {
+ return &AuthMetadataServiceServer_GetPublicClientConfig{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *AuthMetadataServiceServer) OnGetPublicClientConfig(_a0 context.Context, _a1 *service.PublicClientAuthConfigRequest) *AuthMetadataServiceServer_GetPublicClientConfig {
+ c := _m.On("GetPublicClientConfig", _a0, _a1)
+ return &AuthMetadataServiceServer_GetPublicClientConfig{Call: c}
+}
+
+func (_m *AuthMetadataServiceServer) OnGetPublicClientConfigMatch(matchers ...interface{}) *AuthMetadataServiceServer_GetPublicClientConfig {
+ c := _m.On("GetPublicClientConfig", matchers...)
+ return &AuthMetadataServiceServer_GetPublicClientConfig{Call: c}
+}
+
+// GetPublicClientConfig provides a mock function with given fields: _a0, _a1
+func (_m *AuthMetadataServiceServer) GetPublicClientConfig(_a0 context.Context, _a1 *service.PublicClientAuthConfigRequest) (*service.PublicClientAuthConfigResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *service.PublicClientAuthConfigResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *service.PublicClientAuthConfigRequest) *service.PublicClientAuthConfigResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*service.PublicClientAuthConfigResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *service.PublicClientAuthConfigRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
diff --git a/flyteidl/clients/go/admin/mocks/IdentityServiceClient.go b/flyteidl/clients/go/admin/mocks/IdentityServiceClient.go
new file mode 100644
index 0000000000..9d701adc88
--- /dev/null
+++ b/flyteidl/clients/go/admin/mocks/IdentityServiceClient.go
@@ -0,0 +1,66 @@
+// Code generated by mockery v1.0.1. DO NOT EDIT.
+
+package mocks
+
+import (
+ context "context"
+
+ grpc "google.golang.org/grpc"
+
+ mock "github.com/stretchr/testify/mock"
+
+ service "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+)
+
+// IdentityServiceClient is an autogenerated mock type for the IdentityServiceClient type
+type IdentityServiceClient struct {
+ mock.Mock
+}
+
+type IdentityServiceClient_UserInfo struct {
+ *mock.Call
+}
+
+func (_m IdentityServiceClient_UserInfo) Return(_a0 *service.UserInfoResponse, _a1 error) *IdentityServiceClient_UserInfo {
+ return &IdentityServiceClient_UserInfo{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *IdentityServiceClient) OnUserInfo(ctx context.Context, in *service.UserInfoRequest, opts ...grpc.CallOption) *IdentityServiceClient_UserInfo {
+ c := _m.On("UserInfo", ctx, in, opts)
+ return &IdentityServiceClient_UserInfo{Call: c}
+}
+
+func (_m *IdentityServiceClient) OnUserInfoMatch(matchers ...interface{}) *IdentityServiceClient_UserInfo {
+ c := _m.On("UserInfo", matchers...)
+ return &IdentityServiceClient_UserInfo{Call: c}
+}
+
+// UserInfo provides a mock function with given fields: ctx, in, opts
+func (_m *IdentityServiceClient) UserInfo(ctx context.Context, in *service.UserInfoRequest, opts ...grpc.CallOption) (*service.UserInfoResponse, error) {
+ _va := make([]interface{}, len(opts))
+ for _i := range opts {
+ _va[_i] = opts[_i]
+ }
+ var _ca []interface{}
+ _ca = append(_ca, ctx, in)
+ _ca = append(_ca, _va...)
+ ret := _m.Called(_ca...)
+
+ var r0 *service.UserInfoResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *service.UserInfoRequest, ...grpc.CallOption) *service.UserInfoResponse); ok {
+ r0 = rf(ctx, in, opts...)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*service.UserInfoResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *service.UserInfoRequest, ...grpc.CallOption) error); ok {
+ r1 = rf(ctx, in, opts...)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
diff --git a/flyteidl/clients/go/admin/mocks/IdentityServiceServer.go b/flyteidl/clients/go/admin/mocks/IdentityServiceServer.go
new file mode 100644
index 0000000000..3a014ea32d
--- /dev/null
+++ b/flyteidl/clients/go/admin/mocks/IdentityServiceServer.go
@@ -0,0 +1,56 @@
+// Code generated by mockery v1.0.1. DO NOT EDIT.
+
+package mocks
+
+import (
+ context "context"
+
+ service "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+ mock "github.com/stretchr/testify/mock"
+)
+
+// IdentityServiceServer is an autogenerated mock type for the IdentityServiceServer type
+type IdentityServiceServer struct {
+ mock.Mock
+}
+
+type IdentityServiceServer_UserInfo struct {
+ *mock.Call
+}
+
+func (_m IdentityServiceServer_UserInfo) Return(_a0 *service.UserInfoResponse, _a1 error) *IdentityServiceServer_UserInfo {
+ return &IdentityServiceServer_UserInfo{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *IdentityServiceServer) OnUserInfo(_a0 context.Context, _a1 *service.UserInfoRequest) *IdentityServiceServer_UserInfo {
+ c := _m.On("UserInfo", _a0, _a1)
+ return &IdentityServiceServer_UserInfo{Call: c}
+}
+
+func (_m *IdentityServiceServer) OnUserInfoMatch(matchers ...interface{}) *IdentityServiceServer_UserInfo {
+ c := _m.On("UserInfo", matchers...)
+ return &IdentityServiceServer_UserInfo{Call: c}
+}
+
+// UserInfo provides a mock function with given fields: _a0, _a1
+func (_m *IdentityServiceServer) UserInfo(_a0 context.Context, _a1 *service.UserInfoRequest) (*service.UserInfoResponse, error) {
+ ret := _m.Called(_a0, _a1)
+
+ var r0 *service.UserInfoResponse
+ if rf, ok := ret.Get(0).(func(context.Context, *service.UserInfoRequest) *service.UserInfoResponse); ok {
+ r0 = rf(_a0, _a1)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*service.UserInfoResponse)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func(context.Context, *service.UserInfoRequest) error); ok {
+ r1 = rf(_a0, _a1)
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
diff --git a/flyteidl/clients/go/admin/pkce/auth_flow_orchestrator.go b/flyteidl/clients/go/admin/pkce/auth_flow_orchestrator.go
new file mode 100644
index 0000000000..1d3414aefc
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/auth_flow_orchestrator.go
@@ -0,0 +1,164 @@
+package pkce
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+ "net/url"
+ "time"
+
+ "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+ "github.com/flyteorg/flytestdlib/logger"
+
+ "github.com/pkg/browser"
+ "golang.org/x/oauth2"
+)
+
+// TokenOrchestrator implements the main logic to initiate Pkce flow to issue access token and refresh token as well as
+// refreshing the access token if a refresh token is present.
+type TokenOrchestrator struct {
+ cfg Config
+ clientConfig *oauth2.Config
+ tokenCache TokenCache
+}
+
+// RefreshToken attempts to refresh the access token if a refresh token is provided.
+func (f TokenOrchestrator) RefreshToken(ctx context.Context, token *oauth2.Token) (*oauth2.Token, error) {
+ ts := f.clientConfig.TokenSource(ctx, token)
+ var refreshedToken *oauth2.Token
+ var err error
+ refreshedToken, err = ts.Token()
+ if err != nil {
+ logger.Warnf(ctx, "failed to refresh the token due to %v and will be doing re-auth", err)
+ return nil, err
+ }
+
+ if refreshedToken != nil {
+ logger.Debugf(ctx, "got a response from the refresh grant for old expiry %v with new expiry %v",
+ token.Expiry, refreshedToken.Expiry)
+ if refreshedToken.AccessToken != token.AccessToken {
+ if err = f.tokenCache.SaveToken(refreshedToken); err != nil {
+ logger.Errorf(ctx, "unable to save the new token due to %v", err)
+ return nil, err
+ }
+ }
+ }
+
+ return refreshedToken, nil
+}
+
+// FetchTokenFromCacheOrRefreshIt fetches the token from cache and refreshes it if it'll expire within the
+// Config.TokenRefreshGracePeriod period.
+func (f TokenOrchestrator) FetchTokenFromCacheOrRefreshIt(ctx context.Context) (token *oauth2.Token, err error) {
+ token, err = f.tokenCache.GetToken()
+ if err != nil {
+ return nil, err
+ }
+
+ if !token.Valid() {
+ return nil, fmt.Errorf("token from cache is invalid")
+ }
+
+ // If token doesn't need to be refreshed, return it.
+ if token.Expiry.Add(f.cfg.TokenRefreshGracePeriod.Duration).Before(time.Now()) {
+ return token, nil
+ }
+
+ token, err = f.RefreshToken(ctx, token)
+ if err != nil {
+ return nil, fmt.Errorf("failed to refresh token using cached token. Error: %w", err)
+ }
+
+ if !token.Valid() {
+ return nil, fmt.Errorf("refreshed token is invalid")
+ }
+
+ err = f.tokenCache.SaveToken(token)
+ if err != nil {
+ return nil, fmt.Errorf("failed to save token in the token cache. Error: %w", err)
+ }
+
+ return token, nil
+}
+
+// FetchTokenFromAuthFlow starts a webserver to listen to redirect callback from the authorization server at the end
+// of the flow. It then launches the browser to authenticate the user.
+func (f TokenOrchestrator) FetchTokenFromAuthFlow(ctx context.Context) (*oauth2.Token, error) {
+ var err error
+ var redirectURL *url.URL
+ if redirectURL, err = url.Parse(f.clientConfig.RedirectURL); err != nil {
+ return nil, err
+ }
+
+ // pkceCodeVerifier stores the generated random value which the client will on-send to the auth server with the received
+ // authorization code. This way the oauth server can verify that the base64URLEncoded(sha265(codeVerifier)) matches
+ // the stored code challenge, which was initially sent through with the code+PKCE authorization request to ensure
+ // that this is the original user-agent who requested the access token.
+ pkceCodeVerifier := generateCodeVerifier(64)
+
+ // pkceCodeChallenge stores the base64(sha256(codeVerifier)) which is sent from the
+ // client to the auth server as required for PKCE.
+ pkceCodeChallenge := generateCodeChallenge(pkceCodeVerifier)
+
+ stateString := state(32)
+ nonces := state(32)
+
+ tokenChannel := make(chan *oauth2.Token, 1)
+ errorChannel := make(chan error, 1)
+
+ // Replace S256 with one from cient config and provide a support to generate code challenge using the passed
+ // in method.
+ urlToOpen := f.clientConfig.AuthCodeURL(stateString) + "&nonce=" + nonces + "&code_challenge=" +
+ pkceCodeChallenge + "&code_challenge_method=S256"
+
+ serveMux := http.NewServeMux()
+ server := &http.Server{Addr: redirectURL.Host, Handler: serveMux}
+ // Register the call back handler
+ serveMux.HandleFunc(redirectURL.Path, getAuthServerCallbackHandler(f.clientConfig, pkceCodeVerifier,
+ tokenChannel, errorChannel, stateString)) // the oauth2 callback endpoint
+ defer server.Close()
+
+ go func() {
+ if err = server.ListenAndServe(); err != nil && err != http.ErrServerClosed {
+ logger.Fatal(ctx, "Couldn't start the callback http server on host %v due to %v", redirectURL.Host,
+ err)
+ }
+ }()
+
+ logger.Infof(ctx, "Opening the browser at "+urlToOpen)
+ if err = browser.OpenURL(urlToOpen); err != nil {
+ return nil, err
+ }
+
+ ctx, cancelNow := context.WithTimeout(ctx, f.cfg.BrowserSessionTimeout.Duration)
+ defer cancelNow()
+
+ var token *oauth2.Token
+ select {
+ case err = <-errorChannel:
+ return nil, err
+ case <-ctx.Done():
+ return nil, fmt.Errorf("context was canceled during auth flow")
+ case token = <-tokenChannel:
+ if err = f.tokenCache.SaveToken(token); err != nil {
+ logger.Errorf(ctx, "unable to save the new token due to. Will ignore the error and use the issued token. Error: %v", err)
+ }
+
+ return token, nil
+ }
+}
+
+// NewTokenOrchestrator creates a new TokenOrchestrator that implements the main logic to initiate Pkce flow to issue
+// access token and refresh token as well as refreshing the access token if a refresh token is present.
+func NewTokenOrchestrator(ctx context.Context, cfg Config, tokenCache TokenCache, authMetadataClient service.AuthMetadataServiceClient) (TokenOrchestrator, error) {
+ clientConf, err := BuildClientConfig(ctx, authMetadataClient)
+ if err != nil {
+ return TokenOrchestrator{}, err
+ }
+
+ return TokenOrchestrator{
+ cfg: cfg,
+ clientConfig: clientConf,
+ tokenCache: tokenCache,
+ }, nil
+}
diff --git a/flyteidl/clients/go/admin/pkce/auth_flow_orchestrator_test.go b/flyteidl/clients/go/admin/pkce/auth_flow_orchestrator_test.go
new file mode 100644
index 0000000000..879c68de0f
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/auth_flow_orchestrator_test.go
@@ -0,0 +1,81 @@
+package pkce
+
+import (
+ "context"
+ "encoding/json"
+ "io/ioutil"
+ "testing"
+
+ "github.com/flyteorg/flyteidl/clients/go/admin/mocks"
+ "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+
+ "github.com/stretchr/testify/assert"
+ "github.com/stretchr/testify/mock"
+ "golang.org/x/oauth2"
+)
+
+func TestRefreshTheToken(t *testing.T) {
+ ctx := context.Background()
+ clientConf := &oauth2.Config{
+ ClientID: "dummyClient",
+ }
+ orchestrator := TokenOrchestrator{
+ clientConfig: clientConf,
+ }
+ plan, _ := ioutil.ReadFile("testdata/token.json")
+ var tokenData oauth2.Token
+ err := json.Unmarshal(plan, &tokenData)
+ assert.Nil(t, err)
+ t.Run("bad url in config", func(t *testing.T) {
+ refreshedToken, err := orchestrator.RefreshToken(ctx, &tokenData)
+ assert.Nil(t, refreshedToken)
+ assert.NotNil(t, err)
+ })
+}
+
+func TestFetchFromCache(t *testing.T) {
+ ctx := context.Background()
+ metatdata := &service.OAuth2MetadataResponse{
+ TokenEndpoint: "/token",
+ ScopesSupported: []string{"code", "all"},
+ }
+ clientMetatadata := &service.PublicClientAuthConfigResponse{
+ AuthorizationMetadataKey: "flyte_authorization",
+ RedirectUri: "http://localhost:8089/redirect",
+ }
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(clientMetatadata, nil)
+ orchestrator, err := NewTokenOrchestrator(ctx, Config{}, &TokenCacheInMemoryProvider{}, mockAuthClient)
+ assert.NoError(t, err)
+
+ t.Run("no token in cache", func(t *testing.T) {
+ refreshedToken, err := orchestrator.FetchTokenFromCacheOrRefreshIt(ctx)
+ assert.Nil(t, refreshedToken)
+ assert.NotNil(t, err)
+ })
+}
+
+func TestFetchFromAuthFlow(t *testing.T) {
+ ctx := context.Background()
+ t.Run("fetch from auth flow", func(t *testing.T) {
+ metatdata := &service.OAuth2MetadataResponse{
+ TokenEndpoint: "/token",
+ ScopesSupported: []string{"code", "all"},
+ }
+ clientMetatadata := &service.PublicClientAuthConfigResponse{
+ AuthorizationMetadataKey: "flyte_authorization",
+ RedirectUri: "http://localhost:8089/redirect",
+ }
+
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ mockAuthClient.OnGetOAuth2MetadataMatch(mock.Anything, mock.Anything).Return(metatdata, nil)
+ mockAuthClient.OnGetPublicClientConfigMatch(mock.Anything, mock.Anything).Return(clientMetatadata, nil)
+ tokenCache := &TokenCacheInMemoryProvider{}
+ orchestrator, err := NewTokenOrchestrator(ctx, Config{}, tokenCache, mockAuthClient)
+ assert.NoError(t, err)
+ refreshedToken, err := orchestrator.FetchTokenFromAuthFlow(ctx)
+ assert.Nil(t, refreshedToken)
+ assert.NotNil(t, err)
+ })
+}
diff --git a/flyteidl/clients/go/admin/pkce/client_config.go b/flyteidl/clients/go/admin/pkce/client_config.go
new file mode 100644
index 0000000000..93c76397e1
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/client_config.go
@@ -0,0 +1,34 @@
+package pkce
+
+import (
+ "context"
+
+ "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+
+ "golang.org/x/oauth2"
+)
+
+// BuildClientConfig builds OAuth2 config from information retrieved through the anonymous auth metadata service.
+func BuildClientConfig(ctx context.Context, authMetadataClient service.AuthMetadataServiceClient) (clientConf *oauth2.Config, err error) {
+ var clientResp *service.PublicClientAuthConfigResponse
+ if clientResp, err = authMetadataClient.GetPublicClientConfig(ctx, &service.PublicClientAuthConfigRequest{}); err != nil {
+ return nil, err
+ }
+
+ var oauthMetaResp *service.OAuth2MetadataResponse
+ if oauthMetaResp, err = authMetadataClient.GetOAuth2Metadata(ctx, &service.OAuth2MetadataRequest{}); err != nil {
+ return nil, err
+ }
+
+ clientConf = &oauth2.Config{
+ ClientID: clientResp.ClientId,
+ RedirectURL: clientResp.RedirectUri,
+ Scopes: clientResp.Scopes,
+ Endpoint: oauth2.Endpoint{
+ TokenURL: oauthMetaResp.TokenEndpoint,
+ AuthURL: oauthMetaResp.AuthorizationEndpoint,
+ },
+ }
+
+ return clientConf, nil
+}
diff --git a/flyteidl/clients/go/admin/pkce/client_config_test.go b/flyteidl/clients/go/admin/pkce/client_config_test.go
new file mode 100644
index 0000000000..500233b2bc
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/client_config_test.go
@@ -0,0 +1,37 @@
+package pkce
+
+import (
+ "context"
+ "testing"
+
+ "github.com/flyteorg/flyteidl/clients/go/admin/mocks"
+ "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/service"
+
+ "github.com/stretchr/testify/assert"
+ "github.com/stretchr/testify/mock"
+)
+
+func TestGenerateClientConfig(t *testing.T) {
+ ctx := context.Background()
+ mockAuthClient := new(mocks.AuthMetadataServiceClient)
+ flyteClientResp := &service.PublicClientAuthConfigResponse{
+ ClientId: "dummyClient",
+ RedirectUri: "dummyRedirectUri",
+ Scopes: []string{"dummyScopes"},
+ }
+ oauthMetaDataResp := &service.OAuth2MetadataResponse{
+ Issuer: "dummyIssuer",
+ AuthorizationEndpoint: "dummyAuthEndPoint",
+ TokenEndpoint: "dummyTokenEndpoint",
+ CodeChallengeMethodsSupported: []string{"dummyCodeChallenege"},
+ }
+ mockAuthClient.OnGetPublicClientConfigMatch(ctx, mock.Anything).Return(flyteClientResp, nil)
+ mockAuthClient.OnGetOAuth2MetadataMatch(ctx, mock.Anything).Return(oauthMetaDataResp, nil)
+ oauthConfig, err := BuildClientConfig(ctx, mockAuthClient)
+ assert.Nil(t, err)
+ assert.NotNil(t, oauthConfig)
+ assert.Equal(t, "dummyClient", oauthConfig.ClientID)
+ assert.Equal(t, "dummyRedirectUri", oauthConfig.RedirectURL)
+ assert.Equal(t, "dummyTokenEndpoint", oauthConfig.Endpoint.TokenURL)
+ assert.Equal(t, "dummyAuthEndPoint", oauthConfig.Endpoint.AuthURL)
+}
diff --git a/flyteidl/clients/go/admin/pkce/config.go b/flyteidl/clients/go/admin/pkce/config.go
new file mode 100644
index 0000000000..ff56dcf62c
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/config.go
@@ -0,0 +1,9 @@
+package pkce
+
+import "github.com/flyteorg/flytestdlib/config"
+
+// Config defines settings used for PKCE flow.
+type Config struct {
+ BrowserSessionTimeout config.Duration `json:"timeout"`
+ TokenRefreshGracePeriod config.Duration `json:"refreshTime"`
+}
diff --git a/flyteidl/clients/go/admin/pkce/handle_app_call_back.go b/flyteidl/clients/go/admin/pkce/handle_app_call_back.go
new file mode 100644
index 0000000000..022cce6d1b
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/handle_app_call_back.go
@@ -0,0 +1,53 @@
+package pkce
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+
+ "golang.org/x/oauth2"
+)
+
+func getAuthServerCallbackHandler(c *oauth2.Config, codeVerifier string, tokenChannel chan *oauth2.Token,
+ errorChannel chan error, stateString string) func(rw http.ResponseWriter, req *http.Request) {
+
+ return func(rw http.ResponseWriter, req *http.Request) {
+ _, _ = rw.Write([]byte(`
Flyte Authentication
`))
+ rw.Header().Set("Content-Type", "text/html; charset=utf-8")
+ if req.URL.Query().Get("error") != "" {
+ errorChannel <- fmt.Errorf("error on callback during authorization due to %v", req.URL.Query().Get("error"))
+ _, _ = rw.Write([]byte(fmt.Sprintf(`Error!
+ Error: %s
+ Error Hint: %s
+ Description: %s
+
`,
+ req.URL.Query().Get("error"),
+ req.URL.Query().Get("error_hint"),
+ req.URL.Query().Get("error_description"),
+ )))
+ return
+ }
+ if req.URL.Query().Get("code") == "" {
+ errorChannel <- fmt.Errorf("could not find the authorize code")
+ _, _ = rw.Write([]byte(fmt.Sprintln(`Could not find the authorize code.
`)))
+ return
+ }
+ if req.URL.Query().Get("state") != stateString {
+ errorChannel <- fmt.Errorf("possibly a csrf attack")
+ _, _ = rw.Write([]byte(fmt.Sprintln(`Sorry we can't serve your request'.
`)))
+ return
+ }
+ // We'll check whether we sent a code+PKCE request, and if so, send the code_verifier along when requesting the access token.
+ var opts []oauth2.AuthCodeOption
+ opts = append(opts, oauth2.SetAuthURLParam("code_verifier", codeVerifier))
+
+ token, err := c.Exchange(context.Background(), req.URL.Query().Get("code"), opts...)
+ if err != nil {
+ errorChannel <- fmt.Errorf("error while exchanging auth code due to %v", err)
+ _, _ = rw.Write([]byte(fmt.Sprintf(`Couldn't get access token due to error: %s
`, err.Error())))
+ return
+ }
+ _, _ = rw.Write([]byte(`Cool! Your authentication was successful and you can close the window.
`))
+ tokenChannel <- token
+ }
+}
diff --git a/flyteidl/clients/go/admin/pkce/handle_app_call_back_test.go b/flyteidl/clients/go/admin/pkce/handle_app_call_back_test.go
new file mode 100644
index 0000000000..fe86fb112f
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/handle_app_call_back_test.go
@@ -0,0 +1,131 @@
+package pkce
+
+import (
+ "errors"
+ "net/http"
+ "net/url"
+ "strings"
+ "testing"
+
+ "github.com/stretchr/testify/assert"
+ testhttp "github.com/stretchr/testify/http"
+ "golang.org/x/oauth2"
+)
+
+var (
+ rw *testhttp.TestResponseWriter
+ req *http.Request
+ callBackFn func(rw http.ResponseWriter, req *http.Request)
+)
+
+func HandleAppCallBackSetup(t *testing.T, state string) (tokenChannel chan *oauth2.Token, errorChannel chan error) {
+ var testAuthConfig *oauth2.Config
+ errorChannel = make(chan error, 1)
+ tokenChannel = make(chan *oauth2.Token)
+ testAuthConfig = &oauth2.Config{}
+ callBackFn = getAuthServerCallbackHandler(testAuthConfig, "", tokenChannel, errorChannel, state)
+ assert.NotNil(t, callBackFn)
+ req = &http.Request{
+ Method: http.MethodGet,
+ URL: &url.URL{
+ Scheme: "http",
+ Host: "dummyHost",
+ Path: "dummyPath",
+ RawQuery: "&error=invalid_request",
+ },
+ }
+ rw = &testhttp.TestResponseWriter{}
+ return
+}
+
+func TestHandleAppCallBackWithErrorInRequest(t *testing.T) {
+ tokenChannel, errorChannel := HandleAppCallBackSetup(t, "")
+ req = &http.Request{
+ Method: http.MethodGet,
+ URL: &url.URL{
+ Scheme: "http",
+ Host: "dummyHost",
+ Path: "dummyPath",
+ RawQuery: "&error=invalid_request",
+ },
+ }
+ callBackFn(rw, req)
+ var errorValue error
+ select {
+ case errorValue = <-errorChannel:
+ assert.NotNil(t, errorValue)
+ assert.True(t, strings.Contains(rw.Output, "invalid_request"))
+ assert.Equal(t, errors.New("error on callback during authorization due to invalid_request"), errorValue)
+ case <-tokenChannel:
+ assert.Fail(t, "received a token for a failed test")
+ }
+}
+
+func TestHandleAppCallBackWithCodeNotFound(t *testing.T) {
+ tokenChannel, errorChannel := HandleAppCallBackSetup(t, "")
+ req = &http.Request{
+ Method: http.MethodGet,
+ URL: &url.URL{
+ Scheme: "http",
+ Host: "dummyHost",
+ Path: "dummyPath",
+ RawQuery: "",
+ },
+ }
+ callBackFn(rw, req)
+ var errorValue error
+ select {
+ case errorValue = <-errorChannel:
+ assert.NotNil(t, errorValue)
+ assert.True(t, strings.Contains(rw.Output, "Could not find the authorize code"))
+ assert.Equal(t, errors.New("could not find the authorize code"), errorValue)
+ case <-tokenChannel:
+ assert.Fail(t, "received a token for a failed test")
+ }
+}
+
+func TestHandleAppCallBackCsrfAttach(t *testing.T) {
+ tokenChannel, errorChannel := HandleAppCallBackSetup(t, "the real state")
+ req = &http.Request{
+ Method: http.MethodGet,
+ URL: &url.URL{
+ Scheme: "http",
+ Host: "dummyHost",
+ Path: "dummyPath",
+ RawQuery: "&code=dummyCode&state=imposterString",
+ },
+ }
+ callBackFn(rw, req)
+ var errorValue error
+ select {
+ case errorValue = <-errorChannel:
+ assert.NotNil(t, errorValue)
+ assert.True(t, strings.Contains(rw.Output, "Sorry we can't serve your request"))
+ assert.Equal(t, errors.New("possibly a csrf attack"), errorValue)
+ case <-tokenChannel:
+ assert.Fail(t, "received a token for a failed test")
+ }
+}
+
+func TestHandleAppCallBackFailedTokenExchange(t *testing.T) {
+ tokenChannel, errorChannel := HandleAppCallBackSetup(t, "realStateString")
+ req = &http.Request{
+ Method: http.MethodGet,
+ URL: &url.URL{
+ Scheme: "http",
+ Host: "dummyHost",
+ Path: "dummyPath",
+ RawQuery: "&code=dummyCode&state=realStateString",
+ },
+ }
+ rw = &testhttp.TestResponseWriter{}
+ callBackFn(rw, req)
+ var errorValue error
+ select {
+ case errorValue = <-errorChannel:
+ assert.NotNil(t, errorValue)
+ assert.True(t, strings.Contains(errorValue.Error(), "error while exchanging auth code due"))
+ case <-tokenChannel:
+ assert.Fail(t, "received a token for a failed test")
+ }
+}
diff --git a/flyteidl/clients/go/admin/pkce/mocks/token_cache.go b/flyteidl/clients/go/admin/pkce/mocks/token_cache.go
new file mode 100644
index 0000000000..ede500d8f1
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/mocks/token_cache.go
@@ -0,0 +1,86 @@
+// Code generated by mockery v1.0.1. DO NOT EDIT.
+
+package mocks
+
+import (
+ mock "github.com/stretchr/testify/mock"
+ oauth2 "golang.org/x/oauth2"
+)
+
+// TokenCache is an autogenerated mock type for the TokenCache type
+type TokenCache struct {
+ mock.Mock
+}
+
+type TokenCache_GetToken struct {
+ *mock.Call
+}
+
+func (_m TokenCache_GetToken) Return(_a0 *oauth2.Token, _a1 error) *TokenCache_GetToken {
+ return &TokenCache_GetToken{Call: _m.Call.Return(_a0, _a1)}
+}
+
+func (_m *TokenCache) OnGetToken() *TokenCache_GetToken {
+ c := _m.On("GetToken")
+ return &TokenCache_GetToken{Call: c}
+}
+
+func (_m *TokenCache) OnGetTokenMatch(matchers ...interface{}) *TokenCache_GetToken {
+ c := _m.On("GetToken", matchers...)
+ return &TokenCache_GetToken{Call: c}
+}
+
+// GetToken provides a mock function with given fields:
+func (_m *TokenCache) GetToken() (*oauth2.Token, error) {
+ ret := _m.Called()
+
+ var r0 *oauth2.Token
+ if rf, ok := ret.Get(0).(func() *oauth2.Token); ok {
+ r0 = rf()
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(*oauth2.Token)
+ }
+ }
+
+ var r1 error
+ if rf, ok := ret.Get(1).(func() error); ok {
+ r1 = rf()
+ } else {
+ r1 = ret.Error(1)
+ }
+
+ return r0, r1
+}
+
+type TokenCache_SaveToken struct {
+ *mock.Call
+}
+
+func (_m TokenCache_SaveToken) Return(_a0 error) *TokenCache_SaveToken {
+ return &TokenCache_SaveToken{Call: _m.Call.Return(_a0)}
+}
+
+func (_m *TokenCache) OnSaveToken(token *oauth2.Token) *TokenCache_SaveToken {
+ c := _m.On("SaveToken", token)
+ return &TokenCache_SaveToken{Call: c}
+}
+
+func (_m *TokenCache) OnSaveTokenMatch(matchers ...interface{}) *TokenCache_SaveToken {
+ c := _m.On("SaveToken", matchers...)
+ return &TokenCache_SaveToken{Call: c}
+}
+
+// SaveToken provides a mock function with given fields: token
+func (_m *TokenCache) SaveToken(token *oauth2.Token) error {
+ ret := _m.Called(token)
+
+ var r0 error
+ if rf, ok := ret.Get(0).(func(*oauth2.Token) error); ok {
+ r0 = rf(token)
+ } else {
+ r0 = ret.Error(0)
+ }
+
+ return r0
+}
diff --git a/flyteidl/clients/go/admin/pkce/oauth2_client.go b/flyteidl/clients/go/admin/pkce/oauth2_client.go
new file mode 100644
index 0000000000..cab56df132
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/oauth2_client.go
@@ -0,0 +1,59 @@
+// Provides the setup required for the client to perform the "Authorization Code" flow with PKCE in order to obtain an
+// access token for public/untrusted clients.
+package pkce
+
+import (
+ "crypto/sha256"
+ "encoding/base64"
+
+ "golang.org/x/oauth2"
+ rand2 "k8s.io/apimachinery/pkg/util/rand"
+)
+
+// The following sets up the requirements for generating a standards compliant PKCE code verifier.
+const codeVerifierLenMin = 43
+const codeVerifierLenMax = 128
+
+// generateCodeVerifier provides an easy way to generate an n-length randomised
+// code verifier.
+func generateCodeVerifier(n int) string {
+ // Enforce standards compliance...
+ if n < codeVerifierLenMin {
+ n = codeVerifierLenMin
+ }
+
+ if n > codeVerifierLenMax {
+ n = codeVerifierLenMax
+ }
+
+ return randomString(n)
+}
+
+func randomString(length int) string {
+ return rand2.String(length)
+}
+
+// generateCodeChallenge returns a standards compliant PKCE S(HA)256 code
+// challenge.
+func generateCodeChallenge(codeVerifier string) string {
+ // Create a sha-265 hash from the code verifier...
+ s256 := sha256.New()
+ _, _ = s256.Write([]byte(codeVerifier))
+ // Then base64 encode the hash sum to create a code challenge...
+ return base64.RawURLEncoding.EncodeToString(s256.Sum(nil))
+}
+
+func state(n int) string {
+ data := randomString(n)
+ return base64.RawURLEncoding.EncodeToString([]byte(data))
+}
+
+// SimpleTokenSource defines a simple token source that caches a token in memory.
+type SimpleTokenSource struct {
+ CachedToken *oauth2.Token
+}
+
+func (ts *SimpleTokenSource) Token() (*oauth2.Token, error) {
+ t := ts.CachedToken
+ return t, nil
+}
diff --git a/flyteidl/clients/go/admin/pkce/testdata/empty_access_token.json b/flyteidl/clients/go/admin/pkce/testdata/empty_access_token.json
new file mode 100644
index 0000000000..474f4762e0
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/testdata/empty_access_token.json
@@ -0,0 +1,6 @@
+{
+ "access_token":"",
+ "token_type":"bearer",
+ "refresh_token":"eyJhbGciOiJSUzI1NiIsImtleV9pZCI6IjlLZlNILXphZjRjY1dmTlNPbm91YmZUbnItVW5kMHVuY3ctWF9KNUJVdWciLCJ0eXAiOiJKV1QifQ.eyJhdWQiOlsiaHR0cHM6Ly9kZW1vLm51Y2x5ZGUuaW8iXSwiY2xpZW50X2lkIjoiZmx5dGVjdGwiLCJleHAiOjE2MTk1MzM1MjcsImZvcm0iOnsiY29kZV9jaGFsbGVuZ2UiOiJ2bWNxazArZnJRS3Vvb2FMUHZwUDJCeUtod2VKR2VaeG1mdGtkMml0T042Tk13SVBQNWwySmNpWDd3NTdlaS9iVW1LTWhPSjJVUERnK0F5RXRaTG94SFJiMDl1cWRKSSIsImNvZGVfY2hhbGxlbmdlX21ldGhvZCI6IlN2WEgyeDh2UDUrSkJxQ0NjT2dCL0hNWjdLSmE3bkdLMDBaUVA0ekd4WGcifSwiaWF0IjoxNjE5NTAyNTM1LCJpc3MiOiJodHRwczovL2RlbW8ubnVjbHlkZS5pbyIsImp0aSI6IjQzMTM1ZWY2LTA5NjEtNGFlZC1hOTYxLWQyZGI1YWJmM2U1YyIsInNjcCI6WyJvZmZsaW5lIiwiZi5hbGwiLCJhY2Nlc3NfdG9rZW4iXSwic3ViIjoiMTE0NTI3ODE1MzA1MTI4OTc0NDcwIiwidXNlcl9pbmZvIjp7ImZhbWlseV9uYW1lIjoiTWFoaW5kcmFrYXIiLCJnaXZlbl9uYW1lIjoiUHJhZnVsbGEiLCJuYW1lIjoiUHJhZnVsbGEgTWFoaW5kcmFrYXIiLCJwaWN0dXJlIjoiaHR0cHM6Ly9saDMuZ29vZ2xldXNlcmNvbnRlbnQuY29tL2EtL0FPaDE0R2p1VDFrOC04YTV2QkdPSUYxYURnaFltRng4aEQ5S05pUjVqblp1PXM5Ni1jIiwic3ViamVjdCI6IjExNDUyNzgxNTMwNTEyODk3NDQ3MCJ9fQ.YKom5-gE4e84rJJIfxcpbMzgjZT33UZ27UTa1y8pK2BAWaPjIZtwudwDHQ5Rd3m0mJJWhBp0j0e8h9DvzBUdpsnGMXSCYKP-ag9y9k5OW59FMm9RqIakWHtj6NPnxGO1jAsaNCYePj8knR7pBLCLCse2taDHUJ8RU1F0DeHNr2y-JupgG5y1vjBcb-9eD8OwOSTp686_hm7XoJlxiKx8dj2O7HPH7M2pAHA_0bVrKKj7Y_s3fRhkm_Aq6LRdA-IiTl9xJQxgVUreejls9-RR9mSTKj6A81-Isz3qAUttVVaA4OT5OdW879_yT7OSLw_QwpXzNZ7qOR7OIpmL_xZXig",
+ "expiry":"2021-04-27T19:55:26.658635+05:30"
+}
\ No newline at end of file
diff --git a/flyteidl/clients/go/admin/pkce/testdata/token.json b/flyteidl/clients/go/admin/pkce/testdata/token.json
new file mode 100644
index 0000000000..721cecc5f6
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/testdata/token.json
@@ -0,0 +1,6 @@
+{
+ "access_token":"eyJhbGciOiJSUzI1NiIsImtleV9pZCI6IjlLZlNILXphZjRjY1dmTlNPbm91YmZUbnItVW5kMHVuY3ctWF9KNUJVdWciLCJ0eXAiOiJKV1QifQ.eyJhdWQiOlsiaHR0cHM6Ly9kZW1vLm51Y2x5ZGUuaW8iXSwiY2xpZW50X2lkIjoiZmx5dGVjdGwiLCJleHAiOjE2MTk1Mjk5MjcsImZvcm0iOnsiY29kZV9jaGFsbGVuZ2UiOiJ2bWNxazArZnJRS3Vvb2FMUHZwUDJCeUtod2VKR2VaeG1mdGtkMml0T042Tk13SVBQNWwySmNpWDd3NTdlaS9iVW1LTWhPSjJVUERnK0F5RXRaTG94SFJiMDl1cWRKSSIsImNvZGVfY2hhbGxlbmdlX21ldGhvZCI6IlN2WEgyeDh2UDUrSkJxQ0NjT2dCL0hNWjdLSmE3bkdLMDBaUVA0ekd4WGcifSwiaWF0IjoxNjE5NTAyNTM1LCJpc3MiOiJodHRwczovL2RlbW8ubnVjbHlkZS5pbyIsImp0aSI6IjQzMTM1ZWY2LTA5NjEtNGFlZC1hOTYxLWQyZGI1YWJmM2U1YyIsInNjcCI6WyJvZmZsaW5lIiwiYWxsIiwiYWNjZXNzX3Rva2VuIl0sInN1YiI6IjExNDUyNzgxNTMwNTEyODk3NDQ3MCIsInVzZXJfaW5mbyI6eyJmYW1pbHlfbmFtZSI6Ik1haGluZHJha2FyIiwiZ2l2ZW5fbmFtZSI6IlByYWZ1bGxhIiwibmFtZSI6IlByYWZ1bGxhIE1haGluZHJha2FyIiwicGljdHVyZSI6Imh0dHBzOi8vbGgzLmdvb2dsZXVzZXJjb250ZW50LmNvbS9hLS9BT2gxNEdqdVQxazgtOGE1dkJHT0lGMWFEZ2hZbUZ4OGhEOUtOaVI1am5adT1zOTYtYyIsInN1YmplY3QiOiIxMTQ1Mjc4MTUzMDUxMjg5NzQ0NzAifX0.ojbUOy2tF6HL8fIp1FJAQchU2MimlVMr3EGVPxMvYyahpW5YsWh6mz7qn4vpEnBuYZDf6cTaN50pJ8krlDX9RqtxF3iEfV2ZYHwyKMThI9sWh_kEBgGwUpyHyk98ZeqQX1uFOH3iwwhR-lPPUlpgdFGzKsxfxeFLOtu1y0V7BgA08KFqgYzl0lJqDYWBkJh_wUAv5g_r0NzSQCsMqb-B3Lno5ScMnlA3SZ_Hg-XdW8hnFIlrwJj4Cv47j3fcZxpqLbTNDXWWogmRbJb3YPlgn_LEnRAyZnFERHKMCE9vaBSTu-1Qstp-gRTORjyV7l3y680dEygQS-99KV3OSBlz6g",
+ "token_type":"bearer",
+ "refresh_token":"eyJhbGciOiJSUzI1NiIsImtleV9pZCI6IjlLZlNILXphZjRjY1dmTlNPbm91YmZUbnItVW5kMHVuY3ctWF9KNUJVdWciLCJ0eXAiOiJKV1QifQ.eyJhdWQiOlsiaHR0cHM6Ly9kZW1vLm51Y2x5ZGUuaW8iXSwiY2xpZW50X2lkIjoiZmx5dGVjdGwiLCJleHAiOjE2MTk1MzM1MjcsImZvcm0iOnsiY29kZV9jaGFsbGVuZ2UiOiJ2bWNxazArZnJRS3Vvb2FMUHZwUDJCeUtod2VKR2VaeG1mdGtkMml0T042Tk13SVBQNWwySmNpWDd3NTdlaS9iVW1LTWhPSjJVUERnK0F5RXRaTG94SFJiMDl1cWRKSSIsImNvZGVfY2hhbGxlbmdlX21ldGhvZCI6IlN2WEgyeDh2UDUrSkJxQ0NjT2dCL0hNWjdLSmE3bkdLMDBaUVA0ekd4WGcifSwiaWF0IjoxNjE5NTAyNTM1LCJpc3MiOiJodHRwczovL2RlbW8ubnVjbHlkZS5pbyIsImp0aSI6IjQzMTM1ZWY2LTA5NjEtNGFlZC1hOTYxLWQyZGI1YWJmM2U1YyIsInNjcCI6WyJvZmZsaW5lIiwiZi5hbGwiLCJhY2Nlc3NfdG9rZW4iXSwic3ViIjoiMTE0NTI3ODE1MzA1MTI4OTc0NDcwIiwidXNlcl9pbmZvIjp7ImZhbWlseV9uYW1lIjoiTWFoaW5kcmFrYXIiLCJnaXZlbl9uYW1lIjoiUHJhZnVsbGEiLCJuYW1lIjoiUHJhZnVsbGEgTWFoaW5kcmFrYXIiLCJwaWN0dXJlIjoiaHR0cHM6Ly9saDMuZ29vZ2xldXNlcmNvbnRlbnQuY29tL2EtL0FPaDE0R2p1VDFrOC04YTV2QkdPSUYxYURnaFltRng4aEQ5S05pUjVqblp1PXM5Ni1jIiwic3ViamVjdCI6IjExNDUyNzgxNTMwNTEyODk3NDQ3MCJ9fQ.YKom5-gE4e84rJJIfxcpbMzgjZT33UZ27UTa1y8pK2BAWaPjIZtwudwDHQ5Rd3m0mJJWhBp0j0e8h9DvzBUdpsnGMXSCYKP-ag9y9k5OW59FMm9RqIakWHtj6NPnxGO1jAsaNCYePj8knR7pBLCLCse2taDHUJ8RU1F0DeHNr2y-JupgG5y1vjBcb-9eD8OwOSTp686_hm7XoJlxiKx8dj2O7HPH7M2pAHA_0bVrKKj7Y_s3fRhkm_Aq6LRdA-IiTl9xJQxgVUreejls9-RR9mSTKj6A81-Isz3qAUttVVaA4OT5OdW879_yT7OSLw_QwpXzNZ7qOR7OIpmL_xZXig",
+ "expiry":"2021-04-27T19:55:26.658635+05:30"
+}
\ No newline at end of file
diff --git a/flyteidl/clients/go/admin/pkce/token_cache.go b/flyteidl/clients/go/admin/pkce/token_cache.go
new file mode 100644
index 0000000000..22b1397f41
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/token_cache.go
@@ -0,0 +1,14 @@
+package pkce
+
+import "golang.org/x/oauth2"
+
+//go:generate mockery -all -case=underscore
+
+// TokenCache defines the interface needed to cache and retrieve oauth tokens.
+type TokenCache interface {
+ // SaveToken saves the token securely to cache.
+ SaveToken(token *oauth2.Token) error
+
+ // Retrieves the token from the cache.
+ GetToken() (*oauth2.Token, error)
+}
diff --git a/flyteidl/clients/go/admin/pkce/token_cache_inmemory.go b/flyteidl/clients/go/admin/pkce/token_cache_inmemory.go
new file mode 100644
index 0000000000..cde76cd423
--- /dev/null
+++ b/flyteidl/clients/go/admin/pkce/token_cache_inmemory.go
@@ -0,0 +1,24 @@
+package pkce
+
+import (
+ "fmt"
+
+ "golang.org/x/oauth2"
+)
+
+type TokenCacheInMemoryProvider struct {
+ token *oauth2.Token
+}
+
+func (t *TokenCacheInMemoryProvider) SaveToken(token *oauth2.Token) error {
+ t.token = token
+ return nil
+}
+
+func (t TokenCacheInMemoryProvider) GetToken() (*oauth2.Token, error) {
+ if t.token == nil {
+ return nil, fmt.Errorf("cannot find token in cache")
+ }
+
+ return t.token, nil
+}
diff --git a/flyteidl/clients/go/admin/testdata/secret_key b/flyteidl/clients/go/admin/testdata/secret_key
new file mode 100755
index 0000000000..b23f84a846
--- /dev/null
+++ b/flyteidl/clients/go/admin/testdata/secret_key
@@ -0,0 +1 @@
+pptDrk6qoJfM0Z1iFxvgUjxx9vEc46UuE6TvOmBJ4aY
\ No newline at end of file
diff --git a/flyteidl/clients/go/admin/token_source.go b/flyteidl/clients/go/admin/token_source.go
index 374d8d1860..604824836b 100644
--- a/flyteidl/clients/go/admin/token_source.go
+++ b/flyteidl/clients/go/admin/token_source.go
@@ -12,6 +12,7 @@ import (
type CustomHeaderTokenSource struct {
oauth2.TokenSource
customHeader string
+ insecure bool
}
const DefaultAuthorizationHeader = "authorization"
@@ -27,19 +28,23 @@ func (ts CustomHeaderTokenSource) GetRequestMetadata(ctx context.Context, uri ..
}, nil
}
-// Even though Admin is capable of serving authentication without SSL, we're going to require it here. That is, this module's
-// canonical Admin client will only do auth over SSL.
+// RequireTransportSecurity returns whether this credentials class requires TLS/SSL. OAuth uses Bearer tokens that are
+// susceptible to MITM (Man-In-The-Middle) attacks that are mitigated by TLS/SSL. We may return false here to make it
+// easier to setup auth. However, in a production environment, TLS for OAuth2 is a requirement.
+// see also: https://tools.ietf.org/html/rfc6749#section-3.1
func (ts CustomHeaderTokenSource) RequireTransportSecurity() bool {
- return true
+ return !ts.insecure
}
-func NewCustomHeaderTokenSource(source oauth2.TokenSource, customHeader string) CustomHeaderTokenSource {
+func NewCustomHeaderTokenSource(source oauth2.TokenSource, insecure bool, customHeader string) CustomHeaderTokenSource {
header := DefaultAuthorizationHeader
if customHeader != "" {
header = customHeader
}
+
return CustomHeaderTokenSource{
TokenSource: source,
customHeader: header,
+ insecure: insecure,
}
}
diff --git a/flyteidl/clients/go/admin/token_source_test.go b/flyteidl/clients/go/admin/token_source_test.go
index 3dc7800905..0e247bfe81 100644
--- a/flyteidl/clients/go/admin/token_source_test.go
+++ b/flyteidl/clients/go/admin/token_source_test.go
@@ -20,7 +20,7 @@ func (d DummyTestTokenSource) Token() (*oauth2.Token, error) {
func TestNewTokenSource(t *testing.T) {
tokenSource := DummyTestTokenSource{}
- flyteTokenSource := NewCustomHeaderTokenSource(tokenSource, "test")
+ flyteTokenSource := NewCustomHeaderTokenSource(tokenSource, true, "test")
metadata, err := flyteTokenSource.GetRequestMetadata(context.Background())
assert.NoError(t, err)
assert.Equal(t, "Bearer abc", metadata["test"])
diff --git a/flyteidl/clients/go/events/admin_eventsink.go b/flyteidl/clients/go/events/admin_eventsink.go
index ecb432f645..12ff3cacae 100644
--- a/flyteidl/clients/go/events/admin_eventsink.go
+++ b/flyteidl/clients/go/events/admin_eventsink.go
@@ -82,6 +82,16 @@ func (s *adminEventSink) Close() error {
return nil
}
+func initializeAdminClientFromConfig(ctx context.Context) (client service.AdminServiceClient, err error) {
+ cfg := admin2.GetConfig(ctx)
+ clients, err := admin2.NewClientsetBuilder().WithConfig(cfg).Build(ctx)
+ if err != nil {
+ return nil, fmt.Errorf("failed to initialize clientset. Error: %w", err)
+ }
+
+ return clients.AdminClient(), nil
+}
+
func ConstructEventSink(ctx context.Context, config *Config) (EventSink, error) {
switch config.Type {
case EventSinkLog:
@@ -89,10 +99,11 @@ func ConstructEventSink(ctx context.Context, config *Config) (EventSink, error)
case EventSinkFile:
return NewFileSink(config.FilePath)
case EventSinkAdmin:
- adminClient, err := admin2.InitializeAdminClientFromConfig(ctx)
+ adminClient, err := initializeAdminClientFromConfig(ctx)
if err != nil {
return nil, err
}
+
return NewAdminEventSink(ctx, adminClient, config)
default:
return NewStdoutSink()
diff --git a/flyteidl/gen/pb-cpp/flyteidl/service/auth.grpc.pb.cc b/flyteidl/gen/pb-cpp/flyteidl/service/auth.grpc.pb.cc
new file mode 100644
index 0000000000..c56ddb445d
--- /dev/null
+++ b/flyteidl/gen/pb-cpp/flyteidl/service/auth.grpc.pb.cc
@@ -0,0 +1,127 @@
+// Generated by the gRPC C++ plugin.
+// If you make any local change, they will be lost.
+// source: flyteidl/service/auth.proto
+
+#include "flyteidl/service/auth.pb.h"
+#include "flyteidl/service/auth.grpc.pb.h"
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+namespace flyteidl {
+namespace service {
+
+static const char* AuthMetadataService_method_names[] = {
+ "/flyteidl.service.AuthMetadataService/GetOAuth2Metadata",
+ "/flyteidl.service.AuthMetadataService/GetPublicClientConfig",
+};
+
+std::unique_ptr< AuthMetadataService::Stub> AuthMetadataService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
+ (void)options;
+ std::unique_ptr< AuthMetadataService::Stub> stub(new AuthMetadataService::Stub(channel));
+ return stub;
+}
+
+AuthMetadataService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel)
+ : channel_(channel), rpcmethod_GetOAuth2Metadata_(AuthMetadataService_method_names[0], ::grpc::internal::RpcMethod::NORMAL_RPC, channel)
+ , rpcmethod_GetPublicClientConfig_(AuthMetadataService_method_names[1], ::grpc::internal::RpcMethod::NORMAL_RPC, channel)
+ {}
+
+::grpc::Status AuthMetadataService::Stub::GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::flyteidl::service::OAuth2MetadataResponse* response) {
+ return ::grpc::internal::BlockingUnaryCall(channel_.get(), rpcmethod_GetOAuth2Metadata_, context, request, response);
+}
+
+void AuthMetadataService::Stub::experimental_async::GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response, std::function f) {
+ ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_GetOAuth2Metadata_, context, request, response, std::move(f));
+}
+
+void AuthMetadataService::Stub::experimental_async::GetOAuth2Metadata(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::OAuth2MetadataResponse* response, std::function f) {
+ ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_GetOAuth2Metadata_, context, request, response, std::move(f));
+}
+
+void AuthMetadataService::Stub::experimental_async::GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) {
+ ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_GetOAuth2Metadata_, context, request, response, reactor);
+}
+
+void AuthMetadataService::Stub::experimental_async::GetOAuth2Metadata(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::OAuth2MetadataResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) {
+ ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_GetOAuth2Metadata_, context, request, response, reactor);
+}
+
+::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>* AuthMetadataService::Stub::AsyncGetOAuth2MetadataRaw(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) {
+ return ::grpc::internal::ClientAsyncResponseReaderFactory< ::flyteidl::service::OAuth2MetadataResponse>::Create(channel_.get(), cq, rpcmethod_GetOAuth2Metadata_, context, request, true);
+}
+
+::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>* AuthMetadataService::Stub::PrepareAsyncGetOAuth2MetadataRaw(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) {
+ return ::grpc::internal::ClientAsyncResponseReaderFactory< ::flyteidl::service::OAuth2MetadataResponse>::Create(channel_.get(), cq, rpcmethod_GetOAuth2Metadata_, context, request, false);
+}
+
+::grpc::Status AuthMetadataService::Stub::GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::flyteidl::service::PublicClientAuthConfigResponse* response) {
+ return ::grpc::internal::BlockingUnaryCall(channel_.get(), rpcmethod_GetPublicClientConfig_, context, request, response);
+}
+
+void AuthMetadataService::Stub::experimental_async::GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, std::function f) {
+ ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_GetPublicClientConfig_, context, request, response, std::move(f));
+}
+
+void AuthMetadataService::Stub::experimental_async::GetPublicClientConfig(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, std::function f) {
+ ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_GetPublicClientConfig_, context, request, response, std::move(f));
+}
+
+void AuthMetadataService::Stub::experimental_async::GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) {
+ ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_GetPublicClientConfig_, context, request, response, reactor);
+}
+
+void AuthMetadataService::Stub::experimental_async::GetPublicClientConfig(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) {
+ ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_GetPublicClientConfig_, context, request, response, reactor);
+}
+
+::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>* AuthMetadataService::Stub::AsyncGetPublicClientConfigRaw(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) {
+ return ::grpc::internal::ClientAsyncResponseReaderFactory< ::flyteidl::service::PublicClientAuthConfigResponse>::Create(channel_.get(), cq, rpcmethod_GetPublicClientConfig_, context, request, true);
+}
+
+::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>* AuthMetadataService::Stub::PrepareAsyncGetPublicClientConfigRaw(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) {
+ return ::grpc::internal::ClientAsyncResponseReaderFactory< ::flyteidl::service::PublicClientAuthConfigResponse>::Create(channel_.get(), cq, rpcmethod_GetPublicClientConfig_, context, request, false);
+}
+
+AuthMetadataService::Service::Service() {
+ AddMethod(new ::grpc::internal::RpcServiceMethod(
+ AuthMetadataService_method_names[0],
+ ::grpc::internal::RpcMethod::NORMAL_RPC,
+ new ::grpc::internal::RpcMethodHandler< AuthMetadataService::Service, ::flyteidl::service::OAuth2MetadataRequest, ::flyteidl::service::OAuth2MetadataResponse>(
+ std::mem_fn(&AuthMetadataService::Service::GetOAuth2Metadata), this)));
+ AddMethod(new ::grpc::internal::RpcServiceMethod(
+ AuthMetadataService_method_names[1],
+ ::grpc::internal::RpcMethod::NORMAL_RPC,
+ new ::grpc::internal::RpcMethodHandler< AuthMetadataService::Service, ::flyteidl::service::PublicClientAuthConfigRequest, ::flyteidl::service::PublicClientAuthConfigResponse>(
+ std::mem_fn(&AuthMetadataService::Service::GetPublicClientConfig), this)));
+}
+
+AuthMetadataService::Service::~Service() {
+}
+
+::grpc::Status AuthMetadataService::Service::GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response) {
+ (void) context;
+ (void) request;
+ (void) response;
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+}
+
+::grpc::Status AuthMetadataService::Service::GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response) {
+ (void) context;
+ (void) request;
+ (void) response;
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+}
+
+
+} // namespace flyteidl
+} // namespace service
+
diff --git a/flyteidl/gen/pb-cpp/flyteidl/service/auth.grpc.pb.h b/flyteidl/gen/pb-cpp/flyteidl/service/auth.grpc.pb.h
new file mode 100644
index 0000000000..756b4eaa03
--- /dev/null
+++ b/flyteidl/gen/pb-cpp/flyteidl/service/auth.grpc.pb.h
@@ -0,0 +1,428 @@
+// Generated by the gRPC C++ plugin.
+// If you make any local change, they will be lost.
+// source: flyteidl/service/auth.proto
+#ifndef GRPC_flyteidl_2fservice_2fauth_2eproto__INCLUDED
+#define GRPC_flyteidl_2fservice_2fauth_2eproto__INCLUDED
+
+#include "flyteidl/service/auth.pb.h"
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+
+namespace grpc_impl {
+class Channel;
+class CompletionQueue;
+class ServerCompletionQueue;
+} // namespace grpc_impl
+
+namespace grpc {
+namespace experimental {
+template
+class MessageAllocator;
+} // namespace experimental
+} // namespace grpc_impl
+
+namespace grpc {
+class ServerContext;
+} // namespace grpc
+
+namespace flyteidl {
+namespace service {
+
+// The following defines an RPC service that is also served over HTTP via grpc-gateway.
+// Standard response codes for both are defined here: https://github.com/grpc-ecosystem/grpc-gateway/blob/master/runtime/errors.go
+// RPCs defined in this service must be anonymously accessible.
+class AuthMetadataService final {
+ public:
+ static constexpr char const* service_full_name() {
+ return "flyteidl.service.AuthMetadataService";
+ }
+ class StubInterface {
+ public:
+ virtual ~StubInterface() {}
+ // Anonymously accessible. Retrieves local or external oauth authorization server metadata.
+ virtual ::grpc::Status GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::flyteidl::service::OAuth2MetadataResponse* response) = 0;
+ std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::OAuth2MetadataResponse>> AsyncGetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::OAuth2MetadataResponse>>(AsyncGetOAuth2MetadataRaw(context, request, cq));
+ }
+ std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::OAuth2MetadataResponse>> PrepareAsyncGetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::OAuth2MetadataResponse>>(PrepareAsyncGetOAuth2MetadataRaw(context, request, cq));
+ }
+ // Anonymously accessible. Retrieves the client information clients should use when initiating OAuth2 authorization
+ // requests.
+ virtual ::grpc::Status GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::flyteidl::service::PublicClientAuthConfigResponse* response) = 0;
+ std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::PublicClientAuthConfigResponse>> AsyncGetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::PublicClientAuthConfigResponse>>(AsyncGetPublicClientConfigRaw(context, request, cq));
+ }
+ std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::PublicClientAuthConfigResponse>> PrepareAsyncGetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::PublicClientAuthConfigResponse>>(PrepareAsyncGetPublicClientConfigRaw(context, request, cq));
+ }
+ class experimental_async_interface {
+ public:
+ virtual ~experimental_async_interface() {}
+ // Anonymously accessible. Retrieves local or external oauth authorization server metadata.
+ virtual void GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response, std::function) = 0;
+ virtual void GetOAuth2Metadata(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::OAuth2MetadataResponse* response, std::function) = 0;
+ virtual void GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0;
+ virtual void GetOAuth2Metadata(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::OAuth2MetadataResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0;
+ // Anonymously accessible. Retrieves the client information clients should use when initiating OAuth2 authorization
+ // requests.
+ virtual void GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, std::function) = 0;
+ virtual void GetPublicClientConfig(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, std::function) = 0;
+ virtual void GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0;
+ virtual void GetPublicClientConfig(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0;
+ };
+ virtual class experimental_async_interface* experimental_async() { return nullptr; }
+ private:
+ virtual ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::OAuth2MetadataResponse>* AsyncGetOAuth2MetadataRaw(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) = 0;
+ virtual ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::OAuth2MetadataResponse>* PrepareAsyncGetOAuth2MetadataRaw(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) = 0;
+ virtual ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::PublicClientAuthConfigResponse>* AsyncGetPublicClientConfigRaw(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) = 0;
+ virtual ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::PublicClientAuthConfigResponse>* PrepareAsyncGetPublicClientConfigRaw(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) = 0;
+ };
+ class Stub final : public StubInterface {
+ public:
+ Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel);
+ ::grpc::Status GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::flyteidl::service::OAuth2MetadataResponse* response) override;
+ std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>> AsyncGetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>>(AsyncGetOAuth2MetadataRaw(context, request, cq));
+ }
+ std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>> PrepareAsyncGetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>>(PrepareAsyncGetOAuth2MetadataRaw(context, request, cq));
+ }
+ ::grpc::Status GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::flyteidl::service::PublicClientAuthConfigResponse* response) override;
+ std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>> AsyncGetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>>(AsyncGetPublicClientConfigRaw(context, request, cq));
+ }
+ std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>> PrepareAsyncGetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>>(PrepareAsyncGetPublicClientConfigRaw(context, request, cq));
+ }
+ class experimental_async final :
+ public StubInterface::experimental_async_interface {
+ public:
+ void GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response, std::function) override;
+ void GetOAuth2Metadata(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::OAuth2MetadataResponse* response, std::function) override;
+ void GetOAuth2Metadata(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override;
+ void GetOAuth2Metadata(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::OAuth2MetadataResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override;
+ void GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, std::function) override;
+ void GetPublicClientConfig(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, std::function) override;
+ void GetPublicClientConfig(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override;
+ void GetPublicClientConfig(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override;
+ private:
+ friend class Stub;
+ explicit experimental_async(Stub* stub): stub_(stub) { }
+ Stub* stub() { return stub_; }
+ Stub* stub_;
+ };
+ class experimental_async_interface* experimental_async() override { return &async_stub_; }
+
+ private:
+ std::shared_ptr< ::grpc::ChannelInterface> channel_;
+ class experimental_async async_stub_{this};
+ ::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>* AsyncGetOAuth2MetadataRaw(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) override;
+ ::grpc::ClientAsyncResponseReader< ::flyteidl::service::OAuth2MetadataResponse>* PrepareAsyncGetOAuth2MetadataRaw(::grpc::ClientContext* context, const ::flyteidl::service::OAuth2MetadataRequest& request, ::grpc::CompletionQueue* cq) override;
+ ::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>* AsyncGetPublicClientConfigRaw(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) override;
+ ::grpc::ClientAsyncResponseReader< ::flyteidl::service::PublicClientAuthConfigResponse>* PrepareAsyncGetPublicClientConfigRaw(::grpc::ClientContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest& request, ::grpc::CompletionQueue* cq) override;
+ const ::grpc::internal::RpcMethod rpcmethod_GetOAuth2Metadata_;
+ const ::grpc::internal::RpcMethod rpcmethod_GetPublicClientConfig_;
+ };
+ static std::unique_ptr NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions());
+
+ class Service : public ::grpc::Service {
+ public:
+ Service();
+ virtual ~Service();
+ // Anonymously accessible. Retrieves local or external oauth authorization server metadata.
+ virtual ::grpc::Status GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response);
+ // Anonymously accessible. Retrieves the client information clients should use when initiating OAuth2 authorization
+ // requests.
+ virtual ::grpc::Status GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response);
+ };
+ template
+ class WithAsyncMethod_GetOAuth2Metadata : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithAsyncMethod_GetOAuth2Metadata() {
+ ::grpc::Service::MarkMethodAsync(0);
+ }
+ ~WithAsyncMethod_GetOAuth2Metadata() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ void RequestGetOAuth2Metadata(::grpc::ServerContext* context, ::flyteidl::service::OAuth2MetadataRequest* request, ::grpc::ServerAsyncResponseWriter< ::flyteidl::service::OAuth2MetadataResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
+ ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
+ }
+ };
+ template
+ class WithAsyncMethod_GetPublicClientConfig : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithAsyncMethod_GetPublicClientConfig() {
+ ::grpc::Service::MarkMethodAsync(1);
+ }
+ ~WithAsyncMethod_GetPublicClientConfig() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ void RequestGetPublicClientConfig(::grpc::ServerContext* context, ::flyteidl::service::PublicClientAuthConfigRequest* request, ::grpc::ServerAsyncResponseWriter< ::flyteidl::service::PublicClientAuthConfigResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
+ ::grpc::Service::RequestAsyncUnary(1, context, request, response, new_call_cq, notification_cq, tag);
+ }
+ };
+ typedef WithAsyncMethod_GetOAuth2Metadata > AsyncService;
+ template
+ class ExperimentalWithCallbackMethod_GetOAuth2Metadata : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ ExperimentalWithCallbackMethod_GetOAuth2Metadata() {
+ ::grpc::Service::experimental().MarkMethodCallback(0,
+ new ::grpc::internal::CallbackUnaryHandler< ::flyteidl::service::OAuth2MetadataRequest, ::flyteidl::service::OAuth2MetadataResponse>(
+ [this](::grpc::ServerContext* context,
+ const ::flyteidl::service::OAuth2MetadataRequest* request,
+ ::flyteidl::service::OAuth2MetadataResponse* response,
+ ::grpc::experimental::ServerCallbackRpcController* controller) {
+ return this->GetOAuth2Metadata(context, request, response, controller);
+ }));
+ }
+ void SetMessageAllocatorFor_GetOAuth2Metadata(
+ ::grpc::experimental::MessageAllocator< ::flyteidl::service::OAuth2MetadataRequest, ::flyteidl::service::OAuth2MetadataResponse>* allocator) {
+ static_cast<::grpc::internal::CallbackUnaryHandler< ::flyteidl::service::OAuth2MetadataRequest, ::flyteidl::service::OAuth2MetadataResponse>*>(
+ ::grpc::Service::experimental().GetHandler(0))
+ ->SetMessageAllocator(allocator);
+ }
+ ~ExperimentalWithCallbackMethod_GetOAuth2Metadata() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ virtual void GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
+ };
+ template
+ class ExperimentalWithCallbackMethod_GetPublicClientConfig : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ ExperimentalWithCallbackMethod_GetPublicClientConfig() {
+ ::grpc::Service::experimental().MarkMethodCallback(1,
+ new ::grpc::internal::CallbackUnaryHandler< ::flyteidl::service::PublicClientAuthConfigRequest, ::flyteidl::service::PublicClientAuthConfigResponse>(
+ [this](::grpc::ServerContext* context,
+ const ::flyteidl::service::PublicClientAuthConfigRequest* request,
+ ::flyteidl::service::PublicClientAuthConfigResponse* response,
+ ::grpc::experimental::ServerCallbackRpcController* controller) {
+ return this->GetPublicClientConfig(context, request, response, controller);
+ }));
+ }
+ void SetMessageAllocatorFor_GetPublicClientConfig(
+ ::grpc::experimental::MessageAllocator< ::flyteidl::service::PublicClientAuthConfigRequest, ::flyteidl::service::PublicClientAuthConfigResponse>* allocator) {
+ static_cast<::grpc::internal::CallbackUnaryHandler< ::flyteidl::service::PublicClientAuthConfigRequest, ::flyteidl::service::PublicClientAuthConfigResponse>*>(
+ ::grpc::Service::experimental().GetHandler(1))
+ ->SetMessageAllocator(allocator);
+ }
+ ~ExperimentalWithCallbackMethod_GetPublicClientConfig() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ virtual void GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
+ };
+ typedef ExperimentalWithCallbackMethod_GetOAuth2Metadata > ExperimentalCallbackService;
+ template
+ class WithGenericMethod_GetOAuth2Metadata : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithGenericMethod_GetOAuth2Metadata() {
+ ::grpc::Service::MarkMethodGeneric(0);
+ }
+ ~WithGenericMethod_GetOAuth2Metadata() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ };
+ template
+ class WithGenericMethod_GetPublicClientConfig : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithGenericMethod_GetPublicClientConfig() {
+ ::grpc::Service::MarkMethodGeneric(1);
+ }
+ ~WithGenericMethod_GetPublicClientConfig() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ };
+ template
+ class WithRawMethod_GetOAuth2Metadata : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithRawMethod_GetOAuth2Metadata() {
+ ::grpc::Service::MarkMethodRaw(0);
+ }
+ ~WithRawMethod_GetOAuth2Metadata() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ void RequestGetOAuth2Metadata(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
+ ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
+ }
+ };
+ template
+ class WithRawMethod_GetPublicClientConfig : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithRawMethod_GetPublicClientConfig() {
+ ::grpc::Service::MarkMethodRaw(1);
+ }
+ ~WithRawMethod_GetPublicClientConfig() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ void RequestGetPublicClientConfig(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
+ ::grpc::Service::RequestAsyncUnary(1, context, request, response, new_call_cq, notification_cq, tag);
+ }
+ };
+ template
+ class ExperimentalWithRawCallbackMethod_GetOAuth2Metadata : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ ExperimentalWithRawCallbackMethod_GetOAuth2Metadata() {
+ ::grpc::Service::experimental().MarkMethodRawCallback(0,
+ new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
+ [this](::grpc::ServerContext* context,
+ const ::grpc::ByteBuffer* request,
+ ::grpc::ByteBuffer* response,
+ ::grpc::experimental::ServerCallbackRpcController* controller) {
+ this->GetOAuth2Metadata(context, request, response, controller);
+ }));
+ }
+ ~ExperimentalWithRawCallbackMethod_GetOAuth2Metadata() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ virtual void GetOAuth2Metadata(::grpc::ServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
+ };
+ template
+ class ExperimentalWithRawCallbackMethod_GetPublicClientConfig : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ ExperimentalWithRawCallbackMethod_GetPublicClientConfig() {
+ ::grpc::Service::experimental().MarkMethodRawCallback(1,
+ new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
+ [this](::grpc::ServerContext* context,
+ const ::grpc::ByteBuffer* request,
+ ::grpc::ByteBuffer* response,
+ ::grpc::experimental::ServerCallbackRpcController* controller) {
+ this->GetPublicClientConfig(context, request, response, controller);
+ }));
+ }
+ ~ExperimentalWithRawCallbackMethod_GetPublicClientConfig() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ virtual void GetPublicClientConfig(::grpc::ServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
+ };
+ template
+ class WithStreamedUnaryMethod_GetOAuth2Metadata : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithStreamedUnaryMethod_GetOAuth2Metadata() {
+ ::grpc::Service::MarkMethodStreamed(0,
+ new ::grpc::internal::StreamedUnaryHandler< ::flyteidl::service::OAuth2MetadataRequest, ::flyteidl::service::OAuth2MetadataResponse>(std::bind(&WithStreamedUnaryMethod_GetOAuth2Metadata::StreamedGetOAuth2Metadata, this, std::placeholders::_1, std::placeholders::_2)));
+ }
+ ~WithStreamedUnaryMethod_GetOAuth2Metadata() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable regular version of this method
+ ::grpc::Status GetOAuth2Metadata(::grpc::ServerContext* context, const ::flyteidl::service::OAuth2MetadataRequest* request, ::flyteidl::service::OAuth2MetadataResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ // replace default version of method with streamed unary
+ virtual ::grpc::Status StreamedGetOAuth2Metadata(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::flyteidl::service::OAuth2MetadataRequest,::flyteidl::service::OAuth2MetadataResponse>* server_unary_streamer) = 0;
+ };
+ template
+ class WithStreamedUnaryMethod_GetPublicClientConfig : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithStreamedUnaryMethod_GetPublicClientConfig() {
+ ::grpc::Service::MarkMethodStreamed(1,
+ new ::grpc::internal::StreamedUnaryHandler< ::flyteidl::service::PublicClientAuthConfigRequest, ::flyteidl::service::PublicClientAuthConfigResponse>(std::bind(&WithStreamedUnaryMethod_GetPublicClientConfig::StreamedGetPublicClientConfig, this, std::placeholders::_1, std::placeholders::_2)));
+ }
+ ~WithStreamedUnaryMethod_GetPublicClientConfig() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable regular version of this method
+ ::grpc::Status GetPublicClientConfig(::grpc::ServerContext* context, const ::flyteidl::service::PublicClientAuthConfigRequest* request, ::flyteidl::service::PublicClientAuthConfigResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ // replace default version of method with streamed unary
+ virtual ::grpc::Status StreamedGetPublicClientConfig(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::flyteidl::service::PublicClientAuthConfigRequest,::flyteidl::service::PublicClientAuthConfigResponse>* server_unary_streamer) = 0;
+ };
+ typedef WithStreamedUnaryMethod_GetOAuth2Metadata > StreamedUnaryService;
+ typedef Service SplitStreamedService;
+ typedef WithStreamedUnaryMethod_GetOAuth2Metadata > StreamedService;
+};
+
+} // namespace service
+} // namespace flyteidl
+
+
+#endif // GRPC_flyteidl_2fservice_2fauth_2eproto__INCLUDED
diff --git a/flyteidl/gen/pb-cpp/flyteidl/service/auth.pb.cc b/flyteidl/gen/pb-cpp/flyteidl/service/auth.pb.cc
new file mode 100644
index 0000000000..ccad52a85a
--- /dev/null
+++ b/flyteidl/gen/pb-cpp/flyteidl/service/auth.pb.cc
@@ -0,0 +1,2043 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: flyteidl/service/auth.proto
+
+#include "flyteidl/service/auth.pb.h"
+
+#include
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+// @@protoc_insertion_point(includes)
+#include
+
+namespace flyteidl {
+namespace service {
+class OAuth2MetadataRequestDefaultTypeInternal {
+ public:
+ ::google::protobuf::internal::ExplicitlyConstructed _instance;
+} _OAuth2MetadataRequest_default_instance_;
+class OAuth2MetadataResponseDefaultTypeInternal {
+ public:
+ ::google::protobuf::internal::ExplicitlyConstructed _instance;
+} _OAuth2MetadataResponse_default_instance_;
+class PublicClientAuthConfigRequestDefaultTypeInternal {
+ public:
+ ::google::protobuf::internal::ExplicitlyConstructed _instance;
+} _PublicClientAuthConfigRequest_default_instance_;
+class PublicClientAuthConfigResponseDefaultTypeInternal {
+ public:
+ ::google::protobuf::internal::ExplicitlyConstructed _instance;
+} _PublicClientAuthConfigResponse_default_instance_;
+} // namespace service
+} // namespace flyteidl
+static void InitDefaultsOAuth2MetadataRequest_flyteidl_2fservice_2fauth_2eproto() {
+ GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+ {
+ void* ptr = &::flyteidl::service::_OAuth2MetadataRequest_default_instance_;
+ new (ptr) ::flyteidl::service::OAuth2MetadataRequest();
+ ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
+ }
+ ::flyteidl::service::OAuth2MetadataRequest::InitAsDefaultInstance();
+}
+
+::google::protobuf::internal::SCCInfo<0> scc_info_OAuth2MetadataRequest_flyteidl_2fservice_2fauth_2eproto =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsOAuth2MetadataRequest_flyteidl_2fservice_2fauth_2eproto}, {}};
+
+static void InitDefaultsOAuth2MetadataResponse_flyteidl_2fservice_2fauth_2eproto() {
+ GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+ {
+ void* ptr = &::flyteidl::service::_OAuth2MetadataResponse_default_instance_;
+ new (ptr) ::flyteidl::service::OAuth2MetadataResponse();
+ ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
+ }
+ ::flyteidl::service::OAuth2MetadataResponse::InitAsDefaultInstance();
+}
+
+::google::protobuf::internal::SCCInfo<0> scc_info_OAuth2MetadataResponse_flyteidl_2fservice_2fauth_2eproto =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsOAuth2MetadataResponse_flyteidl_2fservice_2fauth_2eproto}, {}};
+
+static void InitDefaultsPublicClientAuthConfigRequest_flyteidl_2fservice_2fauth_2eproto() {
+ GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+ {
+ void* ptr = &::flyteidl::service::_PublicClientAuthConfigRequest_default_instance_;
+ new (ptr) ::flyteidl::service::PublicClientAuthConfigRequest();
+ ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
+ }
+ ::flyteidl::service::PublicClientAuthConfigRequest::InitAsDefaultInstance();
+}
+
+::google::protobuf::internal::SCCInfo<0> scc_info_PublicClientAuthConfigRequest_flyteidl_2fservice_2fauth_2eproto =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsPublicClientAuthConfigRequest_flyteidl_2fservice_2fauth_2eproto}, {}};
+
+static void InitDefaultsPublicClientAuthConfigResponse_flyteidl_2fservice_2fauth_2eproto() {
+ GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+ {
+ void* ptr = &::flyteidl::service::_PublicClientAuthConfigResponse_default_instance_;
+ new (ptr) ::flyteidl::service::PublicClientAuthConfigResponse();
+ ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
+ }
+ ::flyteidl::service::PublicClientAuthConfigResponse::InitAsDefaultInstance();
+}
+
+::google::protobuf::internal::SCCInfo<0> scc_info_PublicClientAuthConfigResponse_flyteidl_2fservice_2fauth_2eproto =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsPublicClientAuthConfigResponse_flyteidl_2fservice_2fauth_2eproto}, {}};
+
+void InitDefaults_flyteidl_2fservice_2fauth_2eproto() {
+ ::google::protobuf::internal::InitSCC(&scc_info_OAuth2MetadataRequest_flyteidl_2fservice_2fauth_2eproto.base);
+ ::google::protobuf::internal::InitSCC(&scc_info_OAuth2MetadataResponse_flyteidl_2fservice_2fauth_2eproto.base);
+ ::google::protobuf::internal::InitSCC(&scc_info_PublicClientAuthConfigRequest_flyteidl_2fservice_2fauth_2eproto.base);
+ ::google::protobuf::internal::InitSCC(&scc_info_PublicClientAuthConfigResponse_flyteidl_2fservice_2fauth_2eproto.base);
+}
+
+::google::protobuf::Metadata file_level_metadata_flyteidl_2fservice_2fauth_2eproto[4];
+constexpr ::google::protobuf::EnumDescriptor const** file_level_enum_descriptors_flyteidl_2fservice_2fauth_2eproto = nullptr;
+constexpr ::google::protobuf::ServiceDescriptor const** file_level_service_descriptors_flyteidl_2fservice_2fauth_2eproto = nullptr;
+
+const ::google::protobuf::uint32 TableStruct_flyteidl_2fservice_2fauth_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
+ ~0u, // no _has_bits_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataRequest, _internal_metadata_),
+ ~0u, // no _extensions_
+ ~0u, // no _oneof_case_
+ ~0u, // no _weak_field_map_
+ ~0u, // no _has_bits_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, _internal_metadata_),
+ ~0u, // no _extensions_
+ ~0u, // no _oneof_case_
+ ~0u, // no _weak_field_map_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, issuer_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, authorization_endpoint_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, token_endpoint_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, response_types_supported_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, scopes_supported_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, token_endpoint_auth_methods_supported_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, jwks_uri_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, code_challenge_methods_supported_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::OAuth2MetadataResponse, grant_types_supported_),
+ ~0u, // no _has_bits_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::PublicClientAuthConfigRequest, _internal_metadata_),
+ ~0u, // no _extensions_
+ ~0u, // no _oneof_case_
+ ~0u, // no _weak_field_map_
+ ~0u, // no _has_bits_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::PublicClientAuthConfigResponse, _internal_metadata_),
+ ~0u, // no _extensions_
+ ~0u, // no _oneof_case_
+ ~0u, // no _weak_field_map_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::PublicClientAuthConfigResponse, client_id_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::PublicClientAuthConfigResponse, redirect_uri_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::PublicClientAuthConfigResponse, scopes_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::PublicClientAuthConfigResponse, authorization_metadata_key_),
+};
+static const ::google::protobuf::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
+ { 0, -1, sizeof(::flyteidl::service::OAuth2MetadataRequest)},
+ { 5, -1, sizeof(::flyteidl::service::OAuth2MetadataResponse)},
+ { 19, -1, sizeof(::flyteidl::service::PublicClientAuthConfigRequest)},
+ { 24, -1, sizeof(::flyteidl::service::PublicClientAuthConfigResponse)},
+};
+
+static ::google::protobuf::Message const * const file_default_instances[] = {
+ reinterpret_cast(&::flyteidl::service::_OAuth2MetadataRequest_default_instance_),
+ reinterpret_cast(&::flyteidl::service::_OAuth2MetadataResponse_default_instance_),
+ reinterpret_cast(&::flyteidl::service::_PublicClientAuthConfigRequest_default_instance_),
+ reinterpret_cast(&::flyteidl::service::_PublicClientAuthConfigResponse_default_instance_),
+};
+
+::google::protobuf::internal::AssignDescriptorsTable assign_descriptors_table_flyteidl_2fservice_2fauth_2eproto = {
+ {}, AddDescriptors_flyteidl_2fservice_2fauth_2eproto, "flyteidl/service/auth.proto", schemas,
+ file_default_instances, TableStruct_flyteidl_2fservice_2fauth_2eproto::offsets,
+ file_level_metadata_flyteidl_2fservice_2fauth_2eproto, 4, file_level_enum_descriptors_flyteidl_2fservice_2fauth_2eproto, file_level_service_descriptors_flyteidl_2fservice_2fauth_2eproto,
+};
+
+const char descriptor_table_protodef_flyteidl_2fservice_2fauth_2eproto[] =
+ "\n\033flyteidl/service/auth.proto\022\020flyteidl."
+ "service\032\034google/api/annotations.proto\032\034f"
+ "lyteidl/admin/project.proto\032.flyteidl/ad"
+ "min/project_domain_attributes.proto\032\031fly"
+ "teidl/admin/task.proto\032\035flyteidl/admin/w"
+ "orkflow.proto\032(flyteidl/admin/workflow_a"
+ "ttributes.proto\032 flyteidl/admin/launch_p"
+ "lan.proto\032\032flyteidl/admin/event.proto\032\036f"
+ "lyteidl/admin/execution.proto\032\'flyteidl/"
+ "admin/matchable_resource.proto\032#flyteidl"
+ "/admin/node_execution.proto\032#flyteidl/ad"
+ "min/task_execution.proto\032\034flyteidl/admin"
+ "/version.proto\032\033flyteidl/admin/common.pr"
+ "oto\032,protoc-gen-swagger/options/annotati"
+ "ons.proto\"\027\n\025OAuth2MetadataRequest\"\246\002\n\026O"
+ "Auth2MetadataResponse\022\016\n\006issuer\030\001 \001(\t\022\036\n"
+ "\026authorization_endpoint\030\002 \001(\t\022\026\n\016token_e"
+ "ndpoint\030\003 \001(\t\022 \n\030response_types_supporte"
+ "d\030\004 \003(\t\022\030\n\020scopes_supported\030\005 \003(\t\022-\n%tok"
+ "en_endpoint_auth_methods_supported\030\006 \003(\t"
+ "\022\020\n\010jwks_uri\030\007 \001(\t\022(\n code_challenge_met"
+ "hods_supported\030\010 \003(\t\022\035\n\025grant_types_supp"
+ "orted\030\t \003(\t\"\037\n\035PublicClientAuthConfigReq"
+ "uest\"}\n\036PublicClientAuthConfigResponse\022\021"
+ "\n\tclient_id\030\001 \001(\t\022\024\n\014redirect_uri\030\002 \001(\t\022"
+ "\016\n\006scopes\030\003 \003(\t\022\"\n\032authorization_metadat"
+ "a_key\030\004 \001(\t2\374\003\n\023AuthMetadataService\022\365\001\n\021"
+ "GetOAuth2Metadata\022\'.flyteidl.service.OAu"
+ "th2MetadataRequest\032(.flyteidl.service.OA"
+ "uth2MetadataResponse\"\214\001\202\323\344\223\002)\022\'/.well-kn"
+ "own/oauth-authorization-server\222AZ\032XRetri"
+ "eves OAuth2 authorization server metadat"
+ "a. This endpoint is anonymously accessib"
+ "le.\022\354\001\n\025GetPublicClientConfig\022/.flyteidl"
+ ".service.PublicClientAuthConfigRequest\0320"
+ ".flyteidl.service.PublicClientAuthConfig"
+ "Response\"p\202\323\344\223\002\031\022\027/config/v1/flyte_clien"
+ "t\222AN\032LRetrieves public flyte client info"
+ ". This endpoint is anonymously accessibl"
+ "e.B9Z7github.com/flyteorg/flyteidl/gen/p"
+ "b-go/flyteidl/serviceb\006proto3"
+ ;
+::google::protobuf::internal::DescriptorTable descriptor_table_flyteidl_2fservice_2fauth_2eproto = {
+ false, InitDefaults_flyteidl_2fservice_2fauth_2eproto,
+ descriptor_table_protodef_flyteidl_2fservice_2fauth_2eproto,
+ "flyteidl/service/auth.proto", &assign_descriptors_table_flyteidl_2fservice_2fauth_2eproto, 1629,
+};
+
+void AddDescriptors_flyteidl_2fservice_2fauth_2eproto() {
+ static constexpr ::google::protobuf::internal::InitFunc deps[15] =
+ {
+ ::AddDescriptors_google_2fapi_2fannotations_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fproject_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fproject_5fdomain_5fattributes_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2ftask_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fworkflow_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fworkflow_5fattributes_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2flaunch_5fplan_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fevent_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fexecution_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fmatchable_5fresource_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fnode_5fexecution_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2ftask_5fexecution_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fversion_2eproto,
+ ::AddDescriptors_flyteidl_2fadmin_2fcommon_2eproto,
+ ::AddDescriptors_protoc_2dgen_2dswagger_2foptions_2fannotations_2eproto,
+ };
+ ::google::protobuf::internal::AddDescriptors(&descriptor_table_flyteidl_2fservice_2fauth_2eproto, deps, 15);
+}
+
+// Force running AddDescriptors() at dynamic initialization time.
+static bool dynamic_init_dummy_flyteidl_2fservice_2fauth_2eproto = []() { AddDescriptors_flyteidl_2fservice_2fauth_2eproto(); return true; }();
+namespace flyteidl {
+namespace service {
+
+// ===================================================================
+
+void OAuth2MetadataRequest::InitAsDefaultInstance() {
+}
+class OAuth2MetadataRequest::HasBitSetters {
+ public:
+};
+
+#if !defined(_MSC_VER) || _MSC_VER >= 1900
+#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
+
+OAuth2MetadataRequest::OAuth2MetadataRequest()
+ : ::google::protobuf::Message(), _internal_metadata_(nullptr) {
+ SharedCtor();
+ // @@protoc_insertion_point(constructor:flyteidl.service.OAuth2MetadataRequest)
+}
+OAuth2MetadataRequest::OAuth2MetadataRequest(const OAuth2MetadataRequest& from)
+ : ::google::protobuf::Message(),
+ _internal_metadata_(nullptr) {
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ // @@protoc_insertion_point(copy_constructor:flyteidl.service.OAuth2MetadataRequest)
+}
+
+void OAuth2MetadataRequest::SharedCtor() {
+}
+
+OAuth2MetadataRequest::~OAuth2MetadataRequest() {
+ // @@protoc_insertion_point(destructor:flyteidl.service.OAuth2MetadataRequest)
+ SharedDtor();
+}
+
+void OAuth2MetadataRequest::SharedDtor() {
+}
+
+void OAuth2MetadataRequest::SetCachedSize(int size) const {
+ _cached_size_.Set(size);
+}
+const OAuth2MetadataRequest& OAuth2MetadataRequest::default_instance() {
+ ::google::protobuf::internal::InitSCC(&::scc_info_OAuth2MetadataRequest_flyteidl_2fservice_2fauth_2eproto.base);
+ return *internal_default_instance();
+}
+
+
+void OAuth2MetadataRequest::Clear() {
+// @@protoc_insertion_point(message_clear_start:flyteidl.service.OAuth2MetadataRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* OAuth2MetadataRequest::_InternalParse(const char* begin, const char* end, void* object,
+ ::google::protobuf::internal::ParseContext* ctx) {
+ auto msg = static_cast(object);
+ ::google::protobuf::int32 size; (void)size;
+ int depth; (void)depth;
+ ::google::protobuf::uint32 tag;
+ ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end;
+ auto ptr = begin;
+ while (ptr < end) {
+ ptr = ::google::protobuf::io::Parse32(ptr, &tag);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ switch (tag >> 3) {
+ default: {
+ if ((tag & 7) == 4 || tag == 0) {
+ ctx->EndGroup(tag);
+ return ptr;
+ }
+ auto res = UnknownFieldParse(tag, {_InternalParse, msg},
+ ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx);
+ ptr = res.first;
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr);
+ if (res.second) return ptr;
+ }
+ } // switch
+ } // while
+ return ptr;
+}
+#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool OAuth2MetadataRequest::MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+ ::google::protobuf::uint32 tag;
+ // @@protoc_insertion_point(parse_start:flyteidl.service.OAuth2MetadataRequest)
+ for (;;) {
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ tag = p.first;
+ if (!p.second) goto handle_unusual;
+ handle_unusual:
+ if (tag == 0) {
+ goto success;
+ }
+ DO_(::google::protobuf::internal::WireFormat::SkipField(
+ input, tag, _internal_metadata_.mutable_unknown_fields()));
+ }
+success:
+ // @@protoc_insertion_point(parse_success:flyteidl.service.OAuth2MetadataRequest)
+ return true;
+failure:
+ // @@protoc_insertion_point(parse_failure:flyteidl.service.OAuth2MetadataRequest)
+ return false;
+#undef DO_
+}
+#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void OAuth2MetadataRequest::SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const {
+ // @@protoc_insertion_point(serialize_start:flyteidl.service.OAuth2MetadataRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
+ _internal_metadata_.unknown_fields(), output);
+ }
+ // @@protoc_insertion_point(serialize_end:flyteidl.service.OAuth2MetadataRequest)
+}
+
+::google::protobuf::uint8* OAuth2MetadataRequest::InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const {
+ // @@protoc_insertion_point(serialize_to_array_start:flyteidl.service.OAuth2MetadataRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
+ _internal_metadata_.unknown_fields(), target);
+ }
+ // @@protoc_insertion_point(serialize_to_array_end:flyteidl.service.OAuth2MetadataRequest)
+ return target;
+}
+
+size_t OAuth2MetadataRequest::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:flyteidl.service.OAuth2MetadataRequest)
+ size_t total_size = 0;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ total_size +=
+ ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
+ _internal_metadata_.unknown_fields());
+ }
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
+ SetCachedSize(cached_size);
+ return total_size;
+}
+
+void OAuth2MetadataRequest::MergeFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:flyteidl.service.OAuth2MetadataRequest)
+ GOOGLE_DCHECK_NE(&from, this);
+ const OAuth2MetadataRequest* source =
+ ::google::protobuf::DynamicCastToGenerated(
+ &from);
+ if (source == nullptr) {
+ // @@protoc_insertion_point(generalized_merge_from_cast_fail:flyteidl.service.OAuth2MetadataRequest)
+ ::google::protobuf::internal::ReflectionOps::Merge(from, this);
+ } else {
+ // @@protoc_insertion_point(generalized_merge_from_cast_success:flyteidl.service.OAuth2MetadataRequest)
+ MergeFrom(*source);
+ }
+}
+
+void OAuth2MetadataRequest::MergeFrom(const OAuth2MetadataRequest& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:flyteidl.service.OAuth2MetadataRequest)
+ GOOGLE_DCHECK_NE(&from, this);
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+}
+
+void OAuth2MetadataRequest::CopyFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:flyteidl.service.OAuth2MetadataRequest)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+void OAuth2MetadataRequest::CopyFrom(const OAuth2MetadataRequest& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:flyteidl.service.OAuth2MetadataRequest)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+bool OAuth2MetadataRequest::IsInitialized() const {
+ return true;
+}
+
+void OAuth2MetadataRequest::Swap(OAuth2MetadataRequest* other) {
+ if (other == this) return;
+ InternalSwap(other);
+}
+void OAuth2MetadataRequest::InternalSwap(OAuth2MetadataRequest* other) {
+ using std::swap;
+ _internal_metadata_.Swap(&other->_internal_metadata_);
+}
+
+::google::protobuf::Metadata OAuth2MetadataRequest::GetMetadata() const {
+ ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fservice_2fauth_2eproto);
+ return ::file_level_metadata_flyteidl_2fservice_2fauth_2eproto[kIndexInFileMessages];
+}
+
+
+// ===================================================================
+
+void OAuth2MetadataResponse::InitAsDefaultInstance() {
+}
+class OAuth2MetadataResponse::HasBitSetters {
+ public:
+};
+
+#if !defined(_MSC_VER) || _MSC_VER >= 1900
+const int OAuth2MetadataResponse::kIssuerFieldNumber;
+const int OAuth2MetadataResponse::kAuthorizationEndpointFieldNumber;
+const int OAuth2MetadataResponse::kTokenEndpointFieldNumber;
+const int OAuth2MetadataResponse::kResponseTypesSupportedFieldNumber;
+const int OAuth2MetadataResponse::kScopesSupportedFieldNumber;
+const int OAuth2MetadataResponse::kTokenEndpointAuthMethodsSupportedFieldNumber;
+const int OAuth2MetadataResponse::kJwksUriFieldNumber;
+const int OAuth2MetadataResponse::kCodeChallengeMethodsSupportedFieldNumber;
+const int OAuth2MetadataResponse::kGrantTypesSupportedFieldNumber;
+#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
+
+OAuth2MetadataResponse::OAuth2MetadataResponse()
+ : ::google::protobuf::Message(), _internal_metadata_(nullptr) {
+ SharedCtor();
+ // @@protoc_insertion_point(constructor:flyteidl.service.OAuth2MetadataResponse)
+}
+OAuth2MetadataResponse::OAuth2MetadataResponse(const OAuth2MetadataResponse& from)
+ : ::google::protobuf::Message(),
+ _internal_metadata_(nullptr),
+ response_types_supported_(from.response_types_supported_),
+ scopes_supported_(from.scopes_supported_),
+ token_endpoint_auth_methods_supported_(from.token_endpoint_auth_methods_supported_),
+ code_challenge_methods_supported_(from.code_challenge_methods_supported_),
+ grant_types_supported_(from.grant_types_supported_) {
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ issuer_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.issuer().size() > 0) {
+ issuer_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.issuer_);
+ }
+ authorization_endpoint_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.authorization_endpoint().size() > 0) {
+ authorization_endpoint_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.authorization_endpoint_);
+ }
+ token_endpoint_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.token_endpoint().size() > 0) {
+ token_endpoint_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.token_endpoint_);
+ }
+ jwks_uri_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.jwks_uri().size() > 0) {
+ jwks_uri_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.jwks_uri_);
+ }
+ // @@protoc_insertion_point(copy_constructor:flyteidl.service.OAuth2MetadataResponse)
+}
+
+void OAuth2MetadataResponse::SharedCtor() {
+ ::google::protobuf::internal::InitSCC(
+ &scc_info_OAuth2MetadataResponse_flyteidl_2fservice_2fauth_2eproto.base);
+ issuer_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ authorization_endpoint_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ token_endpoint_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ jwks_uri_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+
+OAuth2MetadataResponse::~OAuth2MetadataResponse() {
+ // @@protoc_insertion_point(destructor:flyteidl.service.OAuth2MetadataResponse)
+ SharedDtor();
+}
+
+void OAuth2MetadataResponse::SharedDtor() {
+ issuer_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ authorization_endpoint_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ token_endpoint_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ jwks_uri_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+
+void OAuth2MetadataResponse::SetCachedSize(int size) const {
+ _cached_size_.Set(size);
+}
+const OAuth2MetadataResponse& OAuth2MetadataResponse::default_instance() {
+ ::google::protobuf::internal::InitSCC(&::scc_info_OAuth2MetadataResponse_flyteidl_2fservice_2fauth_2eproto.base);
+ return *internal_default_instance();
+}
+
+
+void OAuth2MetadataResponse::Clear() {
+// @@protoc_insertion_point(message_clear_start:flyteidl.service.OAuth2MetadataResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ response_types_supported_.Clear();
+ scopes_supported_.Clear();
+ token_endpoint_auth_methods_supported_.Clear();
+ code_challenge_methods_supported_.Clear();
+ grant_types_supported_.Clear();
+ issuer_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ authorization_endpoint_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ token_endpoint_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ jwks_uri_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* OAuth2MetadataResponse::_InternalParse(const char* begin, const char* end, void* object,
+ ::google::protobuf::internal::ParseContext* ctx) {
+ auto msg = static_cast(object);
+ ::google::protobuf::int32 size; (void)size;
+ int depth; (void)depth;
+ ::google::protobuf::uint32 tag;
+ ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end;
+ auto ptr = begin;
+ while (ptr < end) {
+ ptr = ::google::protobuf::io::Parse32(ptr, &tag);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ switch (tag >> 3) {
+ // string issuer = 1;
+ case 1: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 10) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.issuer");
+ object = msg->mutable_issuer();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string authorization_endpoint = 2;
+ case 2: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 18) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.authorization_endpoint");
+ object = msg->mutable_authorization_endpoint();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string token_endpoint = 3;
+ case 3: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 26) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.token_endpoint");
+ object = msg->mutable_token_endpoint();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // repeated string response_types_supported = 4;
+ case 4: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 34) goto handle_unusual;
+ do {
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.response_types_supported");
+ object = msg->add_response_types_supported();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ if (ptr >= end) break;
+ } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 34 && (ptr += 1));
+ break;
+ }
+ // repeated string scopes_supported = 5;
+ case 5: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 42) goto handle_unusual;
+ do {
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.scopes_supported");
+ object = msg->add_scopes_supported();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ if (ptr >= end) break;
+ } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 42 && (ptr += 1));
+ break;
+ }
+ // repeated string token_endpoint_auth_methods_supported = 6;
+ case 6: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 50) goto handle_unusual;
+ do {
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported");
+ object = msg->add_token_endpoint_auth_methods_supported();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ if (ptr >= end) break;
+ } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 50 && (ptr += 1));
+ break;
+ }
+ // string jwks_uri = 7;
+ case 7: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 58) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.jwks_uri");
+ object = msg->mutable_jwks_uri();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // repeated string code_challenge_methods_supported = 8;
+ case 8: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 66) goto handle_unusual;
+ do {
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported");
+ object = msg->add_code_challenge_methods_supported();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ if (ptr >= end) break;
+ } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 66 && (ptr += 1));
+ break;
+ }
+ // repeated string grant_types_supported = 9;
+ case 9: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 74) goto handle_unusual;
+ do {
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.OAuth2MetadataResponse.grant_types_supported");
+ object = msg->add_grant_types_supported();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ if (ptr >= end) break;
+ } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 74 && (ptr += 1));
+ break;
+ }
+ default: {
+ handle_unusual:
+ if ((tag & 7) == 4 || tag == 0) {
+ ctx->EndGroup(tag);
+ return ptr;
+ }
+ auto res = UnknownFieldParse(tag, {_InternalParse, msg},
+ ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx);
+ ptr = res.first;
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr);
+ if (res.second) return ptr;
+ }
+ } // switch
+ } // while
+ return ptr;
+string_till_end:
+ static_cast<::std::string*>(object)->clear();
+ static_cast<::std::string*>(object)->reserve(size);
+ goto len_delim_till_end;
+len_delim_till_end:
+ return ctx->StoreAndTailCall(ptr, end, {_InternalParse, msg},
+ {parser_till_end, object}, size);
+}
+#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool OAuth2MetadataResponse::MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+ ::google::protobuf::uint32 tag;
+ // @@protoc_insertion_point(parse_start:flyteidl.service.OAuth2MetadataResponse)
+ for (;;) {
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ tag = p.first;
+ if (!p.second) goto handle_unusual;
+ switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
+ // string issuer = 1;
+ case 1: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (10 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_issuer()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->issuer().data(), static_cast(this->issuer().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.issuer"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string authorization_endpoint = 2;
+ case 2: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (18 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_authorization_endpoint()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->authorization_endpoint().data(), static_cast(this->authorization_endpoint().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.authorization_endpoint"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string token_endpoint = 3;
+ case 3: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (26 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_token_endpoint()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->token_endpoint().data(), static_cast(this->token_endpoint().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.token_endpoint"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // repeated string response_types_supported = 4;
+ case 4: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (34 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->add_response_types_supported()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->response_types_supported(this->response_types_supported_size() - 1).data(),
+ static_cast(this->response_types_supported(this->response_types_supported_size() - 1).length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.response_types_supported"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // repeated string scopes_supported = 5;
+ case 5: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (42 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->add_scopes_supported()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->scopes_supported(this->scopes_supported_size() - 1).data(),
+ static_cast(this->scopes_supported(this->scopes_supported_size() - 1).length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.scopes_supported"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // repeated string token_endpoint_auth_methods_supported = 6;
+ case 6: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (50 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->add_token_endpoint_auth_methods_supported()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->token_endpoint_auth_methods_supported(this->token_endpoint_auth_methods_supported_size() - 1).data(),
+ static_cast(this->token_endpoint_auth_methods_supported(this->token_endpoint_auth_methods_supported_size() - 1).length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string jwks_uri = 7;
+ case 7: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (58 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_jwks_uri()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->jwks_uri().data(), static_cast(this->jwks_uri().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.jwks_uri"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // repeated string code_challenge_methods_supported = 8;
+ case 8: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (66 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->add_code_challenge_methods_supported()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->code_challenge_methods_supported(this->code_challenge_methods_supported_size() - 1).data(),
+ static_cast(this->code_challenge_methods_supported(this->code_challenge_methods_supported_size() - 1).length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // repeated string grant_types_supported = 9;
+ case 9: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (74 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->add_grant_types_supported()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->grant_types_supported(this->grant_types_supported_size() - 1).data(),
+ static_cast(this->grant_types_supported(this->grant_types_supported_size() - 1).length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.OAuth2MetadataResponse.grant_types_supported"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ default: {
+ handle_unusual:
+ if (tag == 0) {
+ goto success;
+ }
+ DO_(::google::protobuf::internal::WireFormat::SkipField(
+ input, tag, _internal_metadata_.mutable_unknown_fields()));
+ break;
+ }
+ }
+ }
+success:
+ // @@protoc_insertion_point(parse_success:flyteidl.service.OAuth2MetadataResponse)
+ return true;
+failure:
+ // @@protoc_insertion_point(parse_failure:flyteidl.service.OAuth2MetadataResponse)
+ return false;
+#undef DO_
+}
+#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void OAuth2MetadataResponse::SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const {
+ // @@protoc_insertion_point(serialize_start:flyteidl.service.OAuth2MetadataResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ // string issuer = 1;
+ if (this->issuer().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->issuer().data(), static_cast(this->issuer().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.issuer");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 1, this->issuer(), output);
+ }
+
+ // string authorization_endpoint = 2;
+ if (this->authorization_endpoint().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->authorization_endpoint().data(), static_cast(this->authorization_endpoint().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.authorization_endpoint");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 2, this->authorization_endpoint(), output);
+ }
+
+ // string token_endpoint = 3;
+ if (this->token_endpoint().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->token_endpoint().data(), static_cast(this->token_endpoint().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.token_endpoint");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 3, this->token_endpoint(), output);
+ }
+
+ // repeated string response_types_supported = 4;
+ for (int i = 0, n = this->response_types_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->response_types_supported(i).data(), static_cast(this->response_types_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.response_types_supported");
+ ::google::protobuf::internal::WireFormatLite::WriteString(
+ 4, this->response_types_supported(i), output);
+ }
+
+ // repeated string scopes_supported = 5;
+ for (int i = 0, n = this->scopes_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->scopes_supported(i).data(), static_cast(this->scopes_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.scopes_supported");
+ ::google::protobuf::internal::WireFormatLite::WriteString(
+ 5, this->scopes_supported(i), output);
+ }
+
+ // repeated string token_endpoint_auth_methods_supported = 6;
+ for (int i = 0, n = this->token_endpoint_auth_methods_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->token_endpoint_auth_methods_supported(i).data(), static_cast(this->token_endpoint_auth_methods_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported");
+ ::google::protobuf::internal::WireFormatLite::WriteString(
+ 6, this->token_endpoint_auth_methods_supported(i), output);
+ }
+
+ // string jwks_uri = 7;
+ if (this->jwks_uri().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->jwks_uri().data(), static_cast(this->jwks_uri().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.jwks_uri");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 7, this->jwks_uri(), output);
+ }
+
+ // repeated string code_challenge_methods_supported = 8;
+ for (int i = 0, n = this->code_challenge_methods_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->code_challenge_methods_supported(i).data(), static_cast(this->code_challenge_methods_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported");
+ ::google::protobuf::internal::WireFormatLite::WriteString(
+ 8, this->code_challenge_methods_supported(i), output);
+ }
+
+ // repeated string grant_types_supported = 9;
+ for (int i = 0, n = this->grant_types_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->grant_types_supported(i).data(), static_cast(this->grant_types_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.grant_types_supported");
+ ::google::protobuf::internal::WireFormatLite::WriteString(
+ 9, this->grant_types_supported(i), output);
+ }
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
+ _internal_metadata_.unknown_fields(), output);
+ }
+ // @@protoc_insertion_point(serialize_end:flyteidl.service.OAuth2MetadataResponse)
+}
+
+::google::protobuf::uint8* OAuth2MetadataResponse::InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const {
+ // @@protoc_insertion_point(serialize_to_array_start:flyteidl.service.OAuth2MetadataResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ // string issuer = 1;
+ if (this->issuer().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->issuer().data(), static_cast(this->issuer().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.issuer");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 1, this->issuer(), target);
+ }
+
+ // string authorization_endpoint = 2;
+ if (this->authorization_endpoint().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->authorization_endpoint().data(), static_cast(this->authorization_endpoint().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.authorization_endpoint");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 2, this->authorization_endpoint(), target);
+ }
+
+ // string token_endpoint = 3;
+ if (this->token_endpoint().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->token_endpoint().data(), static_cast(this->token_endpoint().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.token_endpoint");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 3, this->token_endpoint(), target);
+ }
+
+ // repeated string response_types_supported = 4;
+ for (int i = 0, n = this->response_types_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->response_types_supported(i).data(), static_cast(this->response_types_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.response_types_supported");
+ target = ::google::protobuf::internal::WireFormatLite::
+ WriteStringToArray(4, this->response_types_supported(i), target);
+ }
+
+ // repeated string scopes_supported = 5;
+ for (int i = 0, n = this->scopes_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->scopes_supported(i).data(), static_cast(this->scopes_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.scopes_supported");
+ target = ::google::protobuf::internal::WireFormatLite::
+ WriteStringToArray(5, this->scopes_supported(i), target);
+ }
+
+ // repeated string token_endpoint_auth_methods_supported = 6;
+ for (int i = 0, n = this->token_endpoint_auth_methods_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->token_endpoint_auth_methods_supported(i).data(), static_cast(this->token_endpoint_auth_methods_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported");
+ target = ::google::protobuf::internal::WireFormatLite::
+ WriteStringToArray(6, this->token_endpoint_auth_methods_supported(i), target);
+ }
+
+ // string jwks_uri = 7;
+ if (this->jwks_uri().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->jwks_uri().data(), static_cast(this->jwks_uri().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.jwks_uri");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 7, this->jwks_uri(), target);
+ }
+
+ // repeated string code_challenge_methods_supported = 8;
+ for (int i = 0, n = this->code_challenge_methods_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->code_challenge_methods_supported(i).data(), static_cast(this->code_challenge_methods_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported");
+ target = ::google::protobuf::internal::WireFormatLite::
+ WriteStringToArray(8, this->code_challenge_methods_supported(i), target);
+ }
+
+ // repeated string grant_types_supported = 9;
+ for (int i = 0, n = this->grant_types_supported_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->grant_types_supported(i).data(), static_cast(this->grant_types_supported(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.OAuth2MetadataResponse.grant_types_supported");
+ target = ::google::protobuf::internal::WireFormatLite::
+ WriteStringToArray(9, this->grant_types_supported(i), target);
+ }
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
+ _internal_metadata_.unknown_fields(), target);
+ }
+ // @@protoc_insertion_point(serialize_to_array_end:flyteidl.service.OAuth2MetadataResponse)
+ return target;
+}
+
+size_t OAuth2MetadataResponse::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:flyteidl.service.OAuth2MetadataResponse)
+ size_t total_size = 0;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ total_size +=
+ ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
+ _internal_metadata_.unknown_fields());
+ }
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ // repeated string response_types_supported = 4;
+ total_size += 1 *
+ ::google::protobuf::internal::FromIntSize(this->response_types_supported_size());
+ for (int i = 0, n = this->response_types_supported_size(); i < n; i++) {
+ total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->response_types_supported(i));
+ }
+
+ // repeated string scopes_supported = 5;
+ total_size += 1 *
+ ::google::protobuf::internal::FromIntSize(this->scopes_supported_size());
+ for (int i = 0, n = this->scopes_supported_size(); i < n; i++) {
+ total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->scopes_supported(i));
+ }
+
+ // repeated string token_endpoint_auth_methods_supported = 6;
+ total_size += 1 *
+ ::google::protobuf::internal::FromIntSize(this->token_endpoint_auth_methods_supported_size());
+ for (int i = 0, n = this->token_endpoint_auth_methods_supported_size(); i < n; i++) {
+ total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->token_endpoint_auth_methods_supported(i));
+ }
+
+ // repeated string code_challenge_methods_supported = 8;
+ total_size += 1 *
+ ::google::protobuf::internal::FromIntSize(this->code_challenge_methods_supported_size());
+ for (int i = 0, n = this->code_challenge_methods_supported_size(); i < n; i++) {
+ total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->code_challenge_methods_supported(i));
+ }
+
+ // repeated string grant_types_supported = 9;
+ total_size += 1 *
+ ::google::protobuf::internal::FromIntSize(this->grant_types_supported_size());
+ for (int i = 0, n = this->grant_types_supported_size(); i < n; i++) {
+ total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->grant_types_supported(i));
+ }
+
+ // string issuer = 1;
+ if (this->issuer().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->issuer());
+ }
+
+ // string authorization_endpoint = 2;
+ if (this->authorization_endpoint().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->authorization_endpoint());
+ }
+
+ // string token_endpoint = 3;
+ if (this->token_endpoint().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->token_endpoint());
+ }
+
+ // string jwks_uri = 7;
+ if (this->jwks_uri().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->jwks_uri());
+ }
+
+ int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
+ SetCachedSize(cached_size);
+ return total_size;
+}
+
+void OAuth2MetadataResponse::MergeFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:flyteidl.service.OAuth2MetadataResponse)
+ GOOGLE_DCHECK_NE(&from, this);
+ const OAuth2MetadataResponse* source =
+ ::google::protobuf::DynamicCastToGenerated(
+ &from);
+ if (source == nullptr) {
+ // @@protoc_insertion_point(generalized_merge_from_cast_fail:flyteidl.service.OAuth2MetadataResponse)
+ ::google::protobuf::internal::ReflectionOps::Merge(from, this);
+ } else {
+ // @@protoc_insertion_point(generalized_merge_from_cast_success:flyteidl.service.OAuth2MetadataResponse)
+ MergeFrom(*source);
+ }
+}
+
+void OAuth2MetadataResponse::MergeFrom(const OAuth2MetadataResponse& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:flyteidl.service.OAuth2MetadataResponse)
+ GOOGLE_DCHECK_NE(&from, this);
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ response_types_supported_.MergeFrom(from.response_types_supported_);
+ scopes_supported_.MergeFrom(from.scopes_supported_);
+ token_endpoint_auth_methods_supported_.MergeFrom(from.token_endpoint_auth_methods_supported_);
+ code_challenge_methods_supported_.MergeFrom(from.code_challenge_methods_supported_);
+ grant_types_supported_.MergeFrom(from.grant_types_supported_);
+ if (from.issuer().size() > 0) {
+
+ issuer_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.issuer_);
+ }
+ if (from.authorization_endpoint().size() > 0) {
+
+ authorization_endpoint_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.authorization_endpoint_);
+ }
+ if (from.token_endpoint().size() > 0) {
+
+ token_endpoint_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.token_endpoint_);
+ }
+ if (from.jwks_uri().size() > 0) {
+
+ jwks_uri_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.jwks_uri_);
+ }
+}
+
+void OAuth2MetadataResponse::CopyFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:flyteidl.service.OAuth2MetadataResponse)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+void OAuth2MetadataResponse::CopyFrom(const OAuth2MetadataResponse& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:flyteidl.service.OAuth2MetadataResponse)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+bool OAuth2MetadataResponse::IsInitialized() const {
+ return true;
+}
+
+void OAuth2MetadataResponse::Swap(OAuth2MetadataResponse* other) {
+ if (other == this) return;
+ InternalSwap(other);
+}
+void OAuth2MetadataResponse::InternalSwap(OAuth2MetadataResponse* other) {
+ using std::swap;
+ _internal_metadata_.Swap(&other->_internal_metadata_);
+ response_types_supported_.InternalSwap(CastToBase(&other->response_types_supported_));
+ scopes_supported_.InternalSwap(CastToBase(&other->scopes_supported_));
+ token_endpoint_auth_methods_supported_.InternalSwap(CastToBase(&other->token_endpoint_auth_methods_supported_));
+ code_challenge_methods_supported_.InternalSwap(CastToBase(&other->code_challenge_methods_supported_));
+ grant_types_supported_.InternalSwap(CastToBase(&other->grant_types_supported_));
+ issuer_.Swap(&other->issuer_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ authorization_endpoint_.Swap(&other->authorization_endpoint_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ token_endpoint_.Swap(&other->token_endpoint_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ jwks_uri_.Swap(&other->jwks_uri_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+}
+
+::google::protobuf::Metadata OAuth2MetadataResponse::GetMetadata() const {
+ ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fservice_2fauth_2eproto);
+ return ::file_level_metadata_flyteidl_2fservice_2fauth_2eproto[kIndexInFileMessages];
+}
+
+
+// ===================================================================
+
+void PublicClientAuthConfigRequest::InitAsDefaultInstance() {
+}
+class PublicClientAuthConfigRequest::HasBitSetters {
+ public:
+};
+
+#if !defined(_MSC_VER) || _MSC_VER >= 1900
+#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
+
+PublicClientAuthConfigRequest::PublicClientAuthConfigRequest()
+ : ::google::protobuf::Message(), _internal_metadata_(nullptr) {
+ SharedCtor();
+ // @@protoc_insertion_point(constructor:flyteidl.service.PublicClientAuthConfigRequest)
+}
+PublicClientAuthConfigRequest::PublicClientAuthConfigRequest(const PublicClientAuthConfigRequest& from)
+ : ::google::protobuf::Message(),
+ _internal_metadata_(nullptr) {
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ // @@protoc_insertion_point(copy_constructor:flyteidl.service.PublicClientAuthConfigRequest)
+}
+
+void PublicClientAuthConfigRequest::SharedCtor() {
+}
+
+PublicClientAuthConfigRequest::~PublicClientAuthConfigRequest() {
+ // @@protoc_insertion_point(destructor:flyteidl.service.PublicClientAuthConfigRequest)
+ SharedDtor();
+}
+
+void PublicClientAuthConfigRequest::SharedDtor() {
+}
+
+void PublicClientAuthConfigRequest::SetCachedSize(int size) const {
+ _cached_size_.Set(size);
+}
+const PublicClientAuthConfigRequest& PublicClientAuthConfigRequest::default_instance() {
+ ::google::protobuf::internal::InitSCC(&::scc_info_PublicClientAuthConfigRequest_flyteidl_2fservice_2fauth_2eproto.base);
+ return *internal_default_instance();
+}
+
+
+void PublicClientAuthConfigRequest::Clear() {
+// @@protoc_insertion_point(message_clear_start:flyteidl.service.PublicClientAuthConfigRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* PublicClientAuthConfigRequest::_InternalParse(const char* begin, const char* end, void* object,
+ ::google::protobuf::internal::ParseContext* ctx) {
+ auto msg = static_cast(object);
+ ::google::protobuf::int32 size; (void)size;
+ int depth; (void)depth;
+ ::google::protobuf::uint32 tag;
+ ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end;
+ auto ptr = begin;
+ while (ptr < end) {
+ ptr = ::google::protobuf::io::Parse32(ptr, &tag);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ switch (tag >> 3) {
+ default: {
+ if ((tag & 7) == 4 || tag == 0) {
+ ctx->EndGroup(tag);
+ return ptr;
+ }
+ auto res = UnknownFieldParse(tag, {_InternalParse, msg},
+ ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx);
+ ptr = res.first;
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr);
+ if (res.second) return ptr;
+ }
+ } // switch
+ } // while
+ return ptr;
+}
+#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool PublicClientAuthConfigRequest::MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+ ::google::protobuf::uint32 tag;
+ // @@protoc_insertion_point(parse_start:flyteidl.service.PublicClientAuthConfigRequest)
+ for (;;) {
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ tag = p.first;
+ if (!p.second) goto handle_unusual;
+ handle_unusual:
+ if (tag == 0) {
+ goto success;
+ }
+ DO_(::google::protobuf::internal::WireFormat::SkipField(
+ input, tag, _internal_metadata_.mutable_unknown_fields()));
+ }
+success:
+ // @@protoc_insertion_point(parse_success:flyteidl.service.PublicClientAuthConfigRequest)
+ return true;
+failure:
+ // @@protoc_insertion_point(parse_failure:flyteidl.service.PublicClientAuthConfigRequest)
+ return false;
+#undef DO_
+}
+#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void PublicClientAuthConfigRequest::SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const {
+ // @@protoc_insertion_point(serialize_start:flyteidl.service.PublicClientAuthConfigRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
+ _internal_metadata_.unknown_fields(), output);
+ }
+ // @@protoc_insertion_point(serialize_end:flyteidl.service.PublicClientAuthConfigRequest)
+}
+
+::google::protobuf::uint8* PublicClientAuthConfigRequest::InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const {
+ // @@protoc_insertion_point(serialize_to_array_start:flyteidl.service.PublicClientAuthConfigRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
+ _internal_metadata_.unknown_fields(), target);
+ }
+ // @@protoc_insertion_point(serialize_to_array_end:flyteidl.service.PublicClientAuthConfigRequest)
+ return target;
+}
+
+size_t PublicClientAuthConfigRequest::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:flyteidl.service.PublicClientAuthConfigRequest)
+ size_t total_size = 0;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ total_size +=
+ ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
+ _internal_metadata_.unknown_fields());
+ }
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
+ SetCachedSize(cached_size);
+ return total_size;
+}
+
+void PublicClientAuthConfigRequest::MergeFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:flyteidl.service.PublicClientAuthConfigRequest)
+ GOOGLE_DCHECK_NE(&from, this);
+ const PublicClientAuthConfigRequest* source =
+ ::google::protobuf::DynamicCastToGenerated(
+ &from);
+ if (source == nullptr) {
+ // @@protoc_insertion_point(generalized_merge_from_cast_fail:flyteidl.service.PublicClientAuthConfigRequest)
+ ::google::protobuf::internal::ReflectionOps::Merge(from, this);
+ } else {
+ // @@protoc_insertion_point(generalized_merge_from_cast_success:flyteidl.service.PublicClientAuthConfigRequest)
+ MergeFrom(*source);
+ }
+}
+
+void PublicClientAuthConfigRequest::MergeFrom(const PublicClientAuthConfigRequest& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:flyteidl.service.PublicClientAuthConfigRequest)
+ GOOGLE_DCHECK_NE(&from, this);
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+}
+
+void PublicClientAuthConfigRequest::CopyFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:flyteidl.service.PublicClientAuthConfigRequest)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+void PublicClientAuthConfigRequest::CopyFrom(const PublicClientAuthConfigRequest& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:flyteidl.service.PublicClientAuthConfigRequest)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+bool PublicClientAuthConfigRequest::IsInitialized() const {
+ return true;
+}
+
+void PublicClientAuthConfigRequest::Swap(PublicClientAuthConfigRequest* other) {
+ if (other == this) return;
+ InternalSwap(other);
+}
+void PublicClientAuthConfigRequest::InternalSwap(PublicClientAuthConfigRequest* other) {
+ using std::swap;
+ _internal_metadata_.Swap(&other->_internal_metadata_);
+}
+
+::google::protobuf::Metadata PublicClientAuthConfigRequest::GetMetadata() const {
+ ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fservice_2fauth_2eproto);
+ return ::file_level_metadata_flyteidl_2fservice_2fauth_2eproto[kIndexInFileMessages];
+}
+
+
+// ===================================================================
+
+void PublicClientAuthConfigResponse::InitAsDefaultInstance() {
+}
+class PublicClientAuthConfigResponse::HasBitSetters {
+ public:
+};
+
+#if !defined(_MSC_VER) || _MSC_VER >= 1900
+const int PublicClientAuthConfigResponse::kClientIdFieldNumber;
+const int PublicClientAuthConfigResponse::kRedirectUriFieldNumber;
+const int PublicClientAuthConfigResponse::kScopesFieldNumber;
+const int PublicClientAuthConfigResponse::kAuthorizationMetadataKeyFieldNumber;
+#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
+
+PublicClientAuthConfigResponse::PublicClientAuthConfigResponse()
+ : ::google::protobuf::Message(), _internal_metadata_(nullptr) {
+ SharedCtor();
+ // @@protoc_insertion_point(constructor:flyteidl.service.PublicClientAuthConfigResponse)
+}
+PublicClientAuthConfigResponse::PublicClientAuthConfigResponse(const PublicClientAuthConfigResponse& from)
+ : ::google::protobuf::Message(),
+ _internal_metadata_(nullptr),
+ scopes_(from.scopes_) {
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ client_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.client_id().size() > 0) {
+ client_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.client_id_);
+ }
+ redirect_uri_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.redirect_uri().size() > 0) {
+ redirect_uri_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.redirect_uri_);
+ }
+ authorization_metadata_key_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.authorization_metadata_key().size() > 0) {
+ authorization_metadata_key_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.authorization_metadata_key_);
+ }
+ // @@protoc_insertion_point(copy_constructor:flyteidl.service.PublicClientAuthConfigResponse)
+}
+
+void PublicClientAuthConfigResponse::SharedCtor() {
+ ::google::protobuf::internal::InitSCC(
+ &scc_info_PublicClientAuthConfigResponse_flyteidl_2fservice_2fauth_2eproto.base);
+ client_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ redirect_uri_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ authorization_metadata_key_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+
+PublicClientAuthConfigResponse::~PublicClientAuthConfigResponse() {
+ // @@protoc_insertion_point(destructor:flyteidl.service.PublicClientAuthConfigResponse)
+ SharedDtor();
+}
+
+void PublicClientAuthConfigResponse::SharedDtor() {
+ client_id_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ redirect_uri_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ authorization_metadata_key_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+
+void PublicClientAuthConfigResponse::SetCachedSize(int size) const {
+ _cached_size_.Set(size);
+}
+const PublicClientAuthConfigResponse& PublicClientAuthConfigResponse::default_instance() {
+ ::google::protobuf::internal::InitSCC(&::scc_info_PublicClientAuthConfigResponse_flyteidl_2fservice_2fauth_2eproto.base);
+ return *internal_default_instance();
+}
+
+
+void PublicClientAuthConfigResponse::Clear() {
+// @@protoc_insertion_point(message_clear_start:flyteidl.service.PublicClientAuthConfigResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ scopes_.Clear();
+ client_id_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ redirect_uri_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ authorization_metadata_key_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* PublicClientAuthConfigResponse::_InternalParse(const char* begin, const char* end, void* object,
+ ::google::protobuf::internal::ParseContext* ctx) {
+ auto msg = static_cast(object);
+ ::google::protobuf::int32 size; (void)size;
+ int depth; (void)depth;
+ ::google::protobuf::uint32 tag;
+ ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end;
+ auto ptr = begin;
+ while (ptr < end) {
+ ptr = ::google::protobuf::io::Parse32(ptr, &tag);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ switch (tag >> 3) {
+ // string client_id = 1;
+ case 1: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 10) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.PublicClientAuthConfigResponse.client_id");
+ object = msg->mutable_client_id();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string redirect_uri = 2;
+ case 2: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 18) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.PublicClientAuthConfigResponse.redirect_uri");
+ object = msg->mutable_redirect_uri();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // repeated string scopes = 3;
+ case 3: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 26) goto handle_unusual;
+ do {
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.PublicClientAuthConfigResponse.scopes");
+ object = msg->add_scopes();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ if (ptr >= end) break;
+ } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 26 && (ptr += 1));
+ break;
+ }
+ // string authorization_metadata_key = 4;
+ case 4: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 34) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key");
+ object = msg->mutable_authorization_metadata_key();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ default: {
+ handle_unusual:
+ if ((tag & 7) == 4 || tag == 0) {
+ ctx->EndGroup(tag);
+ return ptr;
+ }
+ auto res = UnknownFieldParse(tag, {_InternalParse, msg},
+ ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx);
+ ptr = res.first;
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr);
+ if (res.second) return ptr;
+ }
+ } // switch
+ } // while
+ return ptr;
+string_till_end:
+ static_cast<::std::string*>(object)->clear();
+ static_cast<::std::string*>(object)->reserve(size);
+ goto len_delim_till_end;
+len_delim_till_end:
+ return ctx->StoreAndTailCall(ptr, end, {_InternalParse, msg},
+ {parser_till_end, object}, size);
+}
+#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool PublicClientAuthConfigResponse::MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+ ::google::protobuf::uint32 tag;
+ // @@protoc_insertion_point(parse_start:flyteidl.service.PublicClientAuthConfigResponse)
+ for (;;) {
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ tag = p.first;
+ if (!p.second) goto handle_unusual;
+ switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
+ // string client_id = 1;
+ case 1: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (10 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_client_id()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->client_id().data(), static_cast(this->client_id().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.PublicClientAuthConfigResponse.client_id"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string redirect_uri = 2;
+ case 2: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (18 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_redirect_uri()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->redirect_uri().data(), static_cast(this->redirect_uri().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.PublicClientAuthConfigResponse.redirect_uri"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // repeated string scopes = 3;
+ case 3: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (26 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->add_scopes()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->scopes(this->scopes_size() - 1).data(),
+ static_cast(this->scopes(this->scopes_size() - 1).length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.PublicClientAuthConfigResponse.scopes"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string authorization_metadata_key = 4;
+ case 4: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (34 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_authorization_metadata_key()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->authorization_metadata_key().data(), static_cast(this->authorization_metadata_key().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ default: {
+ handle_unusual:
+ if (tag == 0) {
+ goto success;
+ }
+ DO_(::google::protobuf::internal::WireFormat::SkipField(
+ input, tag, _internal_metadata_.mutable_unknown_fields()));
+ break;
+ }
+ }
+ }
+success:
+ // @@protoc_insertion_point(parse_success:flyteidl.service.PublicClientAuthConfigResponse)
+ return true;
+failure:
+ // @@protoc_insertion_point(parse_failure:flyteidl.service.PublicClientAuthConfigResponse)
+ return false;
+#undef DO_
+}
+#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void PublicClientAuthConfigResponse::SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const {
+ // @@protoc_insertion_point(serialize_start:flyteidl.service.PublicClientAuthConfigResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ // string client_id = 1;
+ if (this->client_id().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->client_id().data(), static_cast(this->client_id().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.client_id");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 1, this->client_id(), output);
+ }
+
+ // string redirect_uri = 2;
+ if (this->redirect_uri().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->redirect_uri().data(), static_cast(this->redirect_uri().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.redirect_uri");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 2, this->redirect_uri(), output);
+ }
+
+ // repeated string scopes = 3;
+ for (int i = 0, n = this->scopes_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->scopes(i).data(), static_cast(this->scopes(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.scopes");
+ ::google::protobuf::internal::WireFormatLite::WriteString(
+ 3, this->scopes(i), output);
+ }
+
+ // string authorization_metadata_key = 4;
+ if (this->authorization_metadata_key().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->authorization_metadata_key().data(), static_cast(this->authorization_metadata_key().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 4, this->authorization_metadata_key(), output);
+ }
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
+ _internal_metadata_.unknown_fields(), output);
+ }
+ // @@protoc_insertion_point(serialize_end:flyteidl.service.PublicClientAuthConfigResponse)
+}
+
+::google::protobuf::uint8* PublicClientAuthConfigResponse::InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const {
+ // @@protoc_insertion_point(serialize_to_array_start:flyteidl.service.PublicClientAuthConfigResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ // string client_id = 1;
+ if (this->client_id().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->client_id().data(), static_cast(this->client_id().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.client_id");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 1, this->client_id(), target);
+ }
+
+ // string redirect_uri = 2;
+ if (this->redirect_uri().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->redirect_uri().data(), static_cast(this->redirect_uri().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.redirect_uri");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 2, this->redirect_uri(), target);
+ }
+
+ // repeated string scopes = 3;
+ for (int i = 0, n = this->scopes_size(); i < n; i++) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->scopes(i).data(), static_cast(this->scopes(i).length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.scopes");
+ target = ::google::protobuf::internal::WireFormatLite::
+ WriteStringToArray(3, this->scopes(i), target);
+ }
+
+ // string authorization_metadata_key = 4;
+ if (this->authorization_metadata_key().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->authorization_metadata_key().data(), static_cast(this->authorization_metadata_key().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 4, this->authorization_metadata_key(), target);
+ }
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
+ _internal_metadata_.unknown_fields(), target);
+ }
+ // @@protoc_insertion_point(serialize_to_array_end:flyteidl.service.PublicClientAuthConfigResponse)
+ return target;
+}
+
+size_t PublicClientAuthConfigResponse::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:flyteidl.service.PublicClientAuthConfigResponse)
+ size_t total_size = 0;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ total_size +=
+ ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
+ _internal_metadata_.unknown_fields());
+ }
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ // repeated string scopes = 3;
+ total_size += 1 *
+ ::google::protobuf::internal::FromIntSize(this->scopes_size());
+ for (int i = 0, n = this->scopes_size(); i < n; i++) {
+ total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->scopes(i));
+ }
+
+ // string client_id = 1;
+ if (this->client_id().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->client_id());
+ }
+
+ // string redirect_uri = 2;
+ if (this->redirect_uri().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->redirect_uri());
+ }
+
+ // string authorization_metadata_key = 4;
+ if (this->authorization_metadata_key().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->authorization_metadata_key());
+ }
+
+ int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
+ SetCachedSize(cached_size);
+ return total_size;
+}
+
+void PublicClientAuthConfigResponse::MergeFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:flyteidl.service.PublicClientAuthConfigResponse)
+ GOOGLE_DCHECK_NE(&from, this);
+ const PublicClientAuthConfigResponse* source =
+ ::google::protobuf::DynamicCastToGenerated(
+ &from);
+ if (source == nullptr) {
+ // @@protoc_insertion_point(generalized_merge_from_cast_fail:flyteidl.service.PublicClientAuthConfigResponse)
+ ::google::protobuf::internal::ReflectionOps::Merge(from, this);
+ } else {
+ // @@protoc_insertion_point(generalized_merge_from_cast_success:flyteidl.service.PublicClientAuthConfigResponse)
+ MergeFrom(*source);
+ }
+}
+
+void PublicClientAuthConfigResponse::MergeFrom(const PublicClientAuthConfigResponse& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:flyteidl.service.PublicClientAuthConfigResponse)
+ GOOGLE_DCHECK_NE(&from, this);
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ scopes_.MergeFrom(from.scopes_);
+ if (from.client_id().size() > 0) {
+
+ client_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.client_id_);
+ }
+ if (from.redirect_uri().size() > 0) {
+
+ redirect_uri_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.redirect_uri_);
+ }
+ if (from.authorization_metadata_key().size() > 0) {
+
+ authorization_metadata_key_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.authorization_metadata_key_);
+ }
+}
+
+void PublicClientAuthConfigResponse::CopyFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:flyteidl.service.PublicClientAuthConfigResponse)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+void PublicClientAuthConfigResponse::CopyFrom(const PublicClientAuthConfigResponse& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:flyteidl.service.PublicClientAuthConfigResponse)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+bool PublicClientAuthConfigResponse::IsInitialized() const {
+ return true;
+}
+
+void PublicClientAuthConfigResponse::Swap(PublicClientAuthConfigResponse* other) {
+ if (other == this) return;
+ InternalSwap(other);
+}
+void PublicClientAuthConfigResponse::InternalSwap(PublicClientAuthConfigResponse* other) {
+ using std::swap;
+ _internal_metadata_.Swap(&other->_internal_metadata_);
+ scopes_.InternalSwap(CastToBase(&other->scopes_));
+ client_id_.Swap(&other->client_id_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ redirect_uri_.Swap(&other->redirect_uri_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ authorization_metadata_key_.Swap(&other->authorization_metadata_key_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+}
+
+::google::protobuf::Metadata PublicClientAuthConfigResponse::GetMetadata() const {
+ ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fservice_2fauth_2eproto);
+ return ::file_level_metadata_flyteidl_2fservice_2fauth_2eproto[kIndexInFileMessages];
+}
+
+
+// @@protoc_insertion_point(namespace_scope)
+} // namespace service
+} // namespace flyteidl
+namespace google {
+namespace protobuf {
+template<> PROTOBUF_NOINLINE ::flyteidl::service::OAuth2MetadataRequest* Arena::CreateMaybeMessage< ::flyteidl::service::OAuth2MetadataRequest >(Arena* arena) {
+ return Arena::CreateInternal< ::flyteidl::service::OAuth2MetadataRequest >(arena);
+}
+template<> PROTOBUF_NOINLINE ::flyteidl::service::OAuth2MetadataResponse* Arena::CreateMaybeMessage< ::flyteidl::service::OAuth2MetadataResponse >(Arena* arena) {
+ return Arena::CreateInternal< ::flyteidl::service::OAuth2MetadataResponse >(arena);
+}
+template<> PROTOBUF_NOINLINE ::flyteidl::service::PublicClientAuthConfigRequest* Arena::CreateMaybeMessage< ::flyteidl::service::PublicClientAuthConfigRequest >(Arena* arena) {
+ return Arena::CreateInternal< ::flyteidl::service::PublicClientAuthConfigRequest >(arena);
+}
+template<> PROTOBUF_NOINLINE ::flyteidl::service::PublicClientAuthConfigResponse* Arena::CreateMaybeMessage< ::flyteidl::service::PublicClientAuthConfigResponse >(Arena* arena) {
+ return Arena::CreateInternal< ::flyteidl::service::PublicClientAuthConfigResponse >(arena);
+}
+} // namespace protobuf
+} // namespace google
+
+// @@protoc_insertion_point(global_scope)
+#include
diff --git a/flyteidl/gen/pb-cpp/flyteidl/service/auth.pb.h b/flyteidl/gen/pb-cpp/flyteidl/service/auth.pb.h
new file mode 100644
index 0000000000..d0b3629271
--- /dev/null
+++ b/flyteidl/gen/pb-cpp/flyteidl/service/auth.pb.h
@@ -0,0 +1,1582 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: flyteidl/service/auth.proto
+
+#ifndef PROTOBUF_INCLUDED_flyteidl_2fservice_2fauth_2eproto
+#define PROTOBUF_INCLUDED_flyteidl_2fservice_2fauth_2eproto
+
+#include
+#include
+
+#include
+#if PROTOBUF_VERSION < 3007000
+#error This file was generated by a newer version of protoc which is
+#error incompatible with your Protocol Buffer headers. Please update
+#error your headers.
+#endif
+#if 3007000 < PROTOBUF_MIN_PROTOC_VERSION
+#error This file was generated by an older version of protoc which is
+#error incompatible with your Protocol Buffer headers. Please
+#error regenerate this file with a newer version of protoc.
+#endif
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include // IWYU pragma: export
+#include // IWYU pragma: export
+#include
+#include "google/api/annotations.pb.h"
+#include "flyteidl/admin/project.pb.h"
+#include "flyteidl/admin/project_domain_attributes.pb.h"
+#include "flyteidl/admin/task.pb.h"
+#include "flyteidl/admin/workflow.pb.h"
+#include "flyteidl/admin/workflow_attributes.pb.h"
+#include "flyteidl/admin/launch_plan.pb.h"
+#include "flyteidl/admin/event.pb.h"
+#include "flyteidl/admin/execution.pb.h"
+#include "flyteidl/admin/matchable_resource.pb.h"
+#include "flyteidl/admin/node_execution.pb.h"
+#include "flyteidl/admin/task_execution.pb.h"
+#include "flyteidl/admin/version.pb.h"
+#include "flyteidl/admin/common.pb.h"
+#include "protoc-gen-swagger/options/annotations.pb.h"
+// @@protoc_insertion_point(includes)
+#include
+#define PROTOBUF_INTERNAL_EXPORT_flyteidl_2fservice_2fauth_2eproto
+
+// Internal implementation detail -- do not use these members.
+struct TableStruct_flyteidl_2fservice_2fauth_2eproto {
+ static const ::google::protobuf::internal::ParseTableField entries[]
+ PROTOBUF_SECTION_VARIABLE(protodesc_cold);
+ static const ::google::protobuf::internal::AuxillaryParseTableField aux[]
+ PROTOBUF_SECTION_VARIABLE(protodesc_cold);
+ static const ::google::protobuf::internal::ParseTable schema[4]
+ PROTOBUF_SECTION_VARIABLE(protodesc_cold);
+ static const ::google::protobuf::internal::FieldMetadata field_metadata[];
+ static const ::google::protobuf::internal::SerializationTable serialization_table[];
+ static const ::google::protobuf::uint32 offsets[];
+};
+void AddDescriptors_flyteidl_2fservice_2fauth_2eproto();
+namespace flyteidl {
+namespace service {
+class OAuth2MetadataRequest;
+class OAuth2MetadataRequestDefaultTypeInternal;
+extern OAuth2MetadataRequestDefaultTypeInternal _OAuth2MetadataRequest_default_instance_;
+class OAuth2MetadataResponse;
+class OAuth2MetadataResponseDefaultTypeInternal;
+extern OAuth2MetadataResponseDefaultTypeInternal _OAuth2MetadataResponse_default_instance_;
+class PublicClientAuthConfigRequest;
+class PublicClientAuthConfigRequestDefaultTypeInternal;
+extern PublicClientAuthConfigRequestDefaultTypeInternal _PublicClientAuthConfigRequest_default_instance_;
+class PublicClientAuthConfigResponse;
+class PublicClientAuthConfigResponseDefaultTypeInternal;
+extern PublicClientAuthConfigResponseDefaultTypeInternal _PublicClientAuthConfigResponse_default_instance_;
+} // namespace service
+} // namespace flyteidl
+namespace google {
+namespace protobuf {
+template<> ::flyteidl::service::OAuth2MetadataRequest* Arena::CreateMaybeMessage<::flyteidl::service::OAuth2MetadataRequest>(Arena*);
+template<> ::flyteidl::service::OAuth2MetadataResponse* Arena::CreateMaybeMessage<::flyteidl::service::OAuth2MetadataResponse>(Arena*);
+template<> ::flyteidl::service::PublicClientAuthConfigRequest* Arena::CreateMaybeMessage<::flyteidl::service::PublicClientAuthConfigRequest>(Arena*);
+template<> ::flyteidl::service::PublicClientAuthConfigResponse* Arena::CreateMaybeMessage<::flyteidl::service::PublicClientAuthConfigResponse>(Arena*);
+} // namespace protobuf
+} // namespace google
+namespace flyteidl {
+namespace service {
+
+// ===================================================================
+
+class OAuth2MetadataRequest final :
+ public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:flyteidl.service.OAuth2MetadataRequest) */ {
+ public:
+ OAuth2MetadataRequest();
+ virtual ~OAuth2MetadataRequest();
+
+ OAuth2MetadataRequest(const OAuth2MetadataRequest& from);
+
+ inline OAuth2MetadataRequest& operator=(const OAuth2MetadataRequest& from) {
+ CopyFrom(from);
+ return *this;
+ }
+ #if LANG_CXX11
+ OAuth2MetadataRequest(OAuth2MetadataRequest&& from) noexcept
+ : OAuth2MetadataRequest() {
+ *this = ::std::move(from);
+ }
+
+ inline OAuth2MetadataRequest& operator=(OAuth2MetadataRequest&& from) noexcept {
+ if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
+ if (this != &from) InternalSwap(&from);
+ } else {
+ CopyFrom(from);
+ }
+ return *this;
+ }
+ #endif
+ static const ::google::protobuf::Descriptor* descriptor() {
+ return default_instance().GetDescriptor();
+ }
+ static const OAuth2MetadataRequest& default_instance();
+
+ static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
+ static inline const OAuth2MetadataRequest* internal_default_instance() {
+ return reinterpret_cast(
+ &_OAuth2MetadataRequest_default_instance_);
+ }
+ static constexpr int kIndexInFileMessages =
+ 0;
+
+ void Swap(OAuth2MetadataRequest* other);
+ friend void swap(OAuth2MetadataRequest& a, OAuth2MetadataRequest& b) {
+ a.Swap(&b);
+ }
+
+ // implements Message ----------------------------------------------
+
+ inline OAuth2MetadataRequest* New() const final {
+ return CreateMaybeMessage(nullptr);
+ }
+
+ OAuth2MetadataRequest* New(::google::protobuf::Arena* arena) const final {
+ return CreateMaybeMessage(arena);
+ }
+ void CopyFrom(const ::google::protobuf::Message& from) final;
+ void MergeFrom(const ::google::protobuf::Message& from) final;
+ void CopyFrom(const OAuth2MetadataRequest& from);
+ void MergeFrom(const OAuth2MetadataRequest& from);
+ PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
+ bool IsInitialized() const final;
+
+ size_t ByteSizeLong() const final;
+ #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ static const char* _InternalParse(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx);
+ ::google::protobuf::internal::ParseFunc _ParseFunc() const final { return _InternalParse; }
+ #else
+ bool MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) final;
+ #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ void SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const final;
+ ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const final;
+ int GetCachedSize() const final { return _cached_size_.Get(); }
+
+ private:
+ void SharedCtor();
+ void SharedDtor();
+ void SetCachedSize(int size) const final;
+ void InternalSwap(OAuth2MetadataRequest* other);
+ private:
+ inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
+ return nullptr;
+ }
+ inline void* MaybeArenaPtr() const {
+ return nullptr;
+ }
+ public:
+
+ ::google::protobuf::Metadata GetMetadata() const final;
+
+ // nested types ----------------------------------------------------
+
+ // accessors -------------------------------------------------------
+
+ // @@protoc_insertion_point(class_scope:flyteidl.service.OAuth2MetadataRequest)
+ private:
+ class HasBitSetters;
+
+ ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
+ mutable ::google::protobuf::internal::CachedSize _cached_size_;
+ friend struct ::TableStruct_flyteidl_2fservice_2fauth_2eproto;
+};
+// -------------------------------------------------------------------
+
+class OAuth2MetadataResponse final :
+ public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:flyteidl.service.OAuth2MetadataResponse) */ {
+ public:
+ OAuth2MetadataResponse();
+ virtual ~OAuth2MetadataResponse();
+
+ OAuth2MetadataResponse(const OAuth2MetadataResponse& from);
+
+ inline OAuth2MetadataResponse& operator=(const OAuth2MetadataResponse& from) {
+ CopyFrom(from);
+ return *this;
+ }
+ #if LANG_CXX11
+ OAuth2MetadataResponse(OAuth2MetadataResponse&& from) noexcept
+ : OAuth2MetadataResponse() {
+ *this = ::std::move(from);
+ }
+
+ inline OAuth2MetadataResponse& operator=(OAuth2MetadataResponse&& from) noexcept {
+ if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
+ if (this != &from) InternalSwap(&from);
+ } else {
+ CopyFrom(from);
+ }
+ return *this;
+ }
+ #endif
+ static const ::google::protobuf::Descriptor* descriptor() {
+ return default_instance().GetDescriptor();
+ }
+ static const OAuth2MetadataResponse& default_instance();
+
+ static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
+ static inline const OAuth2MetadataResponse* internal_default_instance() {
+ return reinterpret_cast(
+ &_OAuth2MetadataResponse_default_instance_);
+ }
+ static constexpr int kIndexInFileMessages =
+ 1;
+
+ void Swap(OAuth2MetadataResponse* other);
+ friend void swap(OAuth2MetadataResponse& a, OAuth2MetadataResponse& b) {
+ a.Swap(&b);
+ }
+
+ // implements Message ----------------------------------------------
+
+ inline OAuth2MetadataResponse* New() const final {
+ return CreateMaybeMessage(nullptr);
+ }
+
+ OAuth2MetadataResponse* New(::google::protobuf::Arena* arena) const final {
+ return CreateMaybeMessage(arena);
+ }
+ void CopyFrom(const ::google::protobuf::Message& from) final;
+ void MergeFrom(const ::google::protobuf::Message& from) final;
+ void CopyFrom(const OAuth2MetadataResponse& from);
+ void MergeFrom(const OAuth2MetadataResponse& from);
+ PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
+ bool IsInitialized() const final;
+
+ size_t ByteSizeLong() const final;
+ #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ static const char* _InternalParse(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx);
+ ::google::protobuf::internal::ParseFunc _ParseFunc() const final { return _InternalParse; }
+ #else
+ bool MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) final;
+ #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ void SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const final;
+ ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const final;
+ int GetCachedSize() const final { return _cached_size_.Get(); }
+
+ private:
+ void SharedCtor();
+ void SharedDtor();
+ void SetCachedSize(int size) const final;
+ void InternalSwap(OAuth2MetadataResponse* other);
+ private:
+ inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
+ return nullptr;
+ }
+ inline void* MaybeArenaPtr() const {
+ return nullptr;
+ }
+ public:
+
+ ::google::protobuf::Metadata GetMetadata() const final;
+
+ // nested types ----------------------------------------------------
+
+ // accessors -------------------------------------------------------
+
+ // repeated string response_types_supported = 4;
+ int response_types_supported_size() const;
+ void clear_response_types_supported();
+ static const int kResponseTypesSupportedFieldNumber = 4;
+ const ::std::string& response_types_supported(int index) const;
+ ::std::string* mutable_response_types_supported(int index);
+ void set_response_types_supported(int index, const ::std::string& value);
+ #if LANG_CXX11
+ void set_response_types_supported(int index, ::std::string&& value);
+ #endif
+ void set_response_types_supported(int index, const char* value);
+ void set_response_types_supported(int index, const char* value, size_t size);
+ ::std::string* add_response_types_supported();
+ void add_response_types_supported(const ::std::string& value);
+ #if LANG_CXX11
+ void add_response_types_supported(::std::string&& value);
+ #endif
+ void add_response_types_supported(const char* value);
+ void add_response_types_supported(const char* value, size_t size);
+ const ::google::protobuf::RepeatedPtrField<::std::string>& response_types_supported() const;
+ ::google::protobuf::RepeatedPtrField<::std::string>* mutable_response_types_supported();
+
+ // repeated string scopes_supported = 5;
+ int scopes_supported_size() const;
+ void clear_scopes_supported();
+ static const int kScopesSupportedFieldNumber = 5;
+ const ::std::string& scopes_supported(int index) const;
+ ::std::string* mutable_scopes_supported(int index);
+ void set_scopes_supported(int index, const ::std::string& value);
+ #if LANG_CXX11
+ void set_scopes_supported(int index, ::std::string&& value);
+ #endif
+ void set_scopes_supported(int index, const char* value);
+ void set_scopes_supported(int index, const char* value, size_t size);
+ ::std::string* add_scopes_supported();
+ void add_scopes_supported(const ::std::string& value);
+ #if LANG_CXX11
+ void add_scopes_supported(::std::string&& value);
+ #endif
+ void add_scopes_supported(const char* value);
+ void add_scopes_supported(const char* value, size_t size);
+ const ::google::protobuf::RepeatedPtrField<::std::string>& scopes_supported() const;
+ ::google::protobuf::RepeatedPtrField<::std::string>* mutable_scopes_supported();
+
+ // repeated string token_endpoint_auth_methods_supported = 6;
+ int token_endpoint_auth_methods_supported_size() const;
+ void clear_token_endpoint_auth_methods_supported();
+ static const int kTokenEndpointAuthMethodsSupportedFieldNumber = 6;
+ const ::std::string& token_endpoint_auth_methods_supported(int index) const;
+ ::std::string* mutable_token_endpoint_auth_methods_supported(int index);
+ void set_token_endpoint_auth_methods_supported(int index, const ::std::string& value);
+ #if LANG_CXX11
+ void set_token_endpoint_auth_methods_supported(int index, ::std::string&& value);
+ #endif
+ void set_token_endpoint_auth_methods_supported(int index, const char* value);
+ void set_token_endpoint_auth_methods_supported(int index, const char* value, size_t size);
+ ::std::string* add_token_endpoint_auth_methods_supported();
+ void add_token_endpoint_auth_methods_supported(const ::std::string& value);
+ #if LANG_CXX11
+ void add_token_endpoint_auth_methods_supported(::std::string&& value);
+ #endif
+ void add_token_endpoint_auth_methods_supported(const char* value);
+ void add_token_endpoint_auth_methods_supported(const char* value, size_t size);
+ const ::google::protobuf::RepeatedPtrField<::std::string>& token_endpoint_auth_methods_supported() const;
+ ::google::protobuf::RepeatedPtrField<::std::string>* mutable_token_endpoint_auth_methods_supported();
+
+ // repeated string code_challenge_methods_supported = 8;
+ int code_challenge_methods_supported_size() const;
+ void clear_code_challenge_methods_supported();
+ static const int kCodeChallengeMethodsSupportedFieldNumber = 8;
+ const ::std::string& code_challenge_methods_supported(int index) const;
+ ::std::string* mutable_code_challenge_methods_supported(int index);
+ void set_code_challenge_methods_supported(int index, const ::std::string& value);
+ #if LANG_CXX11
+ void set_code_challenge_methods_supported(int index, ::std::string&& value);
+ #endif
+ void set_code_challenge_methods_supported(int index, const char* value);
+ void set_code_challenge_methods_supported(int index, const char* value, size_t size);
+ ::std::string* add_code_challenge_methods_supported();
+ void add_code_challenge_methods_supported(const ::std::string& value);
+ #if LANG_CXX11
+ void add_code_challenge_methods_supported(::std::string&& value);
+ #endif
+ void add_code_challenge_methods_supported(const char* value);
+ void add_code_challenge_methods_supported(const char* value, size_t size);
+ const ::google::protobuf::RepeatedPtrField<::std::string>& code_challenge_methods_supported() const;
+ ::google::protobuf::RepeatedPtrField<::std::string>* mutable_code_challenge_methods_supported();
+
+ // repeated string grant_types_supported = 9;
+ int grant_types_supported_size() const;
+ void clear_grant_types_supported();
+ static const int kGrantTypesSupportedFieldNumber = 9;
+ const ::std::string& grant_types_supported(int index) const;
+ ::std::string* mutable_grant_types_supported(int index);
+ void set_grant_types_supported(int index, const ::std::string& value);
+ #if LANG_CXX11
+ void set_grant_types_supported(int index, ::std::string&& value);
+ #endif
+ void set_grant_types_supported(int index, const char* value);
+ void set_grant_types_supported(int index, const char* value, size_t size);
+ ::std::string* add_grant_types_supported();
+ void add_grant_types_supported(const ::std::string& value);
+ #if LANG_CXX11
+ void add_grant_types_supported(::std::string&& value);
+ #endif
+ void add_grant_types_supported(const char* value);
+ void add_grant_types_supported(const char* value, size_t size);
+ const ::google::protobuf::RepeatedPtrField<::std::string>& grant_types_supported() const;
+ ::google::protobuf::RepeatedPtrField<::std::string>* mutable_grant_types_supported();
+
+ // string issuer = 1;
+ void clear_issuer();
+ static const int kIssuerFieldNumber = 1;
+ const ::std::string& issuer() const;
+ void set_issuer(const ::std::string& value);
+ #if LANG_CXX11
+ void set_issuer(::std::string&& value);
+ #endif
+ void set_issuer(const char* value);
+ void set_issuer(const char* value, size_t size);
+ ::std::string* mutable_issuer();
+ ::std::string* release_issuer();
+ void set_allocated_issuer(::std::string* issuer);
+
+ // string authorization_endpoint = 2;
+ void clear_authorization_endpoint();
+ static const int kAuthorizationEndpointFieldNumber = 2;
+ const ::std::string& authorization_endpoint() const;
+ void set_authorization_endpoint(const ::std::string& value);
+ #if LANG_CXX11
+ void set_authorization_endpoint(::std::string&& value);
+ #endif
+ void set_authorization_endpoint(const char* value);
+ void set_authorization_endpoint(const char* value, size_t size);
+ ::std::string* mutable_authorization_endpoint();
+ ::std::string* release_authorization_endpoint();
+ void set_allocated_authorization_endpoint(::std::string* authorization_endpoint);
+
+ // string token_endpoint = 3;
+ void clear_token_endpoint();
+ static const int kTokenEndpointFieldNumber = 3;
+ const ::std::string& token_endpoint() const;
+ void set_token_endpoint(const ::std::string& value);
+ #if LANG_CXX11
+ void set_token_endpoint(::std::string&& value);
+ #endif
+ void set_token_endpoint(const char* value);
+ void set_token_endpoint(const char* value, size_t size);
+ ::std::string* mutable_token_endpoint();
+ ::std::string* release_token_endpoint();
+ void set_allocated_token_endpoint(::std::string* token_endpoint);
+
+ // string jwks_uri = 7;
+ void clear_jwks_uri();
+ static const int kJwksUriFieldNumber = 7;
+ const ::std::string& jwks_uri() const;
+ void set_jwks_uri(const ::std::string& value);
+ #if LANG_CXX11
+ void set_jwks_uri(::std::string&& value);
+ #endif
+ void set_jwks_uri(const char* value);
+ void set_jwks_uri(const char* value, size_t size);
+ ::std::string* mutable_jwks_uri();
+ ::std::string* release_jwks_uri();
+ void set_allocated_jwks_uri(::std::string* jwks_uri);
+
+ // @@protoc_insertion_point(class_scope:flyteidl.service.OAuth2MetadataResponse)
+ private:
+ class HasBitSetters;
+
+ ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
+ ::google::protobuf::RepeatedPtrField<::std::string> response_types_supported_;
+ ::google::protobuf::RepeatedPtrField<::std::string> scopes_supported_;
+ ::google::protobuf::RepeatedPtrField<::std::string> token_endpoint_auth_methods_supported_;
+ ::google::protobuf::RepeatedPtrField<::std::string> code_challenge_methods_supported_;
+ ::google::protobuf::RepeatedPtrField<::std::string> grant_types_supported_;
+ ::google::protobuf::internal::ArenaStringPtr issuer_;
+ ::google::protobuf::internal::ArenaStringPtr authorization_endpoint_;
+ ::google::protobuf::internal::ArenaStringPtr token_endpoint_;
+ ::google::protobuf::internal::ArenaStringPtr jwks_uri_;
+ mutable ::google::protobuf::internal::CachedSize _cached_size_;
+ friend struct ::TableStruct_flyteidl_2fservice_2fauth_2eproto;
+};
+// -------------------------------------------------------------------
+
+class PublicClientAuthConfigRequest final :
+ public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:flyteidl.service.PublicClientAuthConfigRequest) */ {
+ public:
+ PublicClientAuthConfigRequest();
+ virtual ~PublicClientAuthConfigRequest();
+
+ PublicClientAuthConfigRequest(const PublicClientAuthConfigRequest& from);
+
+ inline PublicClientAuthConfigRequest& operator=(const PublicClientAuthConfigRequest& from) {
+ CopyFrom(from);
+ return *this;
+ }
+ #if LANG_CXX11
+ PublicClientAuthConfigRequest(PublicClientAuthConfigRequest&& from) noexcept
+ : PublicClientAuthConfigRequest() {
+ *this = ::std::move(from);
+ }
+
+ inline PublicClientAuthConfigRequest& operator=(PublicClientAuthConfigRequest&& from) noexcept {
+ if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
+ if (this != &from) InternalSwap(&from);
+ } else {
+ CopyFrom(from);
+ }
+ return *this;
+ }
+ #endif
+ static const ::google::protobuf::Descriptor* descriptor() {
+ return default_instance().GetDescriptor();
+ }
+ static const PublicClientAuthConfigRequest& default_instance();
+
+ static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
+ static inline const PublicClientAuthConfigRequest* internal_default_instance() {
+ return reinterpret_cast(
+ &_PublicClientAuthConfigRequest_default_instance_);
+ }
+ static constexpr int kIndexInFileMessages =
+ 2;
+
+ void Swap(PublicClientAuthConfigRequest* other);
+ friend void swap(PublicClientAuthConfigRequest& a, PublicClientAuthConfigRequest& b) {
+ a.Swap(&b);
+ }
+
+ // implements Message ----------------------------------------------
+
+ inline PublicClientAuthConfigRequest* New() const final {
+ return CreateMaybeMessage(nullptr);
+ }
+
+ PublicClientAuthConfigRequest* New(::google::protobuf::Arena* arena) const final {
+ return CreateMaybeMessage(arena);
+ }
+ void CopyFrom(const ::google::protobuf::Message& from) final;
+ void MergeFrom(const ::google::protobuf::Message& from) final;
+ void CopyFrom(const PublicClientAuthConfigRequest& from);
+ void MergeFrom(const PublicClientAuthConfigRequest& from);
+ PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
+ bool IsInitialized() const final;
+
+ size_t ByteSizeLong() const final;
+ #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ static const char* _InternalParse(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx);
+ ::google::protobuf::internal::ParseFunc _ParseFunc() const final { return _InternalParse; }
+ #else
+ bool MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) final;
+ #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ void SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const final;
+ ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const final;
+ int GetCachedSize() const final { return _cached_size_.Get(); }
+
+ private:
+ void SharedCtor();
+ void SharedDtor();
+ void SetCachedSize(int size) const final;
+ void InternalSwap(PublicClientAuthConfigRequest* other);
+ private:
+ inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
+ return nullptr;
+ }
+ inline void* MaybeArenaPtr() const {
+ return nullptr;
+ }
+ public:
+
+ ::google::protobuf::Metadata GetMetadata() const final;
+
+ // nested types ----------------------------------------------------
+
+ // accessors -------------------------------------------------------
+
+ // @@protoc_insertion_point(class_scope:flyteidl.service.PublicClientAuthConfigRequest)
+ private:
+ class HasBitSetters;
+
+ ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
+ mutable ::google::protobuf::internal::CachedSize _cached_size_;
+ friend struct ::TableStruct_flyteidl_2fservice_2fauth_2eproto;
+};
+// -------------------------------------------------------------------
+
+class PublicClientAuthConfigResponse final :
+ public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:flyteidl.service.PublicClientAuthConfigResponse) */ {
+ public:
+ PublicClientAuthConfigResponse();
+ virtual ~PublicClientAuthConfigResponse();
+
+ PublicClientAuthConfigResponse(const PublicClientAuthConfigResponse& from);
+
+ inline PublicClientAuthConfigResponse& operator=(const PublicClientAuthConfigResponse& from) {
+ CopyFrom(from);
+ return *this;
+ }
+ #if LANG_CXX11
+ PublicClientAuthConfigResponse(PublicClientAuthConfigResponse&& from) noexcept
+ : PublicClientAuthConfigResponse() {
+ *this = ::std::move(from);
+ }
+
+ inline PublicClientAuthConfigResponse& operator=(PublicClientAuthConfigResponse&& from) noexcept {
+ if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
+ if (this != &from) InternalSwap(&from);
+ } else {
+ CopyFrom(from);
+ }
+ return *this;
+ }
+ #endif
+ static const ::google::protobuf::Descriptor* descriptor() {
+ return default_instance().GetDescriptor();
+ }
+ static const PublicClientAuthConfigResponse& default_instance();
+
+ static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
+ static inline const PublicClientAuthConfigResponse* internal_default_instance() {
+ return reinterpret_cast(
+ &_PublicClientAuthConfigResponse_default_instance_);
+ }
+ static constexpr int kIndexInFileMessages =
+ 3;
+
+ void Swap(PublicClientAuthConfigResponse* other);
+ friend void swap(PublicClientAuthConfigResponse& a, PublicClientAuthConfigResponse& b) {
+ a.Swap(&b);
+ }
+
+ // implements Message ----------------------------------------------
+
+ inline PublicClientAuthConfigResponse* New() const final {
+ return CreateMaybeMessage(nullptr);
+ }
+
+ PublicClientAuthConfigResponse* New(::google::protobuf::Arena* arena) const final {
+ return CreateMaybeMessage(arena);
+ }
+ void CopyFrom(const ::google::protobuf::Message& from) final;
+ void MergeFrom(const ::google::protobuf::Message& from) final;
+ void CopyFrom(const PublicClientAuthConfigResponse& from);
+ void MergeFrom(const PublicClientAuthConfigResponse& from);
+ PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
+ bool IsInitialized() const final;
+
+ size_t ByteSizeLong() const final;
+ #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ static const char* _InternalParse(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx);
+ ::google::protobuf::internal::ParseFunc _ParseFunc() const final { return _InternalParse; }
+ #else
+ bool MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) final;
+ #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+ void SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const final;
+ ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const final;
+ int GetCachedSize() const final { return _cached_size_.Get(); }
+
+ private:
+ void SharedCtor();
+ void SharedDtor();
+ void SetCachedSize(int size) const final;
+ void InternalSwap(PublicClientAuthConfigResponse* other);
+ private:
+ inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
+ return nullptr;
+ }
+ inline void* MaybeArenaPtr() const {
+ return nullptr;
+ }
+ public:
+
+ ::google::protobuf::Metadata GetMetadata() const final;
+
+ // nested types ----------------------------------------------------
+
+ // accessors -------------------------------------------------------
+
+ // repeated string scopes = 3;
+ int scopes_size() const;
+ void clear_scopes();
+ static const int kScopesFieldNumber = 3;
+ const ::std::string& scopes(int index) const;
+ ::std::string* mutable_scopes(int index);
+ void set_scopes(int index, const ::std::string& value);
+ #if LANG_CXX11
+ void set_scopes(int index, ::std::string&& value);
+ #endif
+ void set_scopes(int index, const char* value);
+ void set_scopes(int index, const char* value, size_t size);
+ ::std::string* add_scopes();
+ void add_scopes(const ::std::string& value);
+ #if LANG_CXX11
+ void add_scopes(::std::string&& value);
+ #endif
+ void add_scopes(const char* value);
+ void add_scopes(const char* value, size_t size);
+ const ::google::protobuf::RepeatedPtrField<::std::string>& scopes() const;
+ ::google::protobuf::RepeatedPtrField<::std::string>* mutable_scopes();
+
+ // string client_id = 1;
+ void clear_client_id();
+ static const int kClientIdFieldNumber = 1;
+ const ::std::string& client_id() const;
+ void set_client_id(const ::std::string& value);
+ #if LANG_CXX11
+ void set_client_id(::std::string&& value);
+ #endif
+ void set_client_id(const char* value);
+ void set_client_id(const char* value, size_t size);
+ ::std::string* mutable_client_id();
+ ::std::string* release_client_id();
+ void set_allocated_client_id(::std::string* client_id);
+
+ // string redirect_uri = 2;
+ void clear_redirect_uri();
+ static const int kRedirectUriFieldNumber = 2;
+ const ::std::string& redirect_uri() const;
+ void set_redirect_uri(const ::std::string& value);
+ #if LANG_CXX11
+ void set_redirect_uri(::std::string&& value);
+ #endif
+ void set_redirect_uri(const char* value);
+ void set_redirect_uri(const char* value, size_t size);
+ ::std::string* mutable_redirect_uri();
+ ::std::string* release_redirect_uri();
+ void set_allocated_redirect_uri(::std::string* redirect_uri);
+
+ // string authorization_metadata_key = 4;
+ void clear_authorization_metadata_key();
+ static const int kAuthorizationMetadataKeyFieldNumber = 4;
+ const ::std::string& authorization_metadata_key() const;
+ void set_authorization_metadata_key(const ::std::string& value);
+ #if LANG_CXX11
+ void set_authorization_metadata_key(::std::string&& value);
+ #endif
+ void set_authorization_metadata_key(const char* value);
+ void set_authorization_metadata_key(const char* value, size_t size);
+ ::std::string* mutable_authorization_metadata_key();
+ ::std::string* release_authorization_metadata_key();
+ void set_allocated_authorization_metadata_key(::std::string* authorization_metadata_key);
+
+ // @@protoc_insertion_point(class_scope:flyteidl.service.PublicClientAuthConfigResponse)
+ private:
+ class HasBitSetters;
+
+ ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
+ ::google::protobuf::RepeatedPtrField<::std::string> scopes_;
+ ::google::protobuf::internal::ArenaStringPtr client_id_;
+ ::google::protobuf::internal::ArenaStringPtr redirect_uri_;
+ ::google::protobuf::internal::ArenaStringPtr authorization_metadata_key_;
+ mutable ::google::protobuf::internal::CachedSize _cached_size_;
+ friend struct ::TableStruct_flyteidl_2fservice_2fauth_2eproto;
+};
+// ===================================================================
+
+
+// ===================================================================
+
+#ifdef __GNUC__
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic ignored "-Wstrict-aliasing"
+#endif // __GNUC__
+// OAuth2MetadataRequest
+
+// -------------------------------------------------------------------
+
+// OAuth2MetadataResponse
+
+// string issuer = 1;
+inline void OAuth2MetadataResponse::clear_issuer() {
+ issuer_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline const ::std::string& OAuth2MetadataResponse::issuer() const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.issuer)
+ return issuer_.GetNoArena();
+}
+inline void OAuth2MetadataResponse::set_issuer(const ::std::string& value) {
+
+ issuer_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.issuer)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_issuer(::std::string&& value) {
+
+ issuer_.SetNoArena(
+ &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+ // @@protoc_insertion_point(field_set_rvalue:flyteidl.service.OAuth2MetadataResponse.issuer)
+}
+#endif
+inline void OAuth2MetadataResponse::set_issuer(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ issuer_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.issuer)
+}
+inline void OAuth2MetadataResponse::set_issuer(const char* value, size_t size) {
+
+ issuer_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ ::std::string(reinterpret_cast(value), size));
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.issuer)
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_issuer() {
+
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.issuer)
+ return issuer_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* OAuth2MetadataResponse::release_issuer() {
+ // @@protoc_insertion_point(field_release:flyteidl.service.OAuth2MetadataResponse.issuer)
+
+ return issuer_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void OAuth2MetadataResponse::set_allocated_issuer(::std::string* issuer) {
+ if (issuer != nullptr) {
+
+ } else {
+
+ }
+ issuer_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), issuer);
+ // @@protoc_insertion_point(field_set_allocated:flyteidl.service.OAuth2MetadataResponse.issuer)
+}
+
+// string authorization_endpoint = 2;
+inline void OAuth2MetadataResponse::clear_authorization_endpoint() {
+ authorization_endpoint_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline const ::std::string& OAuth2MetadataResponse::authorization_endpoint() const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+ return authorization_endpoint_.GetNoArena();
+}
+inline void OAuth2MetadataResponse::set_authorization_endpoint(const ::std::string& value) {
+
+ authorization_endpoint_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_authorization_endpoint(::std::string&& value) {
+
+ authorization_endpoint_.SetNoArena(
+ &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+ // @@protoc_insertion_point(field_set_rvalue:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+}
+#endif
+inline void OAuth2MetadataResponse::set_authorization_endpoint(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ authorization_endpoint_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+}
+inline void OAuth2MetadataResponse::set_authorization_endpoint(const char* value, size_t size) {
+
+ authorization_endpoint_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ ::std::string(reinterpret_cast(value), size));
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_authorization_endpoint() {
+
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+ return authorization_endpoint_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* OAuth2MetadataResponse::release_authorization_endpoint() {
+ // @@protoc_insertion_point(field_release:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+
+ return authorization_endpoint_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void OAuth2MetadataResponse::set_allocated_authorization_endpoint(::std::string* authorization_endpoint) {
+ if (authorization_endpoint != nullptr) {
+
+ } else {
+
+ }
+ authorization_endpoint_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), authorization_endpoint);
+ // @@protoc_insertion_point(field_set_allocated:flyteidl.service.OAuth2MetadataResponse.authorization_endpoint)
+}
+
+// string token_endpoint = 3;
+inline void OAuth2MetadataResponse::clear_token_endpoint() {
+ token_endpoint_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline const ::std::string& OAuth2MetadataResponse::token_endpoint() const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+ return token_endpoint_.GetNoArena();
+}
+inline void OAuth2MetadataResponse::set_token_endpoint(const ::std::string& value) {
+
+ token_endpoint_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_token_endpoint(::std::string&& value) {
+
+ token_endpoint_.SetNoArena(
+ &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+ // @@protoc_insertion_point(field_set_rvalue:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+}
+#endif
+inline void OAuth2MetadataResponse::set_token_endpoint(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ token_endpoint_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+}
+inline void OAuth2MetadataResponse::set_token_endpoint(const char* value, size_t size) {
+
+ token_endpoint_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ ::std::string(reinterpret_cast(value), size));
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_token_endpoint() {
+
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+ return token_endpoint_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* OAuth2MetadataResponse::release_token_endpoint() {
+ // @@protoc_insertion_point(field_release:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+
+ return token_endpoint_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void OAuth2MetadataResponse::set_allocated_token_endpoint(::std::string* token_endpoint) {
+ if (token_endpoint != nullptr) {
+
+ } else {
+
+ }
+ token_endpoint_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), token_endpoint);
+ // @@protoc_insertion_point(field_set_allocated:flyteidl.service.OAuth2MetadataResponse.token_endpoint)
+}
+
+// repeated string response_types_supported = 4;
+inline int OAuth2MetadataResponse::response_types_supported_size() const {
+ return response_types_supported_.size();
+}
+inline void OAuth2MetadataResponse::clear_response_types_supported() {
+ response_types_supported_.Clear();
+}
+inline const ::std::string& OAuth2MetadataResponse::response_types_supported(int index) const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+ return response_types_supported_.Get(index);
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_response_types_supported(int index) {
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+ return response_types_supported_.Mutable(index);
+}
+inline void OAuth2MetadataResponse::set_response_types_supported(int index, const ::std::string& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+ response_types_supported_.Mutable(index)->assign(value);
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_response_types_supported(int index, ::std::string&& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+ response_types_supported_.Mutable(index)->assign(std::move(value));
+}
+#endif
+inline void OAuth2MetadataResponse::set_response_types_supported(int index, const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ response_types_supported_.Mutable(index)->assign(value);
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+}
+inline void OAuth2MetadataResponse::set_response_types_supported(int index, const char* value, size_t size) {
+ response_types_supported_.Mutable(index)->assign(
+ reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+}
+inline ::std::string* OAuth2MetadataResponse::add_response_types_supported() {
+ // @@protoc_insertion_point(field_add_mutable:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+ return response_types_supported_.Add();
+}
+inline void OAuth2MetadataResponse::add_response_types_supported(const ::std::string& value) {
+ response_types_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::add_response_types_supported(::std::string&& value) {
+ response_types_supported_.Add(std::move(value));
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+}
+#endif
+inline void OAuth2MetadataResponse::add_response_types_supported(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ response_types_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add_char:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+}
+inline void OAuth2MetadataResponse::add_response_types_supported(const char* value, size_t size) {
+ response_types_supported_.Add()->assign(reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_add_pointer:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+}
+inline const ::google::protobuf::RepeatedPtrField<::std::string>&
+OAuth2MetadataResponse::response_types_supported() const {
+ // @@protoc_insertion_point(field_list:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+ return response_types_supported_;
+}
+inline ::google::protobuf::RepeatedPtrField<::std::string>*
+OAuth2MetadataResponse::mutable_response_types_supported() {
+ // @@protoc_insertion_point(field_mutable_list:flyteidl.service.OAuth2MetadataResponse.response_types_supported)
+ return &response_types_supported_;
+}
+
+// repeated string scopes_supported = 5;
+inline int OAuth2MetadataResponse::scopes_supported_size() const {
+ return scopes_supported_.size();
+}
+inline void OAuth2MetadataResponse::clear_scopes_supported() {
+ scopes_supported_.Clear();
+}
+inline const ::std::string& OAuth2MetadataResponse::scopes_supported(int index) const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+ return scopes_supported_.Get(index);
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_scopes_supported(int index) {
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+ return scopes_supported_.Mutable(index);
+}
+inline void OAuth2MetadataResponse::set_scopes_supported(int index, const ::std::string& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+ scopes_supported_.Mutable(index)->assign(value);
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_scopes_supported(int index, ::std::string&& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+ scopes_supported_.Mutable(index)->assign(std::move(value));
+}
+#endif
+inline void OAuth2MetadataResponse::set_scopes_supported(int index, const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ scopes_supported_.Mutable(index)->assign(value);
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+}
+inline void OAuth2MetadataResponse::set_scopes_supported(int index, const char* value, size_t size) {
+ scopes_supported_.Mutable(index)->assign(
+ reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+}
+inline ::std::string* OAuth2MetadataResponse::add_scopes_supported() {
+ // @@protoc_insertion_point(field_add_mutable:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+ return scopes_supported_.Add();
+}
+inline void OAuth2MetadataResponse::add_scopes_supported(const ::std::string& value) {
+ scopes_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::add_scopes_supported(::std::string&& value) {
+ scopes_supported_.Add(std::move(value));
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+}
+#endif
+inline void OAuth2MetadataResponse::add_scopes_supported(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ scopes_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add_char:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+}
+inline void OAuth2MetadataResponse::add_scopes_supported(const char* value, size_t size) {
+ scopes_supported_.Add()->assign(reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_add_pointer:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+}
+inline const ::google::protobuf::RepeatedPtrField<::std::string>&
+OAuth2MetadataResponse::scopes_supported() const {
+ // @@protoc_insertion_point(field_list:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+ return scopes_supported_;
+}
+inline ::google::protobuf::RepeatedPtrField<::std::string>*
+OAuth2MetadataResponse::mutable_scopes_supported() {
+ // @@protoc_insertion_point(field_mutable_list:flyteidl.service.OAuth2MetadataResponse.scopes_supported)
+ return &scopes_supported_;
+}
+
+// repeated string token_endpoint_auth_methods_supported = 6;
+inline int OAuth2MetadataResponse::token_endpoint_auth_methods_supported_size() const {
+ return token_endpoint_auth_methods_supported_.size();
+}
+inline void OAuth2MetadataResponse::clear_token_endpoint_auth_methods_supported() {
+ token_endpoint_auth_methods_supported_.Clear();
+}
+inline const ::std::string& OAuth2MetadataResponse::token_endpoint_auth_methods_supported(int index) const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+ return token_endpoint_auth_methods_supported_.Get(index);
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_token_endpoint_auth_methods_supported(int index) {
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+ return token_endpoint_auth_methods_supported_.Mutable(index);
+}
+inline void OAuth2MetadataResponse::set_token_endpoint_auth_methods_supported(int index, const ::std::string& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+ token_endpoint_auth_methods_supported_.Mutable(index)->assign(value);
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_token_endpoint_auth_methods_supported(int index, ::std::string&& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+ token_endpoint_auth_methods_supported_.Mutable(index)->assign(std::move(value));
+}
+#endif
+inline void OAuth2MetadataResponse::set_token_endpoint_auth_methods_supported(int index, const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ token_endpoint_auth_methods_supported_.Mutable(index)->assign(value);
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+}
+inline void OAuth2MetadataResponse::set_token_endpoint_auth_methods_supported(int index, const char* value, size_t size) {
+ token_endpoint_auth_methods_supported_.Mutable(index)->assign(
+ reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+}
+inline ::std::string* OAuth2MetadataResponse::add_token_endpoint_auth_methods_supported() {
+ // @@protoc_insertion_point(field_add_mutable:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+ return token_endpoint_auth_methods_supported_.Add();
+}
+inline void OAuth2MetadataResponse::add_token_endpoint_auth_methods_supported(const ::std::string& value) {
+ token_endpoint_auth_methods_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::add_token_endpoint_auth_methods_supported(::std::string&& value) {
+ token_endpoint_auth_methods_supported_.Add(std::move(value));
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+}
+#endif
+inline void OAuth2MetadataResponse::add_token_endpoint_auth_methods_supported(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ token_endpoint_auth_methods_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add_char:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+}
+inline void OAuth2MetadataResponse::add_token_endpoint_auth_methods_supported(const char* value, size_t size) {
+ token_endpoint_auth_methods_supported_.Add()->assign(reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_add_pointer:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+}
+inline const ::google::protobuf::RepeatedPtrField<::std::string>&
+OAuth2MetadataResponse::token_endpoint_auth_methods_supported() const {
+ // @@protoc_insertion_point(field_list:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+ return token_endpoint_auth_methods_supported_;
+}
+inline ::google::protobuf::RepeatedPtrField<::std::string>*
+OAuth2MetadataResponse::mutable_token_endpoint_auth_methods_supported() {
+ // @@protoc_insertion_point(field_mutable_list:flyteidl.service.OAuth2MetadataResponse.token_endpoint_auth_methods_supported)
+ return &token_endpoint_auth_methods_supported_;
+}
+
+// string jwks_uri = 7;
+inline void OAuth2MetadataResponse::clear_jwks_uri() {
+ jwks_uri_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline const ::std::string& OAuth2MetadataResponse::jwks_uri() const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+ return jwks_uri_.GetNoArena();
+}
+inline void OAuth2MetadataResponse::set_jwks_uri(const ::std::string& value) {
+
+ jwks_uri_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_jwks_uri(::std::string&& value) {
+
+ jwks_uri_.SetNoArena(
+ &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+ // @@protoc_insertion_point(field_set_rvalue:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+}
+#endif
+inline void OAuth2MetadataResponse::set_jwks_uri(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ jwks_uri_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+}
+inline void OAuth2MetadataResponse::set_jwks_uri(const char* value, size_t size) {
+
+ jwks_uri_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ ::std::string(reinterpret_cast(value), size));
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_jwks_uri() {
+
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+ return jwks_uri_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* OAuth2MetadataResponse::release_jwks_uri() {
+ // @@protoc_insertion_point(field_release:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+
+ return jwks_uri_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void OAuth2MetadataResponse::set_allocated_jwks_uri(::std::string* jwks_uri) {
+ if (jwks_uri != nullptr) {
+
+ } else {
+
+ }
+ jwks_uri_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), jwks_uri);
+ // @@protoc_insertion_point(field_set_allocated:flyteidl.service.OAuth2MetadataResponse.jwks_uri)
+}
+
+// repeated string code_challenge_methods_supported = 8;
+inline int OAuth2MetadataResponse::code_challenge_methods_supported_size() const {
+ return code_challenge_methods_supported_.size();
+}
+inline void OAuth2MetadataResponse::clear_code_challenge_methods_supported() {
+ code_challenge_methods_supported_.Clear();
+}
+inline const ::std::string& OAuth2MetadataResponse::code_challenge_methods_supported(int index) const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+ return code_challenge_methods_supported_.Get(index);
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_code_challenge_methods_supported(int index) {
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+ return code_challenge_methods_supported_.Mutable(index);
+}
+inline void OAuth2MetadataResponse::set_code_challenge_methods_supported(int index, const ::std::string& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+ code_challenge_methods_supported_.Mutable(index)->assign(value);
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_code_challenge_methods_supported(int index, ::std::string&& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+ code_challenge_methods_supported_.Mutable(index)->assign(std::move(value));
+}
+#endif
+inline void OAuth2MetadataResponse::set_code_challenge_methods_supported(int index, const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ code_challenge_methods_supported_.Mutable(index)->assign(value);
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+}
+inline void OAuth2MetadataResponse::set_code_challenge_methods_supported(int index, const char* value, size_t size) {
+ code_challenge_methods_supported_.Mutable(index)->assign(
+ reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+}
+inline ::std::string* OAuth2MetadataResponse::add_code_challenge_methods_supported() {
+ // @@protoc_insertion_point(field_add_mutable:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+ return code_challenge_methods_supported_.Add();
+}
+inline void OAuth2MetadataResponse::add_code_challenge_methods_supported(const ::std::string& value) {
+ code_challenge_methods_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::add_code_challenge_methods_supported(::std::string&& value) {
+ code_challenge_methods_supported_.Add(std::move(value));
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+}
+#endif
+inline void OAuth2MetadataResponse::add_code_challenge_methods_supported(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ code_challenge_methods_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add_char:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+}
+inline void OAuth2MetadataResponse::add_code_challenge_methods_supported(const char* value, size_t size) {
+ code_challenge_methods_supported_.Add()->assign(reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_add_pointer:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+}
+inline const ::google::protobuf::RepeatedPtrField<::std::string>&
+OAuth2MetadataResponse::code_challenge_methods_supported() const {
+ // @@protoc_insertion_point(field_list:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+ return code_challenge_methods_supported_;
+}
+inline ::google::protobuf::RepeatedPtrField<::std::string>*
+OAuth2MetadataResponse::mutable_code_challenge_methods_supported() {
+ // @@protoc_insertion_point(field_mutable_list:flyteidl.service.OAuth2MetadataResponse.code_challenge_methods_supported)
+ return &code_challenge_methods_supported_;
+}
+
+// repeated string grant_types_supported = 9;
+inline int OAuth2MetadataResponse::grant_types_supported_size() const {
+ return grant_types_supported_.size();
+}
+inline void OAuth2MetadataResponse::clear_grant_types_supported() {
+ grant_types_supported_.Clear();
+}
+inline const ::std::string& OAuth2MetadataResponse::grant_types_supported(int index) const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+ return grant_types_supported_.Get(index);
+}
+inline ::std::string* OAuth2MetadataResponse::mutable_grant_types_supported(int index) {
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+ return grant_types_supported_.Mutable(index);
+}
+inline void OAuth2MetadataResponse::set_grant_types_supported(int index, const ::std::string& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+ grant_types_supported_.Mutable(index)->assign(value);
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::set_grant_types_supported(int index, ::std::string&& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+ grant_types_supported_.Mutable(index)->assign(std::move(value));
+}
+#endif
+inline void OAuth2MetadataResponse::set_grant_types_supported(int index, const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ grant_types_supported_.Mutable(index)->assign(value);
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+}
+inline void OAuth2MetadataResponse::set_grant_types_supported(int index, const char* value, size_t size) {
+ grant_types_supported_.Mutable(index)->assign(
+ reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+}
+inline ::std::string* OAuth2MetadataResponse::add_grant_types_supported() {
+ // @@protoc_insertion_point(field_add_mutable:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+ return grant_types_supported_.Add();
+}
+inline void OAuth2MetadataResponse::add_grant_types_supported(const ::std::string& value) {
+ grant_types_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+}
+#if LANG_CXX11
+inline void OAuth2MetadataResponse::add_grant_types_supported(::std::string&& value) {
+ grant_types_supported_.Add(std::move(value));
+ // @@protoc_insertion_point(field_add:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+}
+#endif
+inline void OAuth2MetadataResponse::add_grant_types_supported(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ grant_types_supported_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add_char:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+}
+inline void OAuth2MetadataResponse::add_grant_types_supported(const char* value, size_t size) {
+ grant_types_supported_.Add()->assign(reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_add_pointer:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+}
+inline const ::google::protobuf::RepeatedPtrField<::std::string>&
+OAuth2MetadataResponse::grant_types_supported() const {
+ // @@protoc_insertion_point(field_list:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+ return grant_types_supported_;
+}
+inline ::google::protobuf::RepeatedPtrField<::std::string>*
+OAuth2MetadataResponse::mutable_grant_types_supported() {
+ // @@protoc_insertion_point(field_mutable_list:flyteidl.service.OAuth2MetadataResponse.grant_types_supported)
+ return &grant_types_supported_;
+}
+
+// -------------------------------------------------------------------
+
+// PublicClientAuthConfigRequest
+
+// -------------------------------------------------------------------
+
+// PublicClientAuthConfigResponse
+
+// string client_id = 1;
+inline void PublicClientAuthConfigResponse::clear_client_id() {
+ client_id_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline const ::std::string& PublicClientAuthConfigResponse::client_id() const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+ return client_id_.GetNoArena();
+}
+inline void PublicClientAuthConfigResponse::set_client_id(const ::std::string& value) {
+
+ client_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+ // @@protoc_insertion_point(field_set:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+}
+#if LANG_CXX11
+inline void PublicClientAuthConfigResponse::set_client_id(::std::string&& value) {
+
+ client_id_.SetNoArena(
+ &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+ // @@protoc_insertion_point(field_set_rvalue:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+}
+#endif
+inline void PublicClientAuthConfigResponse::set_client_id(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ client_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+}
+inline void PublicClientAuthConfigResponse::set_client_id(const char* value, size_t size) {
+
+ client_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ ::std::string(reinterpret_cast(value), size));
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+}
+inline ::std::string* PublicClientAuthConfigResponse::mutable_client_id() {
+
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+ return client_id_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* PublicClientAuthConfigResponse::release_client_id() {
+ // @@protoc_insertion_point(field_release:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+
+ return client_id_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void PublicClientAuthConfigResponse::set_allocated_client_id(::std::string* client_id) {
+ if (client_id != nullptr) {
+
+ } else {
+
+ }
+ client_id_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), client_id);
+ // @@protoc_insertion_point(field_set_allocated:flyteidl.service.PublicClientAuthConfigResponse.client_id)
+}
+
+// string redirect_uri = 2;
+inline void PublicClientAuthConfigResponse::clear_redirect_uri() {
+ redirect_uri_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline const ::std::string& PublicClientAuthConfigResponse::redirect_uri() const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+ return redirect_uri_.GetNoArena();
+}
+inline void PublicClientAuthConfigResponse::set_redirect_uri(const ::std::string& value) {
+
+ redirect_uri_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+ // @@protoc_insertion_point(field_set:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+}
+#if LANG_CXX11
+inline void PublicClientAuthConfigResponse::set_redirect_uri(::std::string&& value) {
+
+ redirect_uri_.SetNoArena(
+ &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+ // @@protoc_insertion_point(field_set_rvalue:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+}
+#endif
+inline void PublicClientAuthConfigResponse::set_redirect_uri(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ redirect_uri_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+}
+inline void PublicClientAuthConfigResponse::set_redirect_uri(const char* value, size_t size) {
+
+ redirect_uri_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ ::std::string(reinterpret_cast(value), size));
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+}
+inline ::std::string* PublicClientAuthConfigResponse::mutable_redirect_uri() {
+
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+ return redirect_uri_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* PublicClientAuthConfigResponse::release_redirect_uri() {
+ // @@protoc_insertion_point(field_release:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+
+ return redirect_uri_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void PublicClientAuthConfigResponse::set_allocated_redirect_uri(::std::string* redirect_uri) {
+ if (redirect_uri != nullptr) {
+
+ } else {
+
+ }
+ redirect_uri_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), redirect_uri);
+ // @@protoc_insertion_point(field_set_allocated:flyteidl.service.PublicClientAuthConfigResponse.redirect_uri)
+}
+
+// repeated string scopes = 3;
+inline int PublicClientAuthConfigResponse::scopes_size() const {
+ return scopes_.size();
+}
+inline void PublicClientAuthConfigResponse::clear_scopes() {
+ scopes_.Clear();
+}
+inline const ::std::string& PublicClientAuthConfigResponse::scopes(int index) const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+ return scopes_.Get(index);
+}
+inline ::std::string* PublicClientAuthConfigResponse::mutable_scopes(int index) {
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+ return scopes_.Mutable(index);
+}
+inline void PublicClientAuthConfigResponse::set_scopes(int index, const ::std::string& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+ scopes_.Mutable(index)->assign(value);
+}
+#if LANG_CXX11
+inline void PublicClientAuthConfigResponse::set_scopes(int index, ::std::string&& value) {
+ // @@protoc_insertion_point(field_set:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+ scopes_.Mutable(index)->assign(std::move(value));
+}
+#endif
+inline void PublicClientAuthConfigResponse::set_scopes(int index, const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ scopes_.Mutable(index)->assign(value);
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+}
+inline void PublicClientAuthConfigResponse::set_scopes(int index, const char* value, size_t size) {
+ scopes_.Mutable(index)->assign(
+ reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+}
+inline ::std::string* PublicClientAuthConfigResponse::add_scopes() {
+ // @@protoc_insertion_point(field_add_mutable:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+ return scopes_.Add();
+}
+inline void PublicClientAuthConfigResponse::add_scopes(const ::std::string& value) {
+ scopes_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+}
+#if LANG_CXX11
+inline void PublicClientAuthConfigResponse::add_scopes(::std::string&& value) {
+ scopes_.Add(std::move(value));
+ // @@protoc_insertion_point(field_add:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+}
+#endif
+inline void PublicClientAuthConfigResponse::add_scopes(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+ scopes_.Add()->assign(value);
+ // @@protoc_insertion_point(field_add_char:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+}
+inline void PublicClientAuthConfigResponse::add_scopes(const char* value, size_t size) {
+ scopes_.Add()->assign(reinterpret_cast(value), size);
+ // @@protoc_insertion_point(field_add_pointer:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+}
+inline const ::google::protobuf::RepeatedPtrField<::std::string>&
+PublicClientAuthConfigResponse::scopes() const {
+ // @@protoc_insertion_point(field_list:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+ return scopes_;
+}
+inline ::google::protobuf::RepeatedPtrField<::std::string>*
+PublicClientAuthConfigResponse::mutable_scopes() {
+ // @@protoc_insertion_point(field_mutable_list:flyteidl.service.PublicClientAuthConfigResponse.scopes)
+ return &scopes_;
+}
+
+// string authorization_metadata_key = 4;
+inline void PublicClientAuthConfigResponse::clear_authorization_metadata_key() {
+ authorization_metadata_key_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline const ::std::string& PublicClientAuthConfigResponse::authorization_metadata_key() const {
+ // @@protoc_insertion_point(field_get:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+ return authorization_metadata_key_.GetNoArena();
+}
+inline void PublicClientAuthConfigResponse::set_authorization_metadata_key(const ::std::string& value) {
+
+ authorization_metadata_key_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+ // @@protoc_insertion_point(field_set:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+}
+#if LANG_CXX11
+inline void PublicClientAuthConfigResponse::set_authorization_metadata_key(::std::string&& value) {
+
+ authorization_metadata_key_.SetNoArena(
+ &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+ // @@protoc_insertion_point(field_set_rvalue:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+}
+#endif
+inline void PublicClientAuthConfigResponse::set_authorization_metadata_key(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ authorization_metadata_key_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+ // @@protoc_insertion_point(field_set_char:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+}
+inline void PublicClientAuthConfigResponse::set_authorization_metadata_key(const char* value, size_t size) {
+
+ authorization_metadata_key_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ ::std::string(reinterpret_cast(value), size));
+ // @@protoc_insertion_point(field_set_pointer:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+}
+inline ::std::string* PublicClientAuthConfigResponse::mutable_authorization_metadata_key() {
+
+ // @@protoc_insertion_point(field_mutable:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+ return authorization_metadata_key_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* PublicClientAuthConfigResponse::release_authorization_metadata_key() {
+ // @@protoc_insertion_point(field_release:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+
+ return authorization_metadata_key_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void PublicClientAuthConfigResponse::set_allocated_authorization_metadata_key(::std::string* authorization_metadata_key) {
+ if (authorization_metadata_key != nullptr) {
+
+ } else {
+
+ }
+ authorization_metadata_key_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), authorization_metadata_key);
+ // @@protoc_insertion_point(field_set_allocated:flyteidl.service.PublicClientAuthConfigResponse.authorization_metadata_key)
+}
+
+#ifdef __GNUC__
+ #pragma GCC diagnostic pop
+#endif // __GNUC__
+// -------------------------------------------------------------------
+
+// -------------------------------------------------------------------
+
+// -------------------------------------------------------------------
+
+
+// @@protoc_insertion_point(namespace_scope)
+
+} // namespace service
+} // namespace flyteidl
+
+// @@protoc_insertion_point(global_scope)
+
+#include
+#endif // PROTOBUF_INCLUDED_flyteidl_2fservice_2fauth_2eproto
diff --git a/flyteidl/gen/pb-cpp/flyteidl/service/identity.grpc.pb.cc b/flyteidl/gen/pb-cpp/flyteidl/service/identity.grpc.pb.cc
new file mode 100644
index 0000000000..31c587db24
--- /dev/null
+++ b/flyteidl/gen/pb-cpp/flyteidl/service/identity.grpc.pb.cc
@@ -0,0 +1,85 @@
+// Generated by the gRPC C++ plugin.
+// If you make any local change, they will be lost.
+// source: flyteidl/service/identity.proto
+
+#include "flyteidl/service/identity.pb.h"
+#include "flyteidl/service/identity.grpc.pb.h"
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+namespace flyteidl {
+namespace service {
+
+static const char* IdentityService_method_names[] = {
+ "/flyteidl.service.IdentityService/UserInfo",
+};
+
+std::unique_ptr< IdentityService::Stub> IdentityService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
+ (void)options;
+ std::unique_ptr< IdentityService::Stub> stub(new IdentityService::Stub(channel));
+ return stub;
+}
+
+IdentityService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel)
+ : channel_(channel), rpcmethod_UserInfo_(IdentityService_method_names[0], ::grpc::internal::RpcMethod::NORMAL_RPC, channel)
+ {}
+
+::grpc::Status IdentityService::Stub::UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::flyteidl::service::UserInfoResponse* response) {
+ return ::grpc::internal::BlockingUnaryCall(channel_.get(), rpcmethod_UserInfo_, context, request, response);
+}
+
+void IdentityService::Stub::experimental_async::UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response, std::function f) {
+ ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_UserInfo_, context, request, response, std::move(f));
+}
+
+void IdentityService::Stub::experimental_async::UserInfo(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::UserInfoResponse* response, std::function f) {
+ ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_UserInfo_, context, request, response, std::move(f));
+}
+
+void IdentityService::Stub::experimental_async::UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) {
+ ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_UserInfo_, context, request, response, reactor);
+}
+
+void IdentityService::Stub::experimental_async::UserInfo(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::UserInfoResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) {
+ ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_UserInfo_, context, request, response, reactor);
+}
+
+::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>* IdentityService::Stub::AsyncUserInfoRaw(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) {
+ return ::grpc::internal::ClientAsyncResponseReaderFactory< ::flyteidl::service::UserInfoResponse>::Create(channel_.get(), cq, rpcmethod_UserInfo_, context, request, true);
+}
+
+::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>* IdentityService::Stub::PrepareAsyncUserInfoRaw(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) {
+ return ::grpc::internal::ClientAsyncResponseReaderFactory< ::flyteidl::service::UserInfoResponse>::Create(channel_.get(), cq, rpcmethod_UserInfo_, context, request, false);
+}
+
+IdentityService::Service::Service() {
+ AddMethod(new ::grpc::internal::RpcServiceMethod(
+ IdentityService_method_names[0],
+ ::grpc::internal::RpcMethod::NORMAL_RPC,
+ new ::grpc::internal::RpcMethodHandler< IdentityService::Service, ::flyteidl::service::UserInfoRequest, ::flyteidl::service::UserInfoResponse>(
+ std::mem_fn(&IdentityService::Service::UserInfo), this)));
+}
+
+IdentityService::Service::~Service() {
+}
+
+::grpc::Status IdentityService::Service::UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response) {
+ (void) context;
+ (void) request;
+ (void) response;
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+}
+
+
+} // namespace flyteidl
+} // namespace service
+
diff --git a/flyteidl/gen/pb-cpp/flyteidl/service/identity.grpc.pb.h b/flyteidl/gen/pb-cpp/flyteidl/service/identity.grpc.pb.h
new file mode 100644
index 0000000000..241c042b09
--- /dev/null
+++ b/flyteidl/gen/pb-cpp/flyteidl/service/identity.grpc.pb.h
@@ -0,0 +1,259 @@
+// Generated by the gRPC C++ plugin.
+// If you make any local change, they will be lost.
+// source: flyteidl/service/identity.proto
+#ifndef GRPC_flyteidl_2fservice_2fidentity_2eproto__INCLUDED
+#define GRPC_flyteidl_2fservice_2fidentity_2eproto__INCLUDED
+
+#include "flyteidl/service/identity.pb.h"
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+
+namespace grpc_impl {
+class Channel;
+class CompletionQueue;
+class ServerCompletionQueue;
+} // namespace grpc_impl
+
+namespace grpc {
+namespace experimental {
+template
+class MessageAllocator;
+} // namespace experimental
+} // namespace grpc_impl
+
+namespace grpc {
+class ServerContext;
+} // namespace grpc
+
+namespace flyteidl {
+namespace service {
+
+// IdentityService defines an RPC Service that interacts with user/app identities.
+class IdentityService final {
+ public:
+ static constexpr char const* service_full_name() {
+ return "flyteidl.service.IdentityService";
+ }
+ class StubInterface {
+ public:
+ virtual ~StubInterface() {}
+ // Retrieves user information about the currently logged in user.
+ virtual ::grpc::Status UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::flyteidl::service::UserInfoResponse* response) = 0;
+ std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::UserInfoResponse>> AsyncUserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::UserInfoResponse>>(AsyncUserInfoRaw(context, request, cq));
+ }
+ std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::UserInfoResponse>> PrepareAsyncUserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::UserInfoResponse>>(PrepareAsyncUserInfoRaw(context, request, cq));
+ }
+ class experimental_async_interface {
+ public:
+ virtual ~experimental_async_interface() {}
+ // Retrieves user information about the currently logged in user.
+ virtual void UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response, std::function) = 0;
+ virtual void UserInfo(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::UserInfoResponse* response, std::function) = 0;
+ virtual void UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0;
+ virtual void UserInfo(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::UserInfoResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0;
+ };
+ virtual class experimental_async_interface* experimental_async() { return nullptr; }
+ private:
+ virtual ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::UserInfoResponse>* AsyncUserInfoRaw(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) = 0;
+ virtual ::grpc::ClientAsyncResponseReaderInterface< ::flyteidl::service::UserInfoResponse>* PrepareAsyncUserInfoRaw(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) = 0;
+ };
+ class Stub final : public StubInterface {
+ public:
+ Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel);
+ ::grpc::Status UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::flyteidl::service::UserInfoResponse* response) override;
+ std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>> AsyncUserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>>(AsyncUserInfoRaw(context, request, cq));
+ }
+ std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>> PrepareAsyncUserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) {
+ return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>>(PrepareAsyncUserInfoRaw(context, request, cq));
+ }
+ class experimental_async final :
+ public StubInterface::experimental_async_interface {
+ public:
+ void UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response, std::function) override;
+ void UserInfo(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::UserInfoResponse* response, std::function) override;
+ void UserInfo(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override;
+ void UserInfo(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::flyteidl::service::UserInfoResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override;
+ private:
+ friend class Stub;
+ explicit experimental_async(Stub* stub): stub_(stub) { }
+ Stub* stub() { return stub_; }
+ Stub* stub_;
+ };
+ class experimental_async_interface* experimental_async() override { return &async_stub_; }
+
+ private:
+ std::shared_ptr< ::grpc::ChannelInterface> channel_;
+ class experimental_async async_stub_{this};
+ ::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>* AsyncUserInfoRaw(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) override;
+ ::grpc::ClientAsyncResponseReader< ::flyteidl::service::UserInfoResponse>* PrepareAsyncUserInfoRaw(::grpc::ClientContext* context, const ::flyteidl::service::UserInfoRequest& request, ::grpc::CompletionQueue* cq) override;
+ const ::grpc::internal::RpcMethod rpcmethod_UserInfo_;
+ };
+ static std::unique_ptr NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions());
+
+ class Service : public ::grpc::Service {
+ public:
+ Service();
+ virtual ~Service();
+ // Retrieves user information about the currently logged in user.
+ virtual ::grpc::Status UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response);
+ };
+ template
+ class WithAsyncMethod_UserInfo : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithAsyncMethod_UserInfo() {
+ ::grpc::Service::MarkMethodAsync(0);
+ }
+ ~WithAsyncMethod_UserInfo() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ void RequestUserInfo(::grpc::ServerContext* context, ::flyteidl::service::UserInfoRequest* request, ::grpc::ServerAsyncResponseWriter< ::flyteidl::service::UserInfoResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
+ ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
+ }
+ };
+ typedef WithAsyncMethod_UserInfo AsyncService;
+ template
+ class ExperimentalWithCallbackMethod_UserInfo : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ ExperimentalWithCallbackMethod_UserInfo() {
+ ::grpc::Service::experimental().MarkMethodCallback(0,
+ new ::grpc::internal::CallbackUnaryHandler< ::flyteidl::service::UserInfoRequest, ::flyteidl::service::UserInfoResponse>(
+ [this](::grpc::ServerContext* context,
+ const ::flyteidl::service::UserInfoRequest* request,
+ ::flyteidl::service::UserInfoResponse* response,
+ ::grpc::experimental::ServerCallbackRpcController* controller) {
+ return this->UserInfo(context, request, response, controller);
+ }));
+ }
+ void SetMessageAllocatorFor_UserInfo(
+ ::grpc::experimental::MessageAllocator< ::flyteidl::service::UserInfoRequest, ::flyteidl::service::UserInfoResponse>* allocator) {
+ static_cast<::grpc::internal::CallbackUnaryHandler< ::flyteidl::service::UserInfoRequest, ::flyteidl::service::UserInfoResponse>*>(
+ ::grpc::Service::experimental().GetHandler(0))
+ ->SetMessageAllocator(allocator);
+ }
+ ~ExperimentalWithCallbackMethod_UserInfo() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ virtual void UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
+ };
+ typedef ExperimentalWithCallbackMethod_UserInfo ExperimentalCallbackService;
+ template
+ class WithGenericMethod_UserInfo : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithGenericMethod_UserInfo() {
+ ::grpc::Service::MarkMethodGeneric(0);
+ }
+ ~WithGenericMethod_UserInfo() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ };
+ template
+ class WithRawMethod_UserInfo : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithRawMethod_UserInfo() {
+ ::grpc::Service::MarkMethodRaw(0);
+ }
+ ~WithRawMethod_UserInfo() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ void RequestUserInfo(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
+ ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
+ }
+ };
+ template
+ class ExperimentalWithRawCallbackMethod_UserInfo : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ ExperimentalWithRawCallbackMethod_UserInfo() {
+ ::grpc::Service::experimental().MarkMethodRawCallback(0,
+ new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
+ [this](::grpc::ServerContext* context,
+ const ::grpc::ByteBuffer* request,
+ ::grpc::ByteBuffer* response,
+ ::grpc::experimental::ServerCallbackRpcController* controller) {
+ this->UserInfo(context, request, response, controller);
+ }));
+ }
+ ~ExperimentalWithRawCallbackMethod_UserInfo() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable synchronous version of this method
+ ::grpc::Status UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ virtual void UserInfo(::grpc::ServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
+ };
+ template
+ class WithStreamedUnaryMethod_UserInfo : public BaseClass {
+ private:
+ void BaseClassMustBeDerivedFromService(const Service *service) {}
+ public:
+ WithStreamedUnaryMethod_UserInfo() {
+ ::grpc::Service::MarkMethodStreamed(0,
+ new ::grpc::internal::StreamedUnaryHandler< ::flyteidl::service::UserInfoRequest, ::flyteidl::service::UserInfoResponse>(std::bind(&WithStreamedUnaryMethod_UserInfo::StreamedUserInfo, this, std::placeholders::_1, std::placeholders::_2)));
+ }
+ ~WithStreamedUnaryMethod_UserInfo() override {
+ BaseClassMustBeDerivedFromService(this);
+ }
+ // disable regular version of this method
+ ::grpc::Status UserInfo(::grpc::ServerContext* context, const ::flyteidl::service::UserInfoRequest* request, ::flyteidl::service::UserInfoResponse* response) override {
+ abort();
+ return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ }
+ // replace default version of method with streamed unary
+ virtual ::grpc::Status StreamedUserInfo(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::flyteidl::service::UserInfoRequest,::flyteidl::service::UserInfoResponse>* server_unary_streamer) = 0;
+ };
+ typedef WithStreamedUnaryMethod_UserInfo StreamedUnaryService;
+ typedef Service SplitStreamedService;
+ typedef WithStreamedUnaryMethod_UserInfo StreamedService;
+};
+
+} // namespace service
+} // namespace flyteidl
+
+
+#endif // GRPC_flyteidl_2fservice_2fidentity_2eproto__INCLUDED
diff --git a/flyteidl/gen/pb-cpp/flyteidl/service/identity.pb.cc b/flyteidl/gen/pb-cpp/flyteidl/service/identity.pb.cc
new file mode 100644
index 0000000000..26a1e7918c
--- /dev/null
+++ b/flyteidl/gen/pb-cpp/flyteidl/service/identity.pb.cc
@@ -0,0 +1,1098 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: flyteidl/service/identity.proto
+
+#include "flyteidl/service/identity.pb.h"
+
+#include
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+// @@protoc_insertion_point(includes)
+#include
+
+namespace flyteidl {
+namespace service {
+class UserInfoRequestDefaultTypeInternal {
+ public:
+ ::google::protobuf::internal::ExplicitlyConstructed _instance;
+} _UserInfoRequest_default_instance_;
+class UserInfoResponseDefaultTypeInternal {
+ public:
+ ::google::protobuf::internal::ExplicitlyConstructed _instance;
+} _UserInfoResponse_default_instance_;
+} // namespace service
+} // namespace flyteidl
+static void InitDefaultsUserInfoRequest_flyteidl_2fservice_2fidentity_2eproto() {
+ GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+ {
+ void* ptr = &::flyteidl::service::_UserInfoRequest_default_instance_;
+ new (ptr) ::flyteidl::service::UserInfoRequest();
+ ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
+ }
+ ::flyteidl::service::UserInfoRequest::InitAsDefaultInstance();
+}
+
+::google::protobuf::internal::SCCInfo<0> scc_info_UserInfoRequest_flyteidl_2fservice_2fidentity_2eproto =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsUserInfoRequest_flyteidl_2fservice_2fidentity_2eproto}, {}};
+
+static void InitDefaultsUserInfoResponse_flyteidl_2fservice_2fidentity_2eproto() {
+ GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+ {
+ void* ptr = &::flyteidl::service::_UserInfoResponse_default_instance_;
+ new (ptr) ::flyteidl::service::UserInfoResponse();
+ ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
+ }
+ ::flyteidl::service::UserInfoResponse::InitAsDefaultInstance();
+}
+
+::google::protobuf::internal::SCCInfo<0> scc_info_UserInfoResponse_flyteidl_2fservice_2fidentity_2eproto =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsUserInfoResponse_flyteidl_2fservice_2fidentity_2eproto}, {}};
+
+void InitDefaults_flyteidl_2fservice_2fidentity_2eproto() {
+ ::google::protobuf::internal::InitSCC(&scc_info_UserInfoRequest_flyteidl_2fservice_2fidentity_2eproto.base);
+ ::google::protobuf::internal::InitSCC(&scc_info_UserInfoResponse_flyteidl_2fservice_2fidentity_2eproto.base);
+}
+
+::google::protobuf::Metadata file_level_metadata_flyteidl_2fservice_2fidentity_2eproto[2];
+constexpr ::google::protobuf::EnumDescriptor const** file_level_enum_descriptors_flyteidl_2fservice_2fidentity_2eproto = nullptr;
+constexpr ::google::protobuf::ServiceDescriptor const** file_level_service_descriptors_flyteidl_2fservice_2fidentity_2eproto = nullptr;
+
+const ::google::protobuf::uint32 TableStruct_flyteidl_2fservice_2fidentity_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
+ ~0u, // no _has_bits_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoRequest, _internal_metadata_),
+ ~0u, // no _extensions_
+ ~0u, // no _oneof_case_
+ ~0u, // no _weak_field_map_
+ ~0u, // no _has_bits_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, _internal_metadata_),
+ ~0u, // no _extensions_
+ ~0u, // no _oneof_case_
+ ~0u, // no _weak_field_map_
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, subject_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, name_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, preferred_username_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, given_name_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, family_name_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, email_),
+ PROTOBUF_FIELD_OFFSET(::flyteidl::service::UserInfoResponse, picture_),
+};
+static const ::google::protobuf::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
+ { 0, -1, sizeof(::flyteidl::service::UserInfoRequest)},
+ { 5, -1, sizeof(::flyteidl::service::UserInfoResponse)},
+};
+
+static ::google::protobuf::Message const * const file_default_instances[] = {
+ reinterpret_cast(&::flyteidl::service::_UserInfoRequest_default_instance_),
+ reinterpret_cast(&::flyteidl::service::_UserInfoResponse_default_instance_),
+};
+
+::google::protobuf::internal::AssignDescriptorsTable assign_descriptors_table_flyteidl_2fservice_2fidentity_2eproto = {
+ {}, AddDescriptors_flyteidl_2fservice_2fidentity_2eproto, "flyteidl/service/identity.proto", schemas,
+ file_default_instances, TableStruct_flyteidl_2fservice_2fidentity_2eproto::offsets,
+ file_level_metadata_flyteidl_2fservice_2fidentity_2eproto, 2, file_level_enum_descriptors_flyteidl_2fservice_2fidentity_2eproto, file_level_service_descriptors_flyteidl_2fservice_2fidentity_2eproto,
+};
+
+const char descriptor_table_protodef_flyteidl_2fservice_2fidentity_2eproto[] =
+ "\n\037flyteidl/service/identity.proto\022\020flyte"
+ "idl.service\032\034google/api/annotations.prot"
+ "o\032,protoc-gen-swagger/options/annotation"
+ "s.proto\"\021\n\017UserInfoRequest\"\226\001\n\020UserInfoR"
+ "esponse\022\017\n\007subject\030\001 \001(\t\022\014\n\004name\030\002 \001(\t\022\032"
+ "\n\022preferred_username\030\003 \001(\t\022\022\n\ngiven_name"
+ "\030\004 \001(\t\022\023\n\013family_name\030\005 \001(\t\022\r\n\005email\030\006 \001"
+ "(\t\022\017\n\007picture\030\007 \001(\t2\235\001\n\017IdentityService\022"
+ "\211\001\n\010UserInfo\022!.flyteidl.service.UserInfo"
+ "Request\032\".flyteidl.service.UserInfoRespo"
+ "nse\"6\202\323\344\223\002\005\022\003/me\222A(\032&Retrieves authentic"
+ "ated identity info.B9Z7github.com/flyteo"
+ "rg/flyteidl/gen/pb-go/flyteidl/serviceb\006"
+ "proto3"
+ ;
+::google::protobuf::internal::DescriptorTable descriptor_table_flyteidl_2fservice_2fidentity_2eproto = {
+ false, InitDefaults_flyteidl_2fservice_2fidentity_2eproto,
+ descriptor_table_protodef_flyteidl_2fservice_2fidentity_2eproto,
+ "flyteidl/service/identity.proto", &assign_descriptors_table_flyteidl_2fservice_2fidentity_2eproto, 526,
+};
+
+void AddDescriptors_flyteidl_2fservice_2fidentity_2eproto() {
+ static constexpr ::google::protobuf::internal::InitFunc deps[2] =
+ {
+ ::AddDescriptors_google_2fapi_2fannotations_2eproto,
+ ::AddDescriptors_protoc_2dgen_2dswagger_2foptions_2fannotations_2eproto,
+ };
+ ::google::protobuf::internal::AddDescriptors(&descriptor_table_flyteidl_2fservice_2fidentity_2eproto, deps, 2);
+}
+
+// Force running AddDescriptors() at dynamic initialization time.
+static bool dynamic_init_dummy_flyteidl_2fservice_2fidentity_2eproto = []() { AddDescriptors_flyteidl_2fservice_2fidentity_2eproto(); return true; }();
+namespace flyteidl {
+namespace service {
+
+// ===================================================================
+
+void UserInfoRequest::InitAsDefaultInstance() {
+}
+class UserInfoRequest::HasBitSetters {
+ public:
+};
+
+#if !defined(_MSC_VER) || _MSC_VER >= 1900
+#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
+
+UserInfoRequest::UserInfoRequest()
+ : ::google::protobuf::Message(), _internal_metadata_(nullptr) {
+ SharedCtor();
+ // @@protoc_insertion_point(constructor:flyteidl.service.UserInfoRequest)
+}
+UserInfoRequest::UserInfoRequest(const UserInfoRequest& from)
+ : ::google::protobuf::Message(),
+ _internal_metadata_(nullptr) {
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ // @@protoc_insertion_point(copy_constructor:flyteidl.service.UserInfoRequest)
+}
+
+void UserInfoRequest::SharedCtor() {
+}
+
+UserInfoRequest::~UserInfoRequest() {
+ // @@protoc_insertion_point(destructor:flyteidl.service.UserInfoRequest)
+ SharedDtor();
+}
+
+void UserInfoRequest::SharedDtor() {
+}
+
+void UserInfoRequest::SetCachedSize(int size) const {
+ _cached_size_.Set(size);
+}
+const UserInfoRequest& UserInfoRequest::default_instance() {
+ ::google::protobuf::internal::InitSCC(&::scc_info_UserInfoRequest_flyteidl_2fservice_2fidentity_2eproto.base);
+ return *internal_default_instance();
+}
+
+
+void UserInfoRequest::Clear() {
+// @@protoc_insertion_point(message_clear_start:flyteidl.service.UserInfoRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* UserInfoRequest::_InternalParse(const char* begin, const char* end, void* object,
+ ::google::protobuf::internal::ParseContext* ctx) {
+ auto msg = static_cast(object);
+ ::google::protobuf::int32 size; (void)size;
+ int depth; (void)depth;
+ ::google::protobuf::uint32 tag;
+ ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end;
+ auto ptr = begin;
+ while (ptr < end) {
+ ptr = ::google::protobuf::io::Parse32(ptr, &tag);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ switch (tag >> 3) {
+ default: {
+ if ((tag & 7) == 4 || tag == 0) {
+ ctx->EndGroup(tag);
+ return ptr;
+ }
+ auto res = UnknownFieldParse(tag, {_InternalParse, msg},
+ ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx);
+ ptr = res.first;
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr);
+ if (res.second) return ptr;
+ }
+ } // switch
+ } // while
+ return ptr;
+}
+#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool UserInfoRequest::MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+ ::google::protobuf::uint32 tag;
+ // @@protoc_insertion_point(parse_start:flyteidl.service.UserInfoRequest)
+ for (;;) {
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ tag = p.first;
+ if (!p.second) goto handle_unusual;
+ handle_unusual:
+ if (tag == 0) {
+ goto success;
+ }
+ DO_(::google::protobuf::internal::WireFormat::SkipField(
+ input, tag, _internal_metadata_.mutable_unknown_fields()));
+ }
+success:
+ // @@protoc_insertion_point(parse_success:flyteidl.service.UserInfoRequest)
+ return true;
+failure:
+ // @@protoc_insertion_point(parse_failure:flyteidl.service.UserInfoRequest)
+ return false;
+#undef DO_
+}
+#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void UserInfoRequest::SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const {
+ // @@protoc_insertion_point(serialize_start:flyteidl.service.UserInfoRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
+ _internal_metadata_.unknown_fields(), output);
+ }
+ // @@protoc_insertion_point(serialize_end:flyteidl.service.UserInfoRequest)
+}
+
+::google::protobuf::uint8* UserInfoRequest::InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const {
+ // @@protoc_insertion_point(serialize_to_array_start:flyteidl.service.UserInfoRequest)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
+ _internal_metadata_.unknown_fields(), target);
+ }
+ // @@protoc_insertion_point(serialize_to_array_end:flyteidl.service.UserInfoRequest)
+ return target;
+}
+
+size_t UserInfoRequest::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:flyteidl.service.UserInfoRequest)
+ size_t total_size = 0;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ total_size +=
+ ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
+ _internal_metadata_.unknown_fields());
+ }
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
+ SetCachedSize(cached_size);
+ return total_size;
+}
+
+void UserInfoRequest::MergeFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:flyteidl.service.UserInfoRequest)
+ GOOGLE_DCHECK_NE(&from, this);
+ const UserInfoRequest* source =
+ ::google::protobuf::DynamicCastToGenerated(
+ &from);
+ if (source == nullptr) {
+ // @@protoc_insertion_point(generalized_merge_from_cast_fail:flyteidl.service.UserInfoRequest)
+ ::google::protobuf::internal::ReflectionOps::Merge(from, this);
+ } else {
+ // @@protoc_insertion_point(generalized_merge_from_cast_success:flyteidl.service.UserInfoRequest)
+ MergeFrom(*source);
+ }
+}
+
+void UserInfoRequest::MergeFrom(const UserInfoRequest& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:flyteidl.service.UserInfoRequest)
+ GOOGLE_DCHECK_NE(&from, this);
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+}
+
+void UserInfoRequest::CopyFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:flyteidl.service.UserInfoRequest)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+void UserInfoRequest::CopyFrom(const UserInfoRequest& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:flyteidl.service.UserInfoRequest)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+bool UserInfoRequest::IsInitialized() const {
+ return true;
+}
+
+void UserInfoRequest::Swap(UserInfoRequest* other) {
+ if (other == this) return;
+ InternalSwap(other);
+}
+void UserInfoRequest::InternalSwap(UserInfoRequest* other) {
+ using std::swap;
+ _internal_metadata_.Swap(&other->_internal_metadata_);
+}
+
+::google::protobuf::Metadata UserInfoRequest::GetMetadata() const {
+ ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fservice_2fidentity_2eproto);
+ return ::file_level_metadata_flyteidl_2fservice_2fidentity_2eproto[kIndexInFileMessages];
+}
+
+
+// ===================================================================
+
+void UserInfoResponse::InitAsDefaultInstance() {
+}
+class UserInfoResponse::HasBitSetters {
+ public:
+};
+
+#if !defined(_MSC_VER) || _MSC_VER >= 1900
+const int UserInfoResponse::kSubjectFieldNumber;
+const int UserInfoResponse::kNameFieldNumber;
+const int UserInfoResponse::kPreferredUsernameFieldNumber;
+const int UserInfoResponse::kGivenNameFieldNumber;
+const int UserInfoResponse::kFamilyNameFieldNumber;
+const int UserInfoResponse::kEmailFieldNumber;
+const int UserInfoResponse::kPictureFieldNumber;
+#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
+
+UserInfoResponse::UserInfoResponse()
+ : ::google::protobuf::Message(), _internal_metadata_(nullptr) {
+ SharedCtor();
+ // @@protoc_insertion_point(constructor:flyteidl.service.UserInfoResponse)
+}
+UserInfoResponse::UserInfoResponse(const UserInfoResponse& from)
+ : ::google::protobuf::Message(),
+ _internal_metadata_(nullptr) {
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ subject_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.subject().size() > 0) {
+ subject_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.subject_);
+ }
+ name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.name().size() > 0) {
+ name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
+ }
+ preferred_username_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.preferred_username().size() > 0) {
+ preferred_username_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.preferred_username_);
+ }
+ given_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.given_name().size() > 0) {
+ given_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.given_name_);
+ }
+ family_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.family_name().size() > 0) {
+ family_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.family_name_);
+ }
+ email_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.email().size() > 0) {
+ email_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.email_);
+ }
+ picture_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ if (from.picture().size() > 0) {
+ picture_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.picture_);
+ }
+ // @@protoc_insertion_point(copy_constructor:flyteidl.service.UserInfoResponse)
+}
+
+void UserInfoResponse::SharedCtor() {
+ ::google::protobuf::internal::InitSCC(
+ &scc_info_UserInfoResponse_flyteidl_2fservice_2fidentity_2eproto.base);
+ subject_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ preferred_username_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ given_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ family_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ email_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ picture_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+
+UserInfoResponse::~UserInfoResponse() {
+ // @@protoc_insertion_point(destructor:flyteidl.service.UserInfoResponse)
+ SharedDtor();
+}
+
+void UserInfoResponse::SharedDtor() {
+ subject_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ preferred_username_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ given_name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ family_name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ email_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ picture_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+
+void UserInfoResponse::SetCachedSize(int size) const {
+ _cached_size_.Set(size);
+}
+const UserInfoResponse& UserInfoResponse::default_instance() {
+ ::google::protobuf::internal::InitSCC(&::scc_info_UserInfoResponse_flyteidl_2fservice_2fidentity_2eproto.base);
+ return *internal_default_instance();
+}
+
+
+void UserInfoResponse::Clear() {
+// @@protoc_insertion_point(message_clear_start:flyteidl.service.UserInfoResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ subject_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ preferred_username_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ given_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ family_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ email_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ picture_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+ _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* UserInfoResponse::_InternalParse(const char* begin, const char* end, void* object,
+ ::google::protobuf::internal::ParseContext* ctx) {
+ auto msg = static_cast(object);
+ ::google::protobuf::int32 size; (void)size;
+ int depth; (void)depth;
+ ::google::protobuf::uint32 tag;
+ ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end;
+ auto ptr = begin;
+ while (ptr < end) {
+ ptr = ::google::protobuf::io::Parse32(ptr, &tag);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ switch (tag >> 3) {
+ // string subject = 1;
+ case 1: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 10) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.UserInfoResponse.subject");
+ object = msg->mutable_subject();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string name = 2;
+ case 2: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 18) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.UserInfoResponse.name");
+ object = msg->mutable_name();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string preferred_username = 3;
+ case 3: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 26) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.UserInfoResponse.preferred_username");
+ object = msg->mutable_preferred_username();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string given_name = 4;
+ case 4: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 34) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.UserInfoResponse.given_name");
+ object = msg->mutable_given_name();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string family_name = 5;
+ case 5: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 42) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.UserInfoResponse.family_name");
+ object = msg->mutable_family_name();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string email = 6;
+ case 6: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 50) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.UserInfoResponse.email");
+ object = msg->mutable_email();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ // string picture = 7;
+ case 7: {
+ if (static_cast<::google::protobuf::uint8>(tag) != 58) goto handle_unusual;
+ ptr = ::google::protobuf::io::ReadSize(ptr, &size);
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
+ ctx->extra_parse_data().SetFieldName("flyteidl.service.UserInfoResponse.picture");
+ object = msg->mutable_picture();
+ if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
+ parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
+ goto string_till_end;
+ }
+ GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
+ ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
+ ptr += size;
+ break;
+ }
+ default: {
+ handle_unusual:
+ if ((tag & 7) == 4 || tag == 0) {
+ ctx->EndGroup(tag);
+ return ptr;
+ }
+ auto res = UnknownFieldParse(tag, {_InternalParse, msg},
+ ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx);
+ ptr = res.first;
+ GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr);
+ if (res.second) return ptr;
+ }
+ } // switch
+ } // while
+ return ptr;
+string_till_end:
+ static_cast<::std::string*>(object)->clear();
+ static_cast<::std::string*>(object)->reserve(size);
+ goto len_delim_till_end;
+len_delim_till_end:
+ return ctx->StoreAndTailCall(ptr, end, {_InternalParse, msg},
+ {parser_till_end, object}, size);
+}
+#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool UserInfoResponse::MergePartialFromCodedStream(
+ ::google::protobuf::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+ ::google::protobuf::uint32 tag;
+ // @@protoc_insertion_point(parse_start:flyteidl.service.UserInfoResponse)
+ for (;;) {
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ tag = p.first;
+ if (!p.second) goto handle_unusual;
+ switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
+ // string subject = 1;
+ case 1: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (10 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_subject()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->subject().data(), static_cast(this->subject().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.UserInfoResponse.subject"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string name = 2;
+ case 2: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (18 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_name()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->name().data(), static_cast(this->name().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.UserInfoResponse.name"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string preferred_username = 3;
+ case 3: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (26 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_preferred_username()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->preferred_username().data(), static_cast(this->preferred_username().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.UserInfoResponse.preferred_username"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string given_name = 4;
+ case 4: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (34 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_given_name()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->given_name().data(), static_cast(this->given_name().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.UserInfoResponse.given_name"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string family_name = 5;
+ case 5: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (42 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_family_name()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->family_name().data(), static_cast(this->family_name().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.UserInfoResponse.family_name"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string email = 6;
+ case 6: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (50 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_email()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->email().data(), static_cast(this->email().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.UserInfoResponse.email"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ // string picture = 7;
+ case 7: {
+ if (static_cast< ::google::protobuf::uint8>(tag) == (58 & 0xFF)) {
+ DO_(::google::protobuf::internal::WireFormatLite::ReadString(
+ input, this->mutable_picture()));
+ DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->picture().data(), static_cast(this->picture().length()),
+ ::google::protobuf::internal::WireFormatLite::PARSE,
+ "flyteidl.service.UserInfoResponse.picture"));
+ } else {
+ goto handle_unusual;
+ }
+ break;
+ }
+
+ default: {
+ handle_unusual:
+ if (tag == 0) {
+ goto success;
+ }
+ DO_(::google::protobuf::internal::WireFormat::SkipField(
+ input, tag, _internal_metadata_.mutable_unknown_fields()));
+ break;
+ }
+ }
+ }
+success:
+ // @@protoc_insertion_point(parse_success:flyteidl.service.UserInfoResponse)
+ return true;
+failure:
+ // @@protoc_insertion_point(parse_failure:flyteidl.service.UserInfoResponse)
+ return false;
+#undef DO_
+}
+#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void UserInfoResponse::SerializeWithCachedSizes(
+ ::google::protobuf::io::CodedOutputStream* output) const {
+ // @@protoc_insertion_point(serialize_start:flyteidl.service.UserInfoResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ // string subject = 1;
+ if (this->subject().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->subject().data(), static_cast(this->subject().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.subject");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 1, this->subject(), output);
+ }
+
+ // string name = 2;
+ if (this->name().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->name().data(), static_cast(this->name().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.name");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 2, this->name(), output);
+ }
+
+ // string preferred_username = 3;
+ if (this->preferred_username().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->preferred_username().data(), static_cast(this->preferred_username().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.preferred_username");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 3, this->preferred_username(), output);
+ }
+
+ // string given_name = 4;
+ if (this->given_name().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->given_name().data(), static_cast(this->given_name().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.given_name");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 4, this->given_name(), output);
+ }
+
+ // string family_name = 5;
+ if (this->family_name().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->family_name().data(), static_cast(this->family_name().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.family_name");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 5, this->family_name(), output);
+ }
+
+ // string email = 6;
+ if (this->email().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->email().data(), static_cast(this->email().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.email");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 6, this->email(), output);
+ }
+
+ // string picture = 7;
+ if (this->picture().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->picture().data(), static_cast(this->picture().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.picture");
+ ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
+ 7, this->picture(), output);
+ }
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
+ _internal_metadata_.unknown_fields(), output);
+ }
+ // @@protoc_insertion_point(serialize_end:flyteidl.service.UserInfoResponse)
+}
+
+::google::protobuf::uint8* UserInfoResponse::InternalSerializeWithCachedSizesToArray(
+ ::google::protobuf::uint8* target) const {
+ // @@protoc_insertion_point(serialize_to_array_start:flyteidl.service.UserInfoResponse)
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ // string subject = 1;
+ if (this->subject().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->subject().data(), static_cast(this->subject().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.subject");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 1, this->subject(), target);
+ }
+
+ // string name = 2;
+ if (this->name().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->name().data(), static_cast(this->name().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.name");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 2, this->name(), target);
+ }
+
+ // string preferred_username = 3;
+ if (this->preferred_username().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->preferred_username().data(), static_cast(this->preferred_username().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.preferred_username");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 3, this->preferred_username(), target);
+ }
+
+ // string given_name = 4;
+ if (this->given_name().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->given_name().data(), static_cast(this->given_name().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.given_name");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 4, this->given_name(), target);
+ }
+
+ // string family_name = 5;
+ if (this->family_name().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->family_name().data(), static_cast(this->family_name().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.family_name");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 5, this->family_name(), target);
+ }
+
+ // string email = 6;
+ if (this->email().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->email().data(), static_cast(this->email().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.email");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 6, this->email(), target);
+ }
+
+ // string picture = 7;
+ if (this->picture().size() > 0) {
+ ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
+ this->picture().data(), static_cast(this->picture().length()),
+ ::google::protobuf::internal::WireFormatLite::SERIALIZE,
+ "flyteidl.service.UserInfoResponse.picture");
+ target =
+ ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
+ 7, this->picture(), target);
+ }
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
+ _internal_metadata_.unknown_fields(), target);
+ }
+ // @@protoc_insertion_point(serialize_to_array_end:flyteidl.service.UserInfoResponse)
+ return target;
+}
+
+size_t UserInfoResponse::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:flyteidl.service.UserInfoResponse)
+ size_t total_size = 0;
+
+ if (_internal_metadata_.have_unknown_fields()) {
+ total_size +=
+ ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
+ _internal_metadata_.unknown_fields());
+ }
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ // Prevent compiler warnings about cached_has_bits being unused
+ (void) cached_has_bits;
+
+ // string subject = 1;
+ if (this->subject().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->subject());
+ }
+
+ // string name = 2;
+ if (this->name().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->name());
+ }
+
+ // string preferred_username = 3;
+ if (this->preferred_username().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->preferred_username());
+ }
+
+ // string given_name = 4;
+ if (this->given_name().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->given_name());
+ }
+
+ // string family_name = 5;
+ if (this->family_name().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->family_name());
+ }
+
+ // string email = 6;
+ if (this->email().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->email());
+ }
+
+ // string picture = 7;
+ if (this->picture().size() > 0) {
+ total_size += 1 +
+ ::google::protobuf::internal::WireFormatLite::StringSize(
+ this->picture());
+ }
+
+ int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
+ SetCachedSize(cached_size);
+ return total_size;
+}
+
+void UserInfoResponse::MergeFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:flyteidl.service.UserInfoResponse)
+ GOOGLE_DCHECK_NE(&from, this);
+ const UserInfoResponse* source =
+ ::google::protobuf::DynamicCastToGenerated(
+ &from);
+ if (source == nullptr) {
+ // @@protoc_insertion_point(generalized_merge_from_cast_fail:flyteidl.service.UserInfoResponse)
+ ::google::protobuf::internal::ReflectionOps::Merge(from, this);
+ } else {
+ // @@protoc_insertion_point(generalized_merge_from_cast_success:flyteidl.service.UserInfoResponse)
+ MergeFrom(*source);
+ }
+}
+
+void UserInfoResponse::MergeFrom(const UserInfoResponse& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:flyteidl.service.UserInfoResponse)
+ GOOGLE_DCHECK_NE(&from, this);
+ _internal_metadata_.MergeFrom(from._internal_metadata_);
+ ::google::protobuf::uint32 cached_has_bits = 0;
+ (void) cached_has_bits;
+
+ if (from.subject().size() > 0) {
+
+ subject_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.subject_);
+ }
+ if (from.name().size() > 0) {
+
+ name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
+ }
+ if (from.preferred_username().size() > 0) {
+
+ preferred_username_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.preferred_username_);
+ }
+ if (from.given_name().size() > 0) {
+
+ given_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.given_name_);
+ }
+ if (from.family_name().size() > 0) {
+
+ family_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.family_name_);
+ }
+ if (from.email().size() > 0) {
+
+ email_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.email_);
+ }
+ if (from.picture().size() > 0) {
+
+ picture_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.picture_);
+ }
+}
+
+void UserInfoResponse::CopyFrom(const ::google::protobuf::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:flyteidl.service.UserInfoResponse)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+void UserInfoResponse::CopyFrom(const UserInfoResponse& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:flyteidl.service.UserInfoResponse)
+ if (&from == this) return;
+ Clear();
+ MergeFrom(from);
+}
+
+bool UserInfoResponse::IsInitialized() const {
+ return true;
+}
+
+void UserInfoResponse::Swap(UserInfoResponse* other) {
+ if (other == this) return;
+ InternalSwap(other);
+}
+void UserInfoResponse::InternalSwap(UserInfoResponse* other) {
+ using std::swap;
+ _internal_metadata_.Swap(&other->_internal_metadata_);
+ subject_.Swap(&other->subject_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ preferred_username_.Swap(&other->preferred_username_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ given_name_.Swap(&other->given_name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ family_name_.Swap(&other->family_name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ email_.Swap(&other->email_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ picture_.Swap(&other->picture_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+}
+
+::google::protobuf::Metadata UserInfoResponse::GetMetadata() const {
+ ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fservice_2fidentity_2eproto);
+ return ::file_level_metadata_flyteidl_2fservice_2fidentity_2eproto[kIndexInFileMessages];
+}
+
+
+// @@protoc_insertion_point(namespace_scope)
+} // namespace service
+} // namespace flyteidl
+namespace google {
+namespace protobuf {
+template<> PROTOBUF_NOINLINE ::flyteidl::service::UserInfoRequest* Arena::CreateMaybeMessage< ::flyteidl::service::UserInfoRequest >(Arena* arena) {
+ return Arena::CreateInternal< ::flyteidl::service::UserInfoRequest >(arena);
+}
+template<> PROTOBUF_NOINLINE ::flyteidl::service::UserInfoResponse* Arena::CreateMaybeMessage< ::flyteidl::service::UserInfoResponse >(Arena* arena) {
+ return Arena::CreateInternal< ::flyteidl::service::UserInfoResponse >(arena);
+}
+} // namespace protobuf
+} // namespace google
+
+// @@protoc_insertion_point(global_scope)
+#include