Cloud Manager code quality · Java code rules (SonarQube) · updated
java:S1874: Do not use Experience Manager deprecated APIs (deprecated API removal)
In Cloud Manager, java:S1874 flags uses of AEM APIs that Adobe has deprecated with a removal date, and its severity rises from Info to Minor to Major as that date approaches. Replace each use with the API Adobe names before the removal date; after it, builds that still use the API fail.
| Rule key | java:S1874 |
|---|---|
| Adobe's rule name | Do not use Experience Manager deprecated APIs (deprecated API removal) |
| Type | Vulnerability or Bug · Cloud Service Compatibility |
| Severity | Info, Minor or Major |
| Since | 2026.1.0 |
| Checked by | SonarQube analysis of your Java code |
Why Cloud Manager flags it
S1874 is SonarQube's general 'deprecated code should not be used' rule. Adobe added it to the Cloud Manager rule set in release 2026.1.0, scoped to Experience Manager APIs that are marked for removal, and made it the main early warning before removals. It differs from AMSCORE-553, which covers APIs deprecated only in the AEM context with no removal date.
The rule page gives no code examples because the replacement depends on the API. Adobe's 'Deprecated and removed features' page lists each API, its removal date and its replacement; our deprecated APIs pages break those down one by one.
How to work through the list
| Severity shown | What it means | What to do |
|---|---|---|
| Info | Removal date is far off | Plan the change in the normal backlog |
| Minor | Removal date is getting closer | Schedule it this quarter |
| Major | Removal is near | Fix now: it counts against the Security or Reliability rating |
| Build fails | The API is gone | The pipeline cannot pass until it is replaced |
How to fix it
- Export the code quality report from Cloud Manager and filter for java:S1874.
- Group findings by API package (Guava, commons-lang 2, Sling Commons JSON, org.json and so on); one library swap usually clears many rows.
- Use the replacement Adobe names on its deprecated features page, and remove the old library from the bundle's imports.
- Re-run code quality and confirm the count is falling before the next removal date.
Does it stop the pipeline?
Adobe raises the severity from Info to Minor to Major as the API's removal date gets closer. At Major it counts against the Security or Reliability rating; after the removal date the build itself fails because the API is gone. Adobe also tags it Cloud Service Compatibility, so it is counted in that info metric of the report.
If a finding is a genuine false positive, Adobe's code quality page lets you annotate the code with @SuppressWarnings and the rule ID. In a full-stack pipeline, important failures can be overridden by a deployment manager, project manager or business lead; in a code-quality-only pipeline they cannot.
Related pages on this site
Questions
What is the difference between java:S1874 and AMSCORE-553?
java:S1874 covers AEM APIs with a removal date and gets more severe over time. AMSCORE-553 covers APIs deprecated only in the AEM context, without that schedule, and stays a minor code smell.
Why does the severity of the same finding change between runs?
Adobe ties it to the removal date. A finding that was Info last quarter can be Major now without any code change.
Can the free scan list these before Cloud Manager does?
Yes. The Surge Migrate readiness scan runs in your browser on a repository zip and flags removed and scheduled-for-removal APIs with file, line and fix.
See the Cloud Service blockers in your code before Cloud Manager shows them. The free Surge Migrate readiness scan reads a repository zip or a Best Practices Analyzer CSV in your browser and lists them with file, fix and effort. Nothing is uploaded.
Sources
- Adobe: Custom code quality rules (checked 10 Nov 2026)
- Adobe: Code quality testing in Cloud Manager (checked 10 Nov 2026)
- Adobe: Deprecated and removed features (checked 10 Nov 2026)
Rule key, type, severity and version are as listed on Adobe's page, checked 10 Nov 2026. Explanations and examples are ours unless marked as Adobe's.