Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Oct 22 21:12
    Aaronontheweb commented #4001
  • Oct 22 21:11

    Aaronontheweb on dev

    Added missing Persistence Testiā€¦ (compare)

  • Oct 22 21:11
    Aaronontheweb closed #4001
  • Oct 22 20:59
    sean-gilliam commented #3889
  • Oct 22 20:59
    sean-gilliam opened #4001
  • Oct 22 16:07
    spankr commented #3921
  • Oct 22 15:55
    Aaronontheweb labeled #3765
  • Oct 22 15:54
    Aaronontheweb labeled #3765
  • Oct 22 15:54
    Aaronontheweb milestoned #3765
  • Oct 22 15:53
    Aaronontheweb closed #3902
  • Oct 22 15:23
    Aaronontheweb commented #3921
  • Oct 22 15:11
    spankr commented #3921
  • Oct 22 15:05
    Aaronontheweb commented #3973
  • Oct 22 15:05
    Aaronontheweb commented #3973
  • Oct 22 15:02
    Aaronontheweb commented #4000
  • Oct 22 15:02
    Aaronontheweb milestoned #4000
  • Oct 22 15:02
    Aaronontheweb assigned #4000
  • Oct 22 15:01
    Aaronontheweb commented #3889
  • Oct 22 14:55
    sean-gilliam commented #3889
  • Oct 22 14:35
    IgorFedchenko commented #3973
Bart de Boer
@boekabart
It was so much simpler: the Postgres Snapshot class used the generic Journal config as fallback... PR for that is done.
But that doesn't explain why it still worked OK 50% of the time! @Horusiath
Mathias Feitzinger
@feitzi
After some years as an akka.net user, I want to make a more deep dive into the framework.
For this reason, I checked out the actual source code (dev branch) and stared a build and unit testing (like descriped here). But I got in trouble with the existing unit tests. I can't run all tests successful. I have 3 of 4195 unsuccessful tests:
  • Akka.MultiNodeTestRunner.Shared.Tests.ParsingSpec.MessageSink_should_parse_Runner_log_message_correctly
  • Akka.MultiNodeTestRunner.Shared.Tests.ParsingSpec.MessageSink_should_be_able_to_infer_message_type
  • Akka.MultiNodeTestRunner.Shared.Tests.Persistence.JsonPersistentTestRunStoreSpec.Should_load_saved_JSON_TestRunTree
    I have no code changes, its the original dev branch.
    Is this normal, or did I something wrong?
Bartosz Sypytkowski
@Horusiath
@feitzi some of the tests are time sensitive, therefore you may result in hitting into false negatives.
@boekabart I'm afraid I'd need a reproducible use case to understand what's happening
Lutando Ngqakaza
@Lutando
Why do the timestamps (created_at) in my sql journals have values like 637015430987854360 what on earth is that value?
anthonyhawes
@anthonyhawes
@Lutando it's the UTC DateTime converted into ticks
Lutando Ngqakaza
@Lutando
Thank you kind sir
Lutando Ngqakaza
@Lutando
The Offset value that you get when doing EventsByTag persistent query, what do they mean?
 await PersistenceQuery
                .Get(actorSystem)
                .ReadJournalFor<SqlReadJournal>(SqlReadJournal.Identifier)
                .CurrentEventsByTag("MyTag")
                .RunForeach(x =>
                {
                    var a = x.Offset as Sequence;
                    Console.Write($"{a.Value}"); 
                }, materializer);
Prints : 1 1 2 2 3 3 4 4 ... 100 ... 101... 102
Lutando Ngqakaza
@Lutando

another slightly related question what is the best way to get the offset/sequence value

I am doing this (seems quite verbose for getting that sequence value, any shorter hand ways?

var sequence = eventEnvelope.Offset as Sequence
var streamOffset = sequence.Value
Ismael Hamed
@ismaelhamed
@Lutando that's the SequenceNr/Ordering for that event. I typically have a generic OffsetStore to which a pass the offset and internally will do something like:
offset is Sequence seq ? seq.Value : (long?)null;
That Offset is handy for resumable PersistenceQueries
Lutando Ngqakaza
@Lutando
yeah thats what im aiming for but im just wondering why the offset value is "hidden"
Ismael Hamed
@ismaelhamed
It's no that it is "hidden", but an offset can be of different types: currently NoOffset or Sequence, but the JVM also supports TimeBasedUUID
Vladimir Boiarkin
@vladmir-boy
Hi guys. sorry for vague question
I have two actors in my actorSystem communicating on localhost, meaning that they communicate in memory without serialization and transport involved
Can I some how enforce serialization and transport, so I can measure this expenses in the benchmark?
Lutando Ngqakaza
@Lutando

@vladmir-boy absolutely.

 akka.actor.serialize-messages = on
 akka.actor.serialize-creators = on

https://getakka.net/articles/networking/serialization.html#verification

heed the warning in the docs.

as for forcing the transport im not sure how one would do that. I guess if you doing multi node testing, but I dont think its possible to enforce a transport if you dont bind to an address and communicate between the actors
Vladimir Boiarkin
@vladmir-boy
@Lutando thanks! Serialization worked!
This message was deleted
I actually bind to address and my actors then just look
SenderActor = actorSystem.ActorOf<SenderActor>();
RecipientActor = actorSystem.ActorOf<RecipientActor>();
and I assume communication like RecipientActor.Tell(new EventHappened(), SenderActor);
does not trigger networking
Lutando Ngqakaza
@Lutando
I think if youre using the default actor ref provider it wont trigger networking, you must be using Akka.Remote to get transport stuff working I think.
Vladimir Boiarkin
@vladmir-boy
I use the Cluster one
Lutando Ngqakaza
@Lutando
yeah then should be good
I think you need to check what IActorRef you have there, if it is LocalActorRef then it wont use a transport, that is inproc
Zetanova
@Zetanova
@Aaronontheweb Would it be a problem to make the hocon config convertable from and to yaml ? I currently see only a problem with the the dotnet type names used as keynames in diff. sections like akka.persistence.journal.eventstore.event-adapter-bindings
Zetanova
@Zetanova
And is it possible to get or generate some kind of cluster-id to use as debug/logging?
Bartosz Sypytkowski
@Horusiath

And is it possible to get or generate some kind of cluster-id to use as debug/logging?

@Zetanova actor system name?

Would it be a problem to make the hocon config convertable from and to yaml ?

I was advocating making config statically typed and convertible from different formats, but it's pretty to achieve right now (and pretty much impossible without making major breaking changes).

Mike Clark
@mclark1129
It doesn't appear that Akka.Streams.SQS or Alpakka is available as a nuget package. Am I looking in the wrong place?
Zetanova
@Zetanova
@Horusiath The actor system name needs to be on all nodes the same or not? I have currently 3 seed nodes in k8s and if i make a rolling update the the last updated node / first node in the seed list is always starting a new cluster. It sends InitJoin to the other seednodes, they replay with InitJoinNack and it starts a new cluster
sry it instantly joining itself and then sends InitJoin to the to others with a reply of InitJoinNack
Bartosz Sypytkowski
@Horusiath
@Zetanova maybe first we should define what do you mean by cluster-id? I was thinking that you meant unique idenfier of the cluster, shared by all nodes belonging to it.
@mclark1129 is it possible, that Akka.Streams.SQS was not released yet
Zetanova
@Zetanova
@Horusiath yes, something like this. I am rolling out an update for the 3seeds nodes in k8s and i think got splitbrain, using static-quorum with quarum size 2, the last node "seednode-0" is allways joing itself instantly
and now downing happens
Bartosz Sypytkowski
@Horusiath
why do you do rolling updates of seed nodes?
Zetanova
@Zetanova
new image
seednode-2 is restarting, getting ready joing the cluster
seednode-1 is restarting getting ready joing the cluster (seednode-0 is still the leader)
Bartosz Sypytkowski
@Horusiath
also, if you start seed nodes, they will try to join to each other in the order which you've specified - so if you have first node which has 3 seeds, but it's pointing to itself as first one, it can create a new cluster by itself
Zetanova
@Zetanova
seednode-0 is restarting getting ready joing itself (seednode-2 is the leader and seednode-0 made a new clusteer)
the seednode is not testing the other seednode in the list?
in the docs is standing explicitly that the seednodelist should be the same for all nodes and seednodes
if its true, i can just put the self seednode entry to the end
"A special rule applies the first time a cluster forms: the first seed node declared in a akka.cluster.seed-nodes list must be up. Otherwise the cluster will not form. This is designed to prevent a split brain from forming the first time a cluster launches. And in general, as a best practice: always use an identical seed node list on every node, including the seed nodes. This will give you the most consistent behavior and results."
this implies then that first seed node will always form a new cluster when it restarts and never join someone already up
Vasily Kirichenko
@vasily-kirichenko

hi, guys. I need a Lighthouse instance running locally so that my apps could specify it as a seed like akka.tcp://test@localhost:4053 to make it workable on any dev machine. I have the following akka.hocon:

remote {
    log-remote-lifecycle-events = DEBUG
    dot-netty.tcp {
      transport-class = "Akka.Remote.Transport.DotNetty.TcpTransport, Akka.Remote"
      applied-adapters = []
      transport-protocol = tcp
      public-hostname = "127.0.0.1"
      hostname = "127.0.0.1"
      port = 4053
    }
  }

but it still uses my host name (kirichenko-xp):

[INFO][21.08.2019 9:29:00][Thread 0001][remoting] Starting remoting
[INFO][21.08.2019 9:29:00][Thread 0001][remoting] Remoting started; listening on addresses : [akka.tcp://local@kirichenko-xp:4053]
[INFO][21.08.2019 9:29:00][Thread 0001][remoting] Remoting now listens on addresses: [akka.tcp://local@kirichenko-xp:4053]
[INFO][21.08.2019 9:29:00][Thread 0001][Cluster] Cluster Node [akka.tcp://local@kirichenko-xp:4053] - Starting up...
[INFO][21.08.2019 9:29:00][Thread 0001][Cluster] Cluster Node [akka.tcp://local@kirichenko-xp:4053] - Started up successfully
Zetanova
@Zetanova
@vasily-kirichenko public-hostname = "localhost" hostname = "127.0.0.1"
Vasily Kirichenko
@vasily-kirichenko
@Zetanova it's not helped :(
[Unspecified/localhost:9110] pbm> cluster show
akka.tcp://local@kirichenko-xp:4053 | [lighthouse] | up |
Count: 1 nodes