mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
[Security Solution] Show deprecated bulk endpoints in Upgrade Assistant: some clean-up (#209545)
**Addresses:** https://github.com/elastic/kibana/issues/193184 **Is a follow-up to:** https://github.com/elastic/kibana/pull/207091, https://github.com/elastic/kibana/pull/208090, https://github.com/elastic/kibana/pull/207906 ## Summary This PR follows after our recent changes made to the Upgrade Assistant and does some minor cleanup: - The doc link is renamed to `legacyRuleManagementBulkApiDeprecations` for the sake of being more specific. - The deprecation level is changed to `warning` in accordance to what we have in `8.x` and `8.18`.
This commit is contained in:
parent
e21c5d0e91
commit
262969d15d
6 changed files with 22 additions and 12 deletions
|
@ -454,7 +454,7 @@ export const getDocLinks = ({ kibanaBranch, buildFlavor }: GetDocLinkOptions): D
|
|||
aiAssistant: `${SECURITY_SOLUTION_DOCS}security-assistant.html`,
|
||||
signalsMigrationApi: `${SECURITY_SOLUTION_DOCS}signals-migration-api.html`,
|
||||
legacyEndpointManagementApiDeprecations: `${KIBANA_DOCS}breaking-changes-summary.html#breaking-199598`,
|
||||
legacyBulkApiDeprecations: `${KIBANA_DOCS}breaking-changes-summary.html#breaking-207091`,
|
||||
legacyRuleManagementBulkApiDeprecations: `${KIBANA_DOCS}breaking-changes-summary.html#breaking-207091`,
|
||||
},
|
||||
query: {
|
||||
eql: `${ELASTICSEARCH_DOCS}eql.html`,
|
||||
|
|
|
@ -319,7 +319,7 @@ export interface DocLinks {
|
|||
readonly detectionEngineOverview: string;
|
||||
readonly signalsMigrationApi: string;
|
||||
readonly legacyEndpointManagementApiDeprecations: string;
|
||||
readonly legacyBulkApiDeprecations: string;
|
||||
readonly legacyRuleManagementBulkApiDeprecations: string;
|
||||
};
|
||||
readonly query: {
|
||||
readonly eql: string;
|
||||
|
|
|
@ -42,6 +42,8 @@ export const bulkCreateRulesRoute = (
|
|||
logger: Logger,
|
||||
docLinks: DocLinksServiceSetup
|
||||
) => {
|
||||
const securityDocLinks = docLinks.links.securitySolution;
|
||||
|
||||
router.versioned
|
||||
.post({
|
||||
access: 'public',
|
||||
|
@ -67,8 +69,8 @@ export const bulkCreateRulesRoute = (
|
|||
},
|
||||
options: {
|
||||
deprecated: {
|
||||
documentationUrl: docLinks.links.securitySolution.legacyBulkApiDeprecations,
|
||||
severity: 'critical',
|
||||
documentationUrl: securityDocLinks.legacyRuleManagementBulkApiDeprecations,
|
||||
severity: 'warning',
|
||||
reason: {
|
||||
type: 'migrate',
|
||||
newApiMethod: 'POST',
|
||||
|
|
|
@ -132,6 +132,9 @@ export const bulkDeleteRulesRoute = (
|
|||
authz: { requiredPrivileges: ['securitySolution'] },
|
||||
},
|
||||
};
|
||||
|
||||
const securityDocLinks = docLinks.links.securitySolution;
|
||||
|
||||
router.versioned.delete(routeConfig).addVersion(
|
||||
{
|
||||
version: '2023-10-31',
|
||||
|
@ -142,8 +145,8 @@ export const bulkDeleteRulesRoute = (
|
|||
},
|
||||
options: {
|
||||
deprecated: {
|
||||
documentationUrl: docLinks.links.securitySolution.legacyBulkApiDeprecations,
|
||||
severity: 'critical',
|
||||
documentationUrl: securityDocLinks.legacyRuleManagementBulkApiDeprecations,
|
||||
severity: 'warning',
|
||||
reason: {
|
||||
type: 'migrate',
|
||||
newApiMethod: 'POST',
|
||||
|
@ -154,6 +157,7 @@ export const bulkDeleteRulesRoute = (
|
|||
},
|
||||
handler
|
||||
);
|
||||
|
||||
router.versioned.post(routeConfig).addVersion(
|
||||
{
|
||||
version: '2023-10-31',
|
||||
|
@ -164,8 +168,8 @@ export const bulkDeleteRulesRoute = (
|
|||
},
|
||||
options: {
|
||||
deprecated: {
|
||||
documentationUrl: docLinks.links.securitySolution.legacyBulkApiDeprecations,
|
||||
severity: 'critical',
|
||||
documentationUrl: securityDocLinks.legacyRuleManagementBulkApiDeprecations,
|
||||
severity: 'warning',
|
||||
reason: {
|
||||
type: 'migrate',
|
||||
newApiMethod: 'POST',
|
||||
|
|
|
@ -36,6 +36,8 @@ export const bulkPatchRulesRoute = (
|
|||
logger: Logger,
|
||||
docLinks: DocLinksServiceSetup
|
||||
) => {
|
||||
const securityDocLinks = docLinks.links.securitySolution;
|
||||
|
||||
router.versioned
|
||||
.patch({
|
||||
access: 'public',
|
||||
|
@ -61,8 +63,8 @@ export const bulkPatchRulesRoute = (
|
|||
},
|
||||
options: {
|
||||
deprecated: {
|
||||
documentationUrl: docLinks.links.securitySolution.legacyBulkApiDeprecations,
|
||||
severity: 'critical',
|
||||
documentationUrl: securityDocLinks.legacyRuleManagementBulkApiDeprecations,
|
||||
severity: 'warning',
|
||||
reason: {
|
||||
type: 'migrate',
|
||||
newApiMethod: 'POST',
|
||||
|
|
|
@ -40,6 +40,8 @@ export const bulkUpdateRulesRoute = (
|
|||
logger: Logger,
|
||||
docLinks: DocLinksServiceSetup
|
||||
) => {
|
||||
const securityDocLinks = docLinks.links.securitySolution;
|
||||
|
||||
router.versioned
|
||||
.put({
|
||||
access: 'public',
|
||||
|
@ -65,8 +67,8 @@ export const bulkUpdateRulesRoute = (
|
|||
},
|
||||
options: {
|
||||
deprecated: {
|
||||
documentationUrl: docLinks.links.securitySolution.legacyBulkApiDeprecations,
|
||||
severity: 'critical',
|
||||
documentationUrl: securityDocLinks.legacyRuleManagementBulkApiDeprecations,
|
||||
severity: 'warning',
|
||||
reason: {
|
||||
type: 'migrate',
|
||||
newApiMethod: 'POST',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue