debian-mirror-gitlab/lib/gitlab/global_id/deprecations.rb

30 lines
1,009 B
Ruby
Raw Normal View History

2021-09-04 01:27:46 +05:30
# frozen_string_literal: true
module Gitlab
module GlobalId
module Deprecations
# Contains the deprecations in place.
# Example:
#
# DEPRECATIONS = [
2022-08-27 11:52:29 +05:30
# Gitlab::Graphql::DeprecationsBase::NameDeprecation.new(old_name: 'PrometheusService', new_name: 'Integrations::Prometheus', milestone: '14.1')
2021-09-04 01:27:46 +05:30
# ].freeze
DEPRECATIONS = [
# This works around an accidentally released argument named as `"EEIterationID"` in 7000489db.
2022-08-27 11:52:29 +05:30
Gitlab::Graphql::DeprecationsBase::NameDeprecation.new(
old_name: 'EEIteration', new_name: 'Iteration', milestone: '13.3'
),
Gitlab::Graphql::DeprecationsBase::NameDeprecation.new(
old_name: 'PrometheusService', new_name: 'Integrations::Prometheus', milestone: '14.1'
)
2021-09-04 01:27:46 +05:30
].freeze
2022-08-27 11:52:29 +05:30
def self.map_graphql_name(model_name)
Types::GlobalIDType.model_name_to_graphql_name(model_name)
2021-09-04 01:27:46 +05:30
end
2022-08-27 11:52:29 +05:30
include Gitlab::Graphql::DeprecationsBase
2021-09-04 01:27:46 +05:30
end
end
end