Skip to content

refactor: Pekko migration#1266

Open
warcholjakub wants to merge 6 commits intoscalacenter:mainfrom
warcholjakub:refactor/pekko-migration
Open

refactor: Pekko migration#1266
warcholjakub wants to merge 6 commits intoscalacenter:mainfrom
warcholjakub:refactor/pekko-migration

Conversation

@warcholjakub
Copy link
Copy Markdown
Collaborator

No description provided.

@warcholjakub warcholjakub marked this pull request as draft February 24, 2026 15:53
@warcholjakub warcholjakub changed the title refactor: rename config variables refactor: Pekko migration Feb 24, 2026
@warcholjakub warcholjakub marked this pull request as ready for review February 25, 2026 11:52
@warcholjakub warcholjakub requested a review from Copilot February 25, 2026 11:53
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request migrates the Scastie codebase from Akka to Apache Pekko, a significant refactoring that updates all actor-based components, HTTP server infrastructure, and remote communication protocols. The migration is comprehensive and touches all major modules including server, balancer, runners (sbt and scala-cli), and utilities.

Changes:

  • Replaced all Akka imports with Apache Pekko equivalents across the entire codebase
  • Updated configuration keys from "akka-port" to "remote-port" and "akka." to "pekko."
  • Migrated third-party library dependencies (akka-http-circe → pekko-http-circe, akka-http-session → pekko-http-session, akka-http-cors → pekko-http-cors)
  • Changed actor protocol URLs from "akka://" to "pekko://"
  • Moved BlockingProcess from akka.contrib.process package to org.scastie.util
  • Updated all logback configuration to use org.apache.pekko logger names
  • Updated environment variables and deployment configuration

Reviewed changes

Copilot reviewed 62 out of 63 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
utils/src/test/scala/org/scastie/util/ProcessActorTest.scala Updated test imports to Pekko actor and testkit
utils/src/main/scala/org/scastie/util/ScalaCliTask.scala Updated ActorRef import to Pekko
utils/src/main/scala/org/scastie/util/SbtTask.scala Updated ActorRef import to Pekko
utils/src/main/scala/org/scastie/util/ReconnectingActor.scala Updated actor imports and renamed port fields to serverRemotePort/actorRemotePort
utils/src/main/scala/org/scastie/util/ProcessActor.scala Updated all Pekko actor and stream imports, removed akka.contrib.process
utils/src/main/scala/org/scastie/util/GraphStageLogicForwarder.scala Updated stream stage imports to Pekko
utils/src/main/scala/org/scastie/util/GraphStageForwarder.scala Updated stream stage imports to Pekko
utils/src/main/scala/org/scastie/util/BlockingProcess.scala Moved from akka.contrib.process to org.scastie.util, updated all imports and config references
utils/src/main/resources/reference.conf Updated configuration keys from akka to pekko, renamed akka-port to remote-port
storage/src/test/resources/logback.xml Updated logger name to org.apache.pekko
server/src/test/scala/org/scastie/web/SnippetIdMatcherTests.scala Updated HTTP test imports and circe support library
server/src/test/resources/application.conf Updated actor provider to fully qualified Pekko class name
server/src/main/scala/org/scastie/server/routes/*.scala Updated all HTTP and actor imports across all route files
server/src/main/scala/org/scastie/server/oauth2/*.scala Updated session library imports to pekko-http-session
server/src/main/scala/org/scastie/server/ServerMain.scala Updated actor system, HTTP, and CORS imports; updated config key references
server/src/main/scala/org/scastie/server/RestApiServer.scala Updated pattern matching and actor imports
server/src/main/resources/reference.conf Updated all configuration from akka to pekko namespace
server/src/main/resources/logback.xml Updated logger name to org.apache.pekko
scala-cli-runner/src/test/scala/org/scastie/scalacli/ScalaCliRunnerTest.scala Updated test actor imports
scala-cli-runner/src/test/resources/.xml,.conf Updated test configuration for Pekko
scala-cli-runner/src/main/scala/org/scastie/scalacli/*.scala Updated all actor and pattern imports, renamed port references
scala-cli-runner/src/main/resources/.xml,.conf Updated runtime configuration for Pekko
sbt-runner/src/test/scala/org/scastie/sbt/SbtActorTest.scala Updated test actor imports
sbt-runner/src/test/resources/application.conf Updated test configuration for Pekko
sbt-runner/src/main/scala/org/scastie/sbt/*.scala Updated all actor imports, renamed port references, updated actor URLs
sbt-runner/src/main/resources/.xml,.conf Updated runtime configuration for Pekko
run.sh Updated environment variable from SERVER_AKKA_PORT to SERVER_REMOTE_PORT
project/Deployment.scala Updated config key from akka-port to remote-port
deployment/*.conf Updated deployment configurations for staging, production, and local environments
deployment/logback.xml Updated logger name in production logback config
build.sbt Updated all dependencies from Akka to Pekko, including versions
balancer/src/test/scala/org/scastie/balancer/DispatchActorIntegrationTest.scala Updated integration test imports and renamed port variables
balancer/src/test/resources/application.conf Updated actor provider configuration
balancer/src/main/scala/org/scastie/balancer/*.scala Updated all actor, stream, and event imports across balancer actors
balancer/src/main/resources/reference.conf Updated actor configuration warning setting
CONTRIBUTING.md Updated architecture documentation to reference pekko-remote instead of akka-remote

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread balancer/src/main/scala/org/scastie/balancer/SbtDispatcher.scala
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants