Refactor dotCMS core analytics code
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 970
- Forks
- 486
- Avg merge
- 3d 33m
- Merged PRs (30d)
- 170
Description
Description
Clean up dotCMS core as part of the migration to the new analytics microservice architecture. dotCMS now only proxies analytics requests to the microservice — the legacy endpoint and token management code are no longer needed.
Changes required:
- Remove old analytics endpoint —
ContentAnalyticsResource.java(line 60 and related methods) - Remove token renewal code —
AccessTokenRenewJob.javaand all related scheduler registrations inDotInitScheduler - Create Postman test — Add Postman collection tests for
EventAnalyticsProxyResourceto verify the proxy endpoint works end-to-end
This cleanup is a prerequisite to the new architecture where dotCMS only proxies requests to the microservice.
Parent epic: #35048
Acceptance Criteria
-
ContentAnalyticsResource.javalegacy endpoint removed (entry point at line 60 and all associated logic) -
AccessTokenRenewJob.javaremoved - All scheduler registrations for token renewal removed from
DotInitScheduler - No compilation errors after removal — no dangling references
- Postman test added for
EventAnalyticsProxyResourcecovering: successful proxy to event manager, auth header forwarding, error passthrough - Code passes build (
./mvnw install -pl :dotcms-core -DskipTests)
Additional Context
- Source task: Task 26 (Core code refactoring) from the improvement plan
- Related branch:
issue-34849-Add-dotCMS-Analytics-Proxy-Endpoint-for-/v1/analytics/-to-dot-ca-event-manager - New proxy entry point:
EventAnalyticsProxyResource.java
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ContentAnalyticsResource.java, AccessTokenRenewJob.java, DotInitScheduler, and EventAnalyticsProxyResource.java to trace the legacy endpoint, token-renewal registrations, and proxy behavior. Run ./mvnw install -pl :dotcms-core -DskipTests, then use the existing Postman setup to cover successful proxying, auth-header forwarding, and error passthrough. Done means the legacy code and dangling references are gone, the proxy tests exist, and the build passes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, postman
- Domain
- api, backend, testing-qa
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100