diff --git a/CHANGELOG.md b/CHANGELOG.md index 96dc9a20..9eb11e34 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## 11.1 +* Remove deprecation on `status` values `TO_REVIEW`, `REVIEWED` and related usages +* Remove deprecation on `resolution` values `FIXED`, `SAFE`, `ACKNOWLEDGED` and related usages +* Indicate that `status` and `resolution` are not deprecated for hotspots + ## 11.0 * Remove usage of `javax-servlet-api`: * Remove ~~`org.sonar.api.web.ServletFilter`~~ diff --git a/plugin-api/src/main/java/org/sonar/api/issue/Issue.java b/plugin-api/src/main/java/org/sonar/api/issue/Issue.java index 4220b61d..b3d56a85 100644 --- a/plugin-api/src/main/java/org/sonar/api/issue/Issue.java +++ b/plugin-api/src/main/java/org/sonar/api/issue/Issue.java @@ -71,10 +71,7 @@ public interface Issue extends Serializable { */ @Deprecated(since = "10.4") String STATUS_CLOSED = "CLOSED"; - /** - * @deprecated since 10.4 in favor of {@link IssueStatus} - */ - @Deprecated(since = "10.4") + String RESOLUTION_FIXED = "FIXED"; /** @@ -103,18 +100,14 @@ public interface Issue extends Serializable { /** * Security Hotspot has been reviewed and resolved as safe. - * @deprecated since 10.4 as Security Hotspot are deprecated. * @since 8.1 */ - @Deprecated(since = "10.4") String RESOLUTION_SAFE = "SAFE"; /** * Security Hotspot has been reviewed and acknowledged that it poses a risk. - * @deprecated since 10.4 as Security Hotspot are deprecated. * @since 9.4 */ - @Deprecated(since = "10.4") String RESOLUTION_ACKNOWLEDGED = "ACKNOWLEDGED"; /** @@ -124,16 +117,8 @@ public interface Issue extends Serializable { List RESOLUTIONS = List.of(RESOLUTION_FALSE_POSITIVE, RESOLUTION_WONT_FIX, RESOLUTION_FIXED, RESOLUTION_REMOVED); - /** - * @deprecated since 10.4 as Security Hotspot are deprecated - */ - @Deprecated(since = "10.4") List SECURITY_HOTSPOT_RESOLUTIONS = List.of(RESOLUTION_FIXED, RESOLUTION_SAFE, RESOLUTION_ACKNOWLEDGED); - /** - * @deprecated since 10.4 as Security Hotspot are deprecated - */ - @Deprecated(since = "10.4") String STATUS_TO_REVIEW = "TO_REVIEW"; /** @@ -142,10 +127,6 @@ public interface Issue extends Serializable { @Deprecated(since = "8.1") String STATUS_IN_REVIEW = "IN_REVIEW"; - /** - * @deprecated since 10.4 as Security Hotspot are deprecated - */ - @Deprecated(since = "10.4") String STATUS_REVIEWED = "REVIEWED"; /** @@ -205,14 +186,14 @@ public interface Issue extends Serializable { /** * See constant values in {@link Issue}. - * @deprecated since 10.4 in favor of {@link IssueStatus} + * @deprecated since 10.4 in favor of {@link IssueStatus}. Not deprecated for hotspots */ @Deprecated(since = "10.4") String status(); /** * The type of resolution, or null if the issue is not resolved. See constant values in {@link Issue}. - * @deprecated since 10.4 in favor of {@link IssueStatus} + * @deprecated since 10.4 in favor of {@link IssueStatus}. Not deprecated for hotspots */ @CheckForNull @Deprecated(since = "10.4") diff --git a/plugin-api/src/main/java/org/sonar/api/issue/IssueStatus.java b/plugin-api/src/main/java/org/sonar/api/issue/IssueStatus.java index f1366d5d..aaae5533 100644 --- a/plugin-api/src/main/java/org/sonar/api/issue/IssueStatus.java +++ b/plugin-api/src/main/java/org/sonar/api/issue/IssueStatus.java @@ -60,7 +60,7 @@ public static IssueStatus of(@Nullable String status, @Nullable String resolutio return IssueStatus.CONFIRMED; case Issue.STATUS_CLOSED: return IssueStatus.FIXED; - // Security hotspot should not return issue status as they are deprecated. + // Security hotspot should not return issue status. case Issue.STATUS_REVIEWED: case Issue.STATUS_TO_REVIEW: return null;