Commit graph

77 commits

Author SHA1 Message Date
Patrik Nordwall
a7eed00948 Merge pull request #21813 from akka/wip-21518-patriknw
minor cleanup of cluster.subscribe usage
2016-11-16 21:33:02 +01:00
Patrik Nordwall
88a6bdb059 Cluster singleton testing (#21803)
* add another singleton restart test

* remove from singleton sorted set with unique address

* because the upNumber used by the Ordering can change
2016-11-11 15:10:30 -08:00
Patrik Nordwall
d9e873644e minor cleanup of cluster.subscribe usage 2016-11-08 15:14:52 +01:00
Patrik Nordwall
9be7df1527 send terminationMessage to singleton when leaving last, #21592 (#21654)
* send terminationMessage to singleton when leaving last, #21592

* When leaving last node, i.e. no newOldestOption, the manager was
  just stopped. The change is to send the terminationMessage also
  in this case and wait until the singleton actor is terminated
  before stopping the manager.
* Also changed so that the singleton is stopped immediately when
  cluster has been terminated when last node is leaving, i.e.
  no newOldestOption. Previously it retried until maxTakeOverRetries
  before stopping.
* More comprehensive test of this scenario in ClusterSingletonManagerLeaveSpec

* increase test timeout
2016-10-28 14:23:18 +02:00
Niko Will
5fe950e694 Adding protobuf serialization for SendToOneSubscriber (cluster pubsub) #21629 2016-10-08 16:09:29 -05:00
Patrik Nordwall
8d36499cd4 shortname for provider config 2016-09-29 15:01:05 +02:00
Johan Andrén
9acb1feba3 ClusterClientSpec workin with artery #21477 2016-09-16 12:29:49 +02:00
Johan Andrén
848d56cc2f More tests working on artery
* non-multi-jvm tests from akka-cluster
* akka-cluster-metrics
* akka-cluster-tools
* akka-cluster-sharding
2016-09-14 11:40:42 +02:00
Patrik Nordwall
8ab02738b7 Merge branch 'master' into wip-sync-artery-dev-2.4.9-patriknw 2016-08-23 20:14:15 +02:00
Patrik Nordwall
e6068a0f5a Fix regression in Cluster Singleton, #21236
* When the test fails the node is removed from the membership
  twice, which triggers two OldestChanged cycles, but in
  the 2.4.9 change https://github.com/akka/akka/pull/21152/files#diff-f0ae95c926a050aecf45dba3e08d1c77L669
  the singleton manager always goes to End (stop) when it has been Oldest
* This fix restores the previous behavior for this scenario
2016-08-23 19:08:49 +02:00
Patrik Nordwall
0c4d4c37ba cluster singleton improvements, #20942
* track nodes by UniqueAddress in Cluster Singleton, #20942
* reply with HandOverDone from new incarnation, #20942
* confirm as terminated immediately when new incarnation joins, #20942 instead of waiting for failure detector to mark it as unreachable this will speed-up removal when restarting cluster node with same hostname:port
2016-08-19 11:56:55 +02:00
Patrik Nordwall
ccb5d1ba04 Merge branch 'master' into wip-sync-2.4.8-artery-patriknw 2016-07-08 15:38:33 +02:00
Patrik Nordwall
f0f755bf08 Merge pull request #20828 from choffmeister/choffmeister-20826-unregister-leaving-distributed-pubsub-nodes
Remove distributed pubsub nodes on leave
2016-07-05 15:48:07 +02:00
Patrik Nordwall
8b274ebc62 ignore PubSub Status message from unknown node, #20846 (#20847)
* ignore PubSub Status message from unknown node, #20846

Reproducer:
1. old cluster of node1, node2 and node3
2. shutdown node3 and start it again with same host:port, let it
   join itself and not the old cluster
3. node1 and node2 will continue to gossip to the node3 address and
   Status message is accepted and replied to (Delta is ignored from
   unknown node)

Solution:
* ignore status message from unknown node
* also added a reply flag in the Status message to break the
  back-and-forth replies in case the deltas are not accepted,
  this is not needed for fixing this bug, but it adds an extra
  level of safety
2016-07-01 12:12:23 +02:00
Christian Hoffmeister
fcd290cd9a Remove distributed pubsub nodes on leave #20826
This ensures that gracefully leaving nodes (which would terminate after
their own removed event) are already unregistered on all other pubsub
nodes, before termination.
2016-06-30 09:19:39 +02:00
Johan Andrén
d6c048f59a A simpler ActorRefProvider config #20649 (#20767)
* Provide shorter aliases for the ActorRefProviders #20649
* Use the new actorefprovider aliases throughout code and docs
* Cleaner alias replacement logic
2016-06-10 15:04:13 +02:00
Björn Antonsson
c66ce62d63 Update to a working version of Scalariform 2016-06-02 22:12:36 +02:00
Christopher Hunt
ceb0678de2 Observe the cluster client and its receptionist
Allows the cluster client and its receptionist to be observable in terms of contact points becoming available and client heartbeats. Furthermore a query API for requesting the current state has been provided.
2016-05-12 18:45:56 +10:00
Patrik Nordwall
d5a3b26291 format the code
* just a clean test:compile
* and fixing the tweets Source
2016-05-10 11:52:36 +02:00
Oleksii
5cc1c10a55 DistributedPubSub messages sent to dead letters if no recipients #19009 2016-05-10 08:56:31 +02:00
Johan Andrén
5671927cf1 clu #20309 API for pluggable cluster downing 2016-04-18 15:06:05 +02:00
Konrad Malawski
62d8a69fac all #20090 enable running java tests in actor,camel,cluster,persistence 2016-04-06 01:23:21 +02:00
Patrik Nordwall
9f659cf9b1 remove JUnitRunner annotation, #16112
* it was used for running tests from inside Eclipse,

  but since it caused some trouble we remove it
2016-04-05 17:06:58 +02:00
Patrik Nordwall
137c4c8b3d fix the the typo 2016-03-18 17:06:34 +01:00
Johannes Rudolph
b6cbc7f13a =all remove unused imports 2016-02-23 20:29:22 +01:00
Johan Andrén
62e30b3c08 Update copyrights and links to the new company name #19851 2016-02-23 12:58:39 +01:00
Kirill Plyashkevich
35ffc49226 GZIPInputStream is not closed at all at places, where it's instantiated, which leads to off-heap memory leak with every deserialized message.
GZIPInputStream uses Inflater internally (so also native zlib). Inflater frees up memory only on explicit call to end() or during finalization (finalize() contains only call to end()), so GZIPInputStream should always be explicitly closed.

As native libraries are used a non-scalaish try-finally is used to avoid off-heap memory leak for GZIPInputStream and GZIPOutputStream in case of exceptions.
2016-02-15 16:15:05 +01:00
Patrik Nordwall
aaa8a2bb4c silence deadletter logging of SubscribeAck
* since it is normally (practially always) a local
  messages send that will not be rejected you don't
  care about the ack
2016-02-08 18:20:36 +01:00
Patrik Nordwall
d37a304394 Merge pull request #19154 from Adebski/Adebski-distributed-pub-sub-race-condition-fix
Race-condition problem in distributed-pub-sub fixed by introducing passivate-like protocol for mediator and Topic actors.
2016-01-28 10:55:38 +01:00
Prayag Verma
b7783968a0 =pro #19068 All copyrights ranges and single years updated to a range ending in 2016 2016-01-25 10:20:30 +01:00
adebski
460bad2726 =clu #19017 Race-condition issue when handling Topic/Group actors.
* Added reusable PerGroupingBuffer trait for pubsub implementation
* Moved mkKey methods to the Internal object
* Introduced passivate-like protocol between DistributedPubSubMediator/Topic and Topic/Group actors, contained in ChildActorTerminationProtocol messages.
2016-01-24 14:14:24 +01:00
Roland Kuhn
e5baba2b29 squash some warnings 2016-01-20 11:54:24 +01:00
Johan Andrén
19c7017482 =clu #18577 Option to stop cluster client after no receptionist contact timeout 2016-01-11 14:02:12 +01:00
Konrad Malawski
35108384c9 =clt #19381 silence heartbeat logging in cluster client 2016-01-08 12:11:56 +01:00
Roland Kuhn
f1abaa1c5e Merge pull request #18875 from ktoso/wip-akka.js-cherries-ktoso
Akka.js cherries to master
2015-11-07 18:01:24 +01:00
Patrik Nordwall
c7c187f6b7 =clu replace Set -- with diff and ++ with union
* better performance according to
  https://docs.google.com/presentation/d/1Qjryxoe-fYEM8ZPhM-98LKfbhnRcn5eAEMNlVVnixsA/pub
2015-11-06 14:48:17 +01:00
Andrea
cd3d68a77c =act switch to java std lib ThreadLocalRandom 2015-11-06 14:04:33 +01:00
Patrik Nordwall
9380983d3c =clu #18554 Make oldest assignment deterministic when joining
* the reported issue is fixed by the immediate leaderActions
  (moving to Up)  when joining the first node to itself
* the other changes are precautions just in case
2015-10-21 07:53:14 +02:00
Patrik Nordwall
92e9972d54 =clt #18440 Harden ClusterClientSpec again
The fix in https://github.com/akka/akka/pull/17903 was not using
the correct configuration property. The issue in #17735 was never
fixed by that PR, but now it is.
2015-09-18 09:27:19 +02:00
Patrik Nordwall
a3ced0a38a =clt #18343 Improve structure of DistPubSub docs 2015-09-17 10:50:49 +02:00
Patrik Nordwall
a45f31cecb Merge pull request #18490 from akka/wip-16948-singleton-retries-patriknw
=clt #16948 Use min retries for singleton leaving scenario
2015-09-17 10:39:19 +02:00
Patrik Nordwall
6d036ca00c =clt #16948 Use min retries for singleton leaving scenario"
* In 2.4 we derive the number of hand-over/take-over retries from
  the removal margin, but we decided to set that to 0 by default, since
  it is intended for network partition scenarios. maxTakeOverRetries
  became 1. So there must be also be a  min number of retries property.
* The test failed for the leaving scenario because the singleton
  instance was stopped hard without sending the terminationMessage when
  the maxTakeOverRetries was exceeded.
2015-09-17 10:38:52 +02:00
Patrik Nordwall
15bcd5c41f =clt #18459 Add ClusterClient test for quick restart 2015-09-16 10:47:19 +02:00
Patrik Nordwall
22b8853314 =clu #13584 mark as experimental and some doc clarificiations 2015-09-04 14:09:41 +02:00
Patrik Nordwall
4b6382f780 Merge pull request #18363 from akka/wip-13783-embedded-protobuf-patriknw
=all #13783 replace protobuf dependency by embedded version
2015-09-04 11:30:01 +02:00
Patrik Nordwall
bfde1eff19 =clu #18337 Disable down-removal-margin by default
For manual downing it is not needed. For auto-down it doesn't add any extra safety, since that
is not handling network partitions anyway.

The setting is still useful if you implement downing strategies that handle network partitions,
e.g. by keeping the larger side of the partition and shutting down the smaller side.
2015-09-04 11:28:33 +02:00
Roland Kuhn
c3ecb87a65 =all #13783 replace protobuf dependency by embedded version
- created new subproject akka-protobuf (and added COPYING and LICENSE)
- renamed com.google.protobuf -> akka.protobuf everywhere
- also added such renaming step to the results of protoc compilation in
  project/Protobuf.scala
- had to include transcriptions of Netty’s ProtobufEncoder/Decoder to
  make multi-node-testkit compile again
2015-09-04 09:06:50 +02:00
Patrik Nordwall
6420a37250 Merge pull request #18286 from akka/wip-18258-cluster-client-protobuf-patriknw
=clt #18258 Create protobuf serialization for ClusterClient
2015-08-21 14:38:10 +02:00
Patrik Nordwall
b9fecfd53b Merge pull request #18257 from akka/wip-17699-DeadLetterSuppression-patriknw
=cls #17699 Add some DeadLetterSuppression
2015-08-21 08:46:30 +02:00
Patrik Nordwall
95d6c8a62f =clt #17975 Add debug logging to ClusterClientReceptionist 2015-08-21 08:32:07 +02:00