fix: add action v2 execution to features (#7597)

* fix: add action v2 execution to features

* fix: add action v2 execution to features

* fix: add action v2 execution to features

* fix: update internal/command/instance_features_model.go

Co-authored-by: Tim Möhlmann <tim+github@zitadel.com>

* fix: merge back main

* fix: merge back main

* fix: rename feature and service

* fix: rename feature and service

* fix: review changes

* fix: review changes

---------

Co-authored-by: Tim Möhlmann <tim+github@zitadel.com>
This commit is contained in:
Stefan Benz
2024-04-09 19:21:21 +02:00
committed by GitHub
parent 6a51c4b0f5
commit 6dcdef0268
52 changed files with 1069 additions and 737 deletions

View File

@@ -1,6 +1,6 @@
syntax = "proto3";
package zitadel.execution.v3alpha;
package zitadel.action.v3alpha;
import "google/api/annotations.proto";
import "google/api/field_behavior.proto";
@@ -8,17 +8,17 @@ import "google/protobuf/duration.proto";
import "google/protobuf/struct.proto";
import "protoc-gen-openapiv2/options/annotations.proto";
import "validate/validate.proto";
import "zitadel/execution/v3alpha/target.proto";
import "zitadel/execution/v3alpha/execution.proto";
import "zitadel/execution/v3alpha/query.proto";
import "zitadel/action/v3alpha/target.proto";
import "zitadel/action/v3alpha/execution.proto";
import "zitadel/action/v3alpha/query.proto";
import "zitadel/object/v2beta/object.proto";
import "zitadel/protoc_gen_zitadel/v2/options.proto";
option go_package = "github.com/zitadel/zitadel/pkg/grpc/execution/v3alpha;execution";
option go_package = "github.com/zitadel/zitadel/pkg/grpc/action/v3alpha;action";
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_swagger) = {
info: {
title: "Execution Service";
title: "Action Service";
version: "3.0-preview";
description: "This API is intended to manage custom executions (previously known as actions) in a ZITADEL instance. This project is in preview state. It can AND will continue breaking until the services provide the same functionality as the current actions.";
contact:{
@@ -104,7 +104,7 @@ option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_swagger) = {
}
};
service ExecutionService {
service ActionService {
// Create a target
//
@@ -516,22 +516,22 @@ message ListTargetsRequest {
// list limitations and ordering.
zitadel.object.v2beta.ListQuery query = 1;
// the field the result is sorted.
zitadel.execution.v3alpha.TargetFieldName sorting_column = 2 [
zitadel.action.v3alpha.TargetFieldName sorting_column = 2 [
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "\"FIELD_NAME_SCHEMA_TYPE\""
}
];
// Define the criteria to query for.
repeated zitadel.execution.v3alpha.TargetSearchQuery queries = 3;
repeated zitadel.action.v3alpha.TargetSearchQuery queries = 3;
}
message ListTargetsResponse {
// Details provides information about the returned result including total amount found.
zitadel.object.v2beta.ListDetails details = 1;
// States by which field the results are sorted.
zitadel.execution.v3alpha.TargetFieldName sorting_column = 2;
zitadel.action.v3alpha.TargetFieldName sorting_column = 2;
// The result contains the user schemas, which matched the queries.
repeated zitadel.execution.v3alpha.Target result = 3;
repeated zitadel.action.v3alpha.Target result = 3;
}
message GetTargetByIDRequest {
@@ -548,7 +548,7 @@ message GetTargetByIDRequest {
}
message GetTargetByIDResponse {
zitadel.execution.v3alpha.Target target = 1;
zitadel.action.v3alpha.Target target = 1;
}
message SetExecutionRequest {
@@ -579,14 +579,14 @@ message ListExecutionsRequest {
// list limitations and ordering.
zitadel.object.v2beta.ListQuery query = 1;
// Define the criteria to query for.
repeated zitadel.execution.v3alpha.SearchQuery queries = 2;
repeated zitadel.action.v3alpha.SearchQuery queries = 2;
}
message ListExecutionsResponse {
// Details provides information about the returned result including total amount found.
zitadel.object.v2beta.ListDetails details = 1;
// The result contains the executions, which matched the queries.
repeated zitadel.execution.v3alpha.Execution result = 2;
repeated zitadel.action.v3alpha.Execution result = 2;
}
message ListExecutionFunctionsRequest{}

View File

@@ -1,6 +1,6 @@
syntax = "proto3";
package zitadel.execution.v3alpha;
package zitadel.action.v3alpha;
import "google/api/annotations.proto";
import "google/api/field_behavior.proto";
@@ -11,7 +11,7 @@ import "validate/validate.proto";
import "zitadel/object/v2beta/object.proto";
import "zitadel/protoc_gen_zitadel/v2/options.proto";
option go_package = "github.com/zitadel/zitadel/pkg/grpc/execution/v3alpha;execution";
option go_package = "github.com/zitadel/zitadel/pkg/grpc/action/v3alpha;action";
message Execution {
string execution_id = 1 [

View File

@@ -1,14 +1,14 @@
syntax = "proto3";
package zitadel.execution.v3alpha;
package zitadel.action.v3alpha;
option go_package = "github.com/zitadel/zitadel/pkg/grpc/execution/v3alpha;execution";
option go_package = "github.com/zitadel/zitadel/pkg/grpc/action/v3alpha;action";
import "google/api/field_behavior.proto";
import "protoc-gen-openapiv2/options/annotations.proto";
import "validate/validate.proto";
import "zitadel/object/v2beta/object.proto";
import "zitadel/execution/v3alpha/execution.proto";
import "zitadel/action/v3alpha/execution.proto";
message SearchQuery {
oneof query {

View File

@@ -1,6 +1,6 @@
syntax = "proto3";
package zitadel.execution.v3alpha;
package zitadel.action.v3alpha;
import "google/api/annotations.proto";
import "google/api/field_behavior.proto";
@@ -11,7 +11,7 @@ import "validate/validate.proto";
import "zitadel/object/v2beta/object.proto";
import "zitadel/protoc_gen_zitadel/v2/options.proto";
option go_package = "github.com/zitadel/zitadel/pkg/grpc/execution/v3alpha;execution";
option go_package = "github.com/zitadel/zitadel/pkg/grpc/action/v3alpha;action";
message SetRESTWebhook {
string url = 1 [

View File

@@ -43,6 +43,12 @@ message SetInstanceFeaturesRequest{
description: "Enable the experimental `urn:ietf:params:oauth:grant-type:token-exchange` grant type for the OIDC token endpoint. Token exchange can be used to request tokens with a lesser scope or impersonate other users. See the security policy to allow impersonation on an instance.";
}
];
optional bool actions = 6 [
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "true";
description: "Actions allow to manage data executions and targets. If the flag is enabled, you'll be able to use the new API and its features. Note that it is still in an early stage.";
}
];
}
message SetInstanceFeaturesResponse {
@@ -100,4 +106,11 @@ message GetInstanceFeaturesResponse {
description: "Enable the experimental `urn:ietf:params:oauth:grant-type:token-exchange` grant type for the OIDC token endpoint. Token exchange can be used to request tokens with a lesser scope or impersonate other users. See the security policy to allow impersonation on an instance.";
}
];
FeatureFlag actions = 7 [
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "true";
description: "Actions v2 allow to manage data executions and targets. If the flag is enabled, you'll be able to use the new API and its features. Note that it is still in an early stage.";
}
];
}

View File

@@ -45,7 +45,14 @@ message SetSystemFeaturesRequest{
description: "Enable the experimental `urn:ietf:params:oauth:grant-type:token-exchange` grant type for the OIDC token endpoint. Token exchange can be used to request tokens with a lesser scope or impersonate other users. See the security policy to allow impersonation on an instance.";
}
];
optional bool actions = 6 [
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "true";
description: "Actions allow to manage data executions and targets. If the flag is enabled, you'll be able to use the new API and its features. Note that it is still in an early stage.";
}
];
}
message SetSystemFeaturesResponse {
@@ -96,4 +103,11 @@ message GetSystemFeaturesResponse {
description: "Enable the experimental `urn:ietf:params:oauth:grant-type:token-exchange` grant type for the OIDC token endpoint. Token exchange can be used to request tokens with a lesser scope or impersonate other users. See the security policy to allow impersonation on an instance.";
}
];
FeatureFlag actions = 7 [
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "true";
description: "Actions v2 allow to manage data executions and targets. If the flag is enabled, you'll be able to use the new API and its features. Note that it is still in an early stage.";
}
];
}