Play Framework and Pekko Upgrade - #113
Conversation
Co-authored-by: sntiwari1 <54884367+sntiwari1@users.noreply.github.com>
Co-authored-by: sntiwari1 <54884367+sntiwari1@users.noreply.github.com>
- Upgraded Play Framework from 2.7.2 to 3.0.5 - Migrated from Akka 2.5.22 to Apache Pekko 1.0.2 - Updated Scala from 2.11.12 to 2.13.12 - Updated Java compiler target from 8 to 11 - Updated dependencies: Jackson 2.14.3, Logback 1.4.14, SLF4J 2.0.9, Netty 4.1.93 - Replaced all Akka imports with Pekko (24 imports across 14 Java files) - Updated application.conf: akka namespace to pekko - Fixed Play 3.0 API changes: FutureConverters, Http.Context removal - Updated ActorStartModule to use PekkoGuiceSupport - Added Scala library exclusions to prevent version conflicts - Build successful with all modules compiling Co-authored-by: sntiwari1 <54884367+sntiwari1@users.noreply.github.com>
Co-authored-by: sntiwari1 <54884367+sntiwari1@users.noreply.github.com>
…ME.md - Removed 6 detailed documentation files (MIGRATION_INDEX, PLAY_PEKKO_MIGRATION_REPORT, QUICK_REFERENCE, START_HERE, TECHNICAL_ANALYSIS, UPGRADE_SUMMARY) - Created single UPGRADE_README.md with essential upgrade information - No icons or symbols used, clean and concise format - Contains version changes, build instructions, and key migration details Co-authored-by: sntiwari1 <54884367+sntiwari1@users.noreply.github.com>
Upgrade to Play Framework 3.0.5 and Apache Pekko 1.0.2
|
Based on your review schedule, I'll hold off on reviewing this PR until it's marked as ready for review. If you'd like me to take a look now, comment
|
Removed detailed changes section regarding dependencies, source code, and configuration updates.
…JSON data and related objects
…mprove validation checks for JSON data and related objects
…and JSON data objects, ensuring compatibility with both Scala and Java Map types.
…t serialization, enhancing compatibility and ensuring proper handling of request data.
SBCOSS-719: Updated the code references in api's for pekko upgradation
There was a problem hiding this comment.
Pull Request Overview
This PR upgrades the codebase from Play Framework 2.7.2 with Akka 2.5.22 to Play Framework 3.0.5 with Apache Pekko 1.0.3, addressing license compliance issues (Akka's license change to BSL 1.1) and security concerns with outdated dependencies.
- Migrated all Akka imports to Apache Pekko across the codebase
- Upgraded Play Framework from 2.7.2 to 3.0.5, Scala from 2.11.12 to 2.13.12, and Java from 8 to 11
- Added Scala collection conversion handling for compatibility with Scala 2.13's immutable collections
Reviewed Changes
Copilot reviewed 22 out of 23 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| pom.xml | Updated root POM with new version properties for Pekko, Play, Scala, and Java 11 target |
| service/pom.xml | Migrated dependencies from Akka to Pekko, updated Play groupId and artifact names, added Scala dependency exclusions |
| all-actors/pom.xml | Replaced Akka dependencies with Pekko equivalents, added explicit Scala 2.13 dependency and exclusions |
| sb-es-utils/pom.xml | Updated Akka actor dependency to Pekko actor |
| service/conf/application.conf | Updated configuration from Akka to Pekko namespaces, strengthened secret key |
| service/app/utils/module/ActorStartModule.java | Changed from AkkaGuiceSupport to PekkoGuiceSupport |
| service/app/utils/module/OnRequestHandler.java | Removed deprecated Http.Context usage, updated to use Http.Request directly |
| service/app/controllers/RequestHandler.java | Updated FutureConverters import for Scala 2.13 compatibility |
| service/app/validators/CertAddRequestValidator.java | Added Scala collection to Java Map conversion handling |
| all-actors/src/main/java/org/sunbird/serviceimpl/CertsServiceImpl.java | Added Scala collection conversion for request data processing |
| Multiple actor and controller files | Updated imports from akka.actor to org.apache.pekko.actor |
| UPGRADE_README.md | Added comprehensive upgrade documentation |
| .gitignore | Updated to include *.tar.gz pattern |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Review by Korbit AI
Korbit automatically attempts to detect when you fix issues in new commits.
| Category | Issue | Status |
|---|---|---|
| Hardcoded CORS Header Value ▹ view | ||
| Actor system migration compatibility risk ▹ view | ||
| Potential API incompatibility between Akka and Pekko ActorRef ▹ view | ||
| Overly permissive CORS policy ▹ view | ||
| Potential ActorRef type mismatch between Akka and Pekko ▹ view | ||
| Method Has Multiple Responsibilities ▹ view | ||
| Incomplete Akka to Pekko migration risk ▹ view | ||
| Potential API incompatibility after Akka to Pekko migration ▹ view | ||
| Mixed Akka/Pekko framework usage ▹ view | ||
| Potential runtime compatibility issue with Pekko/Akka migration ▹ view |
Files scanned
| File Path | Reviewed |
|---|---|
| service/app/utils/module/ActorStartModule.java | ✅ |
| all-actors/src/main/java/org/sunbird/service/ICertService.java | ✅ |
| service/app/utils/module/SignalHandler.java | ✅ |
| service/app/utils/module/OnRequestHandler.java | ✅ |
| all-actors/src/main/java/org/sunbird/actor/CertificationActor.java | ✅ |
| all-actors/src/main/java/org/sunbird/BaseActor.java | ✅ |
| service/app/controllers/BaseController.java | ✅ |
| service/app/controllers/CertificateController.java | ✅ |
| service/app/controllers/RequestHandler.java | ✅ |
| all-actors/src/main/java/org/sunbird/utilities/CertificateUtil.java | ✅ |
| service/app/validators/CertAddRequestValidator.java | ✅ |
| sb-es-utils/src/main/java/org/sunbird/common/ElasticSearchRestHighImpl.java | ✅ |
| sb-es-utils/src/main/java/org/sunbird/common/ElasticSearchHelper.java | ✅ |
| all-actors/src/main/java/org/sunbird/serviceimpl/CertsServiceImpl.java | ✅ |
Explore our documentation to understand the languages and file types we support and the files we ignore.
Check out our docs on how you can make Korbit work best for you and your team.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Added null check
This PR upgrades the repository from Play Framework 2.7.2 + Akka 2.5.22 + Scala 2.11.12 to Play Framework 3.0.5 + Apache Pekko 1.0.3 + Scala 2.13.12.
The upgrade ensures license compliance, security, and modernization, while maintaining API compatibility and project functionality.
Context:
Dependencies:
Type of change
How Has This Been Tested?
mvn clean install -DskipTestsmvn play2:distTest Configuration:
Checklist:
Key Changes / Files Modified
Maven POMs
Source Code (15 Java files)
akka.*→org.apache.pekko.*)Configuration
application.conf: Updated namespace fromakka→pekkoPlay 3.0 API Updates
ActorStartModule: AkkaGuiceSupport → PekkoGuiceSupportRequestHandler: Updated FutureConverters for Scala 2.13OnRequestHandler: Removed deprecatedHttp.Context, usingHttp.RequestMigration Impact
akka→pekko)Description by Korbit AI
What change is being made?
Upgrade the project from Play Framework 2.7/Akka to Play Framework 3.0 with Apache Pekko, replacing Akka dependencies and package namespaces with Pekko equivalents across code, configuration, and build files.
Why are these changes being made?
To align with Apache-2.0 licensed Pekko (Akka-compatible) and avoid Akka's licensing constraints, while improving security and adopting a modern stack with updated dependencies and runtime (Java 11, Scala 2.13, newer Pekko/Play versions). This upgrade also centralizes Pekko migration in code, config, and build so the system remains API compatible.