Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

akka-cluster-typed 2.6 with jackson serialization; server docker deployment; and more #524

Open
wants to merge 42 commits into
base: main
Choose a base branch
from

Commits on Aug 18, 2021

  1. Configuration menu
    Copy the full SHA
    017a716 View commit details
    Browse the repository at this point in the history
  2. update scala-js 1.7.0

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    5994003 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    ecbf6fc View commit details
    Browse the repository at this point in the history
  4. update sbt-assembly 1.0.0

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    29cd0b5 View commit details
    Browse the repository at this point in the history
  5. update sbt-docker 1.8.2

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    7f83141 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    91cc388 View commit details
    Browse the repository at this point in the history
  7. update sbt-revolver 0.9.1

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    eeeb955 View commit details
    Browse the repository at this point in the history
  8. update sbt-buildinfo 0.10.0

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    8196b8b View commit details
    Browse the repository at this point in the history
  9. update scalatest 3.2.9

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    c2d5d35 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    00ea7f0 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    d1a4b4e View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    6ca8f79 View commit details
    Browse the repository at this point in the history
  13. update play-json 2.6.14 and 2.10.0-RC5

    + 2.6.9 -> 2.6.14 for scala 2.10
    + 2.9.0 -> 2.10.0-RC5 for scala 2.12, 2.13
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    44a06fc View commit details
    Browse the repository at this point in the history
  14. clean code: Fix a scalas 2.13 deprecated warnings

    warnings about missing `()` when calling/ overriding some methods
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    52f4f0e View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    044fa6f View commit details
    Browse the repository at this point in the history
  16. clean code: DispatchActor.remoteSbtSelections

    Don't create class fields just for initializing other field
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    d66bbb5 View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    8068c72 View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    950de9e View commit details
    Browse the repository at this point in the history
  19. Fix storate/ listSnippets test case

    When testing in local machine (not in CI), the order of actual result list is not always [3,2,1]
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    df1f9b4 View commit details
    Browse the repository at this point in the history
  20. Rename sbtRunner's application.conf to reference.conf

    + server use reference.conf instead of application.conf
    so sbtRunner should use the same naming.
    + This also permit use config in this file in balancer/test
      which has sbtRunner as a Test dependency.
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    72182aa View commit details
    Browse the repository at this point in the history
  21. Migrate to akka-typed and use cluster instead of remote only

    # Changes
    + Also use jackson for serialization instead of java-serializer.
      - Implement in utils/ PlayJackson.scala
      - Config in utils/ reference.conf
      - Config removed: warn-about-java-serializer-usage = false
    
    + Use Actor discovery [1], so:
      - Remove ActorReconnecting, SbtPing, SbtPong, SbtRunnerConnect, ActorConnected
      - server/ balancer don't need to know sbtRunner's host/port.
        So, we remove some configs such as:
        balancer.remote-hostname, remote-sbt-ports-start,..
    
    + Type safe configuration:
      - Use ConfigLoader & EnrichedConfig from playframework.
      - Add some case classes:
        BalancerConf (in DispatchActor.scala), SbtConf (in SbtActor.scala)
    
    # Configs change:
    + Add `com.olegych.scastie.data-dir`
    
    # Other notes
    + There is no sender() and parent in akka typed [2]
    So, we need explicitly add `replyTo` ActorRef to several messages.
    
    + Supervision:
      When an exception is thrown and no supervision strategy is defined,
      then actor will stop in akka typed instead of restart as in classic [3]
      So, some actors, such as SbtActor need be explicitly supervising.
    
    + SbtProcess: Migrated from classic FSM to typed [4]
    
    # Refs
    [1] https://doc.akka.io/docs/akka/current/typed/actor-discovery.html
    [2] https://doc.akka.io/docs/akka/current/typed/from-classic.html#sender
    [3] https://doc.akka.io/docs/akka/current/typed/from-classic.html#supervision
    [4] https://doc.akka.io/docs/akka/current/typed/fsm.html
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    3f9caa2 View commit details
    Browse the repository at this point in the history
  22. Configuration menu
    Copy the full SHA
    2062051 View commit details
    Browse the repository at this point in the history
  23. Configuration menu
    Copy the full SHA
    acc5cff View commit details
    Browse the repository at this point in the history
  24. Use play-json's JsValueDeserializer

    The previous JsValueDeserializer implementation is working
    but it's a bit hacking :D
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    8c204aa View commit details
    Browse the repository at this point in the history
  25. Configuration menu
    Copy the full SHA
    5e3dacf View commit details
    Browse the repository at this point in the history
  26. PlayJsonDeserializer: Don't consume all input source

    Don't consume input source beyond the ending '}' location of the parsing JsObject
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    ca0ac20 View commit details
    Browse the repository at this point in the history
  27. Configuration menu
    Copy the full SHA
    7bc8df6 View commit details
    Browse the repository at this point in the history
  28. Add ShowConfigTest

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    741aedc View commit details
    Browse the repository at this point in the history
  29. Configuration menu
    Copy the full SHA
    6fef919 View commit details
    Browse the repository at this point in the history
  30. sbt: Reimplement sbt Deployment code

    + deploy, deployServer, deployQuick, deployLocal is now commandAliases instead of TaskKeys.
    + Add dockerCompose task
    + Run `server` by `docker run --network=host ...` instead of `java ...`
    + Fix: deployLocal fail if you don't have access to scastie-secrets github repo.
    + Also remove the unused RUNNER_PRODUCTION env variable
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    e3b1329 View commit details
    Browse the repository at this point in the history
  31. Configuration menu
    Copy the full SHA
    6f9d1a3 View commit details
    Browse the repository at this point in the history
  32. Configuration menu
    Copy the full SHA
    00e3f13 View commit details
    Browse the repository at this point in the history
  33. Configuration menu
    Copy the full SHA
    f40e70a View commit details
    Browse the repository at this point in the history
  34. Remove writing RUNNING_PID

    Don't need this logic as we are now running scastie in docker
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    54d448d View commit details
    Browse the repository at this point in the history
  35. Simplify SbtProcess's params

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    cf4b0c3 View commit details
    Browse the repository at this point in the history
  36. Configuration menu
    Copy the full SHA
    f93d7db View commit details
    Browse the repository at this point in the history
  37. sbt: dockerCompose task

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    cff758b View commit details
    Browse the repository at this point in the history
  38. .gitignore

    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    e4f4266 View commit details
    Browse the repository at this point in the history
  39. Configuration menu
    Copy the full SHA
    6435fb6 View commit details
    Browse the repository at this point in the history
  40. Configuration menu
    Copy the full SHA
    4cf0d9e View commit details
    Browse the repository at this point in the history
  41. Do not flood the console log when asking SnippetProgress

    + Exception `e` always be `AskTimeoutException`
    + The `scalaJsContent` and `scalaJsSourceMapContent` may be very long Strings!
    giabao committed Aug 18, 2021
    Configuration menu
    Copy the full SHA
    0e2caf7 View commit details
    Browse the repository at this point in the history
  42. Configuration menu
    Copy the full SHA
    459088c View commit details
    Browse the repository at this point in the history