Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
fd655755
Commit
fd655755
authored
Jan 10, 2022
by
Tiger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Deprecate agent token deletion mutation
Changelog: other
parent
82253cc6
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
2 deletions
+14
-2
app/graphql/types/deprecated_mutations.rb
app/graphql/types/deprecated_mutations.rb
+2
-1
app/graphql/types/mutation_type.rb
app/graphql/types/mutation_type.rb
+0
-1
doc/api/graphql/reference/index.md
doc/api/graphql/reference/index.md
+4
-0
spec/graphql/types/mutation_type_spec.rb
spec/graphql/types/mutation_type_spec.rb
+8
-0
No files found.
app/graphql/types/deprecated_mutations.rb
View file @
fd655755
...
...
@@ -5,7 +5,8 @@ module Types
extend
ActiveSupport
::
Concern
prepended
do
# placeholder for any FOSS mutations to be deprecated
mount_mutation
Mutations
::
Clusters
::
AgentTokens
::
Delete
,
deprecated:
{
reason:
'Tokens must be revoked with ClusterAgentTokenRevoke'
,
milestone:
'14.7'
}
end
end
end
app/graphql/types/mutation_type.rb
View file @
fd655755
...
...
@@ -35,7 +35,6 @@ module Types
mount_mutation
Mutations
::
Clusters
::
Agents
::
Create
mount_mutation
Mutations
::
Clusters
::
Agents
::
Delete
mount_mutation
Mutations
::
Clusters
::
AgentTokens
::
Create
mount_mutation
Mutations
::
Clusters
::
AgentTokens
::
Delete
mount_mutation
Mutations
::
Clusters
::
AgentTokens
::
Revoke
mount_mutation
Mutations
::
Commits
::
Create
,
calls_gitaly:
true
mount_mutation
Mutations
::
CustomEmoji
::
Create
,
feature_flag: :custom_emoji
...
...
doc/api/graphql/reference/index.md
View file @
fd655755
...
...
@@ -954,6 +954,10 @@ Input type: `ClusterAgentTokenCreateInput`
### `Mutation.clusterAgentTokenDelete`
WARNING:
**Deprecated** in 14.7.
Tokens must be revoked with ClusterAgentTokenRevoke.
Input type: `ClusterAgentTokenDeleteInput`
#### Arguments
spec/graphql/types/mutation_type_spec.rb
View file @
fd655755
...
...
@@ -7,6 +7,14 @@ RSpec.describe Types::MutationType do
expect
(
described_class
).
to
have_graphql_mutation
(
Mutations
::
MergeRequests
::
SetDraft
)
end
describe
'deprecated mutations'
do
describe
'clusterAgentTokenDelete'
do
let
(
:field
)
{
get_field
(
'clusterAgentTokenDelete'
)
}
it
{
expect
(
field
.
deprecation_reason
).
to
eq
(
'Tokens must be revoked with ClusterAgentTokenRevoke. Deprecated in 14.7.'
)
}
end
end
def
get_field
(
name
)
described_class
.
fields
[
GraphqlHelpers
.
fieldnamerize
(
name
)]
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment