Commit graph

195 commits

Author SHA1 Message Date
kerr
0e4d41ad33
+build Add sort imports support. (#28780)
* Add scalafix plugin for jdk 9.
* Add command alias sortImports.
* Excludes some sources from SortImports.
* Update SortImports to 0.4.0
* Sort imports with `sortImports` command.
2020-04-27 14:32:18 +02:00
ohze.net
ea7205eaf7
dotty phase 2: scalafix ExplicitNonNullaryApply (#28949)
* scalafix ExplicitNonNullaryApply prepare

+ Temporarily use com.sandinh:sbt-scalafix because scalacenter/scalafix#1098
+ Add ExplicitNonNullaryApply rule to .scalafix.conf
+ Manually fix a NonNullaryApply case in DeathWatchSpec that cause
  `fixall` fail because ExplicitNonNullaryApply rule incorrectly rewrite
  `context unbecome` to `context unbecome()` instead of `context.unbecome()`

* scalafix ExplicitNonNullaryApply

fix by enabling only ExplicitNonNullaryApply rule in .scalafix.conf then:
```
% sbt -Dakka.build.scalaVersion=2.13.1
> fixall
```

* scalafmtAll

* Revert to ch.epfl.scala:sbt-scalafix

Co-authored-by: Bùi Việt Thành <thanhbv@sandinh.net>
2020-04-27 12:31:16 +02:00
Bùi Việt Thành
02b9b30354 scalafix ExplicitResultTypes - for implicit members 2020-04-20 17:59:50 +07:00
Bùi Việt Thành
2c6e349c7e scalafix FinalObject - for scalafix ignored files 2020-04-20 17:59:50 +07:00
Patrik Nordwall
abbef000ab
Notify Receptionist subscribers when node added and removed, #28792 (#28795)
* notify subscribers when node added and removed
* If the change from ddata arrives before the join information
* One difficulty is that that the removal tick may trigger removal
  for entries that are in the ddata state but not in the membership yet.
* it's possible that the Entry arrives before MemberJoined, but
  such entries should not be removed by the RemoveTick
* by adding a timestamp of when the entry is created we can
  avoid removing such early entries and the MemberJoined should be
  visible before that duration has elapsed
2020-04-02 15:19:05 +02:00
Renato Cavalcanti
59cec8b44a
Merge pull request #28843 from akka/wip-28842-parent-dispatcher-patriknw
fix DispatcherSameAsParent when using ClusterActorRefProvider, #28842
2020-04-01 12:16:12 +02:00
Patrik Nordwall
5ffa4b077d fix DispatcherSameAsParent when using ClusterActorRefProvider, #28842
* add test
* the check for valid config is not needed in RemoteActorRefProvider,
  since it is delegating to LocalActorRefProvider for all cases but the
  remote deployment case
2020-03-30 08:04:52 +02:00
Patrik Nordwall
d9f1416252 change %mdc examples, and tests
* if MDC is empty it's confusing with {} because it can be misunderstood
  to be a missing log template parameter
2020-03-27 17:59:58 +01:00
Patrik Nordwall
1d16e847b5 Reliable delivery in Typed, #20984
Different approach than in classic AtLeastOnceDelivery because I would like:
* support flow control, with a work pulling approach
* be possible to use with or without persistence (without it may loose
  messages if producer node crashes)
* detect lost messages on the consumer side and let that drive resends,
  instead of aggressively resending from producer side
* deliver messages in order and deduplicate resent messages
* have an efficient protocol for acknowledgments over the network (not ack each message),
  but still have a simple one-by-one protocol for the end user

* support 3 use cases (building blocks)
  * point-to-point
  * work pulling
  * sharding
* optional durable queue, with one event sourced implementation
* protobuf serialization
* ApiMayChange
* reference docs and examples
* api docs
* doc example code missing so far
2020-03-12 15:37:16 +01:00
Renato Cavalcanti
6e171815b6
Adds ActorRef.ignore (#28630) 2020-03-12 12:40:56 +01:00
Johan Andrén
59ce257209
Distributed pubsub for typed (#28625)
* First stab at distributed pubsub for typed

* Also allow sending to a single subscriber across the topic

* Revert "Also allow sending to a single subscriber across the topic"

This reverts commit 4fd4f0b75c0dda01706dcde70645dcfa09da889b.

* Serializer and basic multi-jvm test

* docs

* Review feedback

* This reads better

* One brace too many

* sample formatting/headers/yadi

* Hide actual messages to ease bincomp evolution

* More tesssssts

* And even moar tessssssssts

* Review feedback addressed

* Same serialization as typed sharding
Mention turnaround in docs
2020-03-10 14:01:19 +00:00
Mikhail Limansky
3fccda9f4c Update multi-jmv tests for ScalaTest 3.1.0 2020-01-15 12:31:07 +03:00
Mikhail Limansky
6723c6cc59 Fix test compilation issue in akka-cluster-typed 2020-01-13 12:40:06 +03:00
Mike Limansky
d9ed927df0 Update to ScalaTest 3.1.0, fix #28289. 2020-01-11 15:15:10 +03:00
Johan Andrén
4749b11be8 Typed receptionist deregistration (#28406)
* Co-authored-by: tipame <33191778+tipame@users.noreply.github.com>
2020-01-10 09:34:04 -08:00
Arnout Engelen
fb7c695d15 Link to replicator case object (#28439)
* Link to replicator case object (#28427)

Unfortunately apidoc cannot detect when you link to a class but only the
corresponding object exists in the scaladoc, not the class itself.

* Further clarifications
2020-01-08 13:47:43 +01:00
Helena Edelson
6bf20f4117 Update all copyright headers to 2020 after new year's #27881 (#28434) 2020-01-02 13:24:59 +01:00
Brian Wignall
fd41299943 Fix typos, via a Levenshtein-style corrector 2019-12-19 01:57:55 -05:00
Brian Wignall
10e61e816f Fix typos (#28326) 2019-12-09 08:41:55 +01:00
Patrik Nordwall
619a4494d5
Merge pull request #28308 from akka/wip-mdc-logback-config-patriknw
use %mdc logback config to output all MDC entries
2019-12-05 16:26:30 +01:00
Johannes Rudolph
702b6a7f41 actor: allow seamless access to untyped extensions given typed ActorSystem (#28294)
* actor: allow seamless access to untyped extensions given typed ActorSystem

* add overrides with concrete type for Java API everywhere
2019-12-05 16:01:22 +01:00
Patrik Nordwall
c84e4d82fb use %mdc logback config to output all MDC entries
* change logback doc example configurations
* change logback test configurations
* change docs around MDC
* change Slf4jLoggerSpec to use this instead
2019-12-05 11:47:37 +01:00
Xusheng Peng
7b943873fc add local affinity support for group router #28174 2019-12-03 16:34:27 +01:00
sullis
dbc97fb6f3 Scala 2.13.0 -> Scala 2.13.1 (#28140)
* Scala 2.13.0 -> Scala 2.13.1

* Update to genjavadoc 0.15

* Allow 'higherKinds' without explicit import

To follow the 2.13.1 convention

* Remaining higherKinds imports

* Mima excludes for missing value classes in generics
2019-11-29 13:38:19 +01:00
Johan Andrén
4588a3904f
Include host and port in mdc if clustered or remote #28073 2019-11-28 11:35:11 +01:00
Arnout Engelen
4b632c4537 Add convenience method to start timer without key (#27875)
* Add convenience method to start timer without key

It is probably common that there is no need to allow different timers
that send the same message, and this makes that more convenient to write.

Updated one method to gather feedback, if we like the change I can apply
it to the others as well.

* Add alternative to all typed timer API's

Update java/scaladoc, update tests

Not updated classic actors and FSM API's
2019-11-26 13:26:49 +00:00
Patrik Nordwall
36aa8fd48a Handle Replicator.Unsubscribe in Typed scaladsl, #28061
* scaladsl.Unsubscribe was missing in ReplicatorBehavior
* also noticed a Changed vs SubscribeResponse leftover from
  previous api change
2019-10-26 10:51:46 +02:00
Helena Edelson
bec1a882c2 Add a page for Typed Distributed PubSub (#28012) 2019-10-19 20:26:27 +02:00
Patrik Nordwall
46fcca5f39
Add API for multi-dc Sharding/Singleton in Typed, #27705 (#27974)
* add withDataCenter in Entity, following same patterna as the role
* update cluster-dc.md, split in classic and new pages
* fix bug in ClusterSharding shouldHostShard
  * contains on String
* update multi-dc singleton sample
2019-10-15 12:20:41 +02:00
Patrik Nordwall
c83d04c1f8
Merge pull request #27978 from akka/wip-scala-2.12-simplifications-patriknw
small simplification since Scala 2.11 isn't supported
2019-10-15 11:17:54 +02:00
Patrik Nordwall
5de5dec6ee
Merge pull request #27988 from akka/wip-protobuf-3.10.0-patriknw
Update protobuf-java and protoc to 3.10.0
2019-10-15 11:09:30 +02:00
Patrik Nordwall
4bd3edaa32 add missing apply for consistency types, #27997 (#27998) 2019-10-15 10:36:13 +02:00
Johan Andrén
6190f0bc58 Provide Scheduler implicitly from implicit typed actorsystem (#27986) 2019-10-14 16:33:06 +02:00
Patrik Nordwall
78281ba92f
doc: improvements to Distributed Data docs (#27971)
* doc: improvements to Distributed Data docs

* leftover

* java formatting
2019-10-14 14:03:04 +02:00
Scala Steward
63df007685 protoc version 3.10.0 2019-10-14 11:11:21 +02:00
Patrik Nordwall
ac08ca8729 small simplification since Scala 2.11 isn't supported 2019-10-11 16:55:30 +02:00
Patrik Nordwall
bb6d6365b1
Scaladoc improvements (#27929)
* private[akka] visibility on some internal classes
  * found via unidoc
* fix Scaladoc links
2019-10-10 14:17:01 +02:00
Patrik Nordwall
ddaceae80d
rename PersistenceId.apply to PersistenceId.ofUniqueId, #27924 (#27953)
* to make the entityTypeHint, entityId the more prominent choice, and
  avoid that only the entityId is used as the uniqueId
2019-10-10 14:05:46 +02:00
Patrik Nordwall
0236afc039 use CBOR in some tests instead of custom serializers (#27882) 2019-10-09 13:56:18 +02:00
Patrik Nordwall
40ce73ad4e doc: small improvements of core cluster pages (#27939)
* proofreading of core cluster pages
* some more info in failure detector
2019-10-09 10:17:22 +01:00
Patrik Nordwall
62a98317cb
doc: improve receptionist docs, #25895 (#27870)
* change intro text, not comparing with Classic
* exampel of Receptionist.Find
* link from spawn protocol section as requested in issue
2019-10-03 17:56:37 +02:00
Patrik Nordwall
a217d5566e
Remove auto-downing, #27788 (#27855)
* moved to cluster tests, in new package akka.cluster.testkit
* changed config in tests
* migration guide
* documentation clarificiations for Downing and Leaving
* update warnings in Singleton and Sharding
2019-10-03 14:08:43 +02:00
Patrik Nordwall
064f06f5a6 supervision in AdapterClusterImpl (#27862)
* methods like cluster.join and cluster.subscribe may throw exception if called
  with invalid parameters
* the manager and subscriptions actors should survive such exceptions
2019-10-03 08:02:29 +01:00
Patrik Nordwall
51a3aa98c9
doc: improve docs of Cluster joining (#27821)
* some were lost or became confusing in previous refactoring
* ref links
2019-10-01 19:10:36 +02:00
Patrik Nordwall
91db18b564 ActorContext as constructor parameter in AbstractBehavior, #27689 (#27806)
* ActorContext as constructor parameter in AbstractBehavior, #27689

* additional test

* additional doc clarification

* another rebase
2019-09-27 11:17:37 +02:00
Patrik Nordwall
a7c43cf573
Config to exclude class prefix from serialize-messages, #24273 (#27517)
* Config to exclude class prefix from serialize-messages, #24273

* Adding no-serialization-verification-needed-class-prefix, with "akka." included
  by default
* This is important now when we disable Java serialization by default.
  There will be many complaints about Akka internal classes that are not marked with
  NoSerializationVerificationNeeded, and we can't really sprinkle that everywhere.
* Not removing NoSerializationVerificationNeeded usage in Akka classes because that
  may break bin compat, even though it's needed any more.

* fix DisabledJavaSerializerWarningSpec
2019-09-26 22:51:12 +02:00
Helena Edelson
94cc028986 Distributed Data: General Typed docs cleanup after all API changes (#27783) 2019-09-26 17:14:08 +02:00
Johan Andrén
e74831d78b Use japi lambdas where it makes sense (#27790)
* Use akka.japi.function types for adapter lambdas

The Java lambda types does not allow for throwing exceptions but
because of how we run the adapter lambdas in-actor that is fine, so
use our own akka.japi.function types to allow for that.

* Use akka.japi.function types for lambdas where it makes sense
2019-09-26 11:07:56 +02:00
Patrik Nordwall
39d2db9abb
Merge pull request #27659 from akka/wip-24717-doc-apply-style13-patriknw
doc: stylish distributed-data.md, #24717
2019-09-19 16:44:07 +02:00
Patrik Nordwall
8cb2721c33
Reference docs for SL4J logging in Typed, #27648 (#27696)
* Reference docs for SL4J logging in Typed, #27648
* mention package implicit for LoggerOps
* reference docs of log testing utilities
* cleanup classic logging.md
  * most of it is still relevant, and different enough from
    typed/logging.md to keep it separate
* use ThresholdFilter instead of LevelFilter

Co-Authored-By: Will Sargent <will.sargent@gmail.com>
2019-09-17 17:26:13 +02:00