Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • 20:47
    IgorFedchenko commented #4085
  • 20:46
    IgorFedchenko commented #4085
  • 15:09
    IgorFedchenko commented #4085
  • 11:24
    Kenji-Tanaka commented #3887
  • 10:45
    nagytech edited #4086
  • 10:45
    nagytech synchronize #4086
  • 10:43
    nagytech opened #4086
  • 09:00
    Horusiath commented #4077
  • 06:31
    Aaronontheweb commented #4085
  • 06:28
    Aaronontheweb commented #4085
  • 06:24
    Aaronontheweb commented #4085
  • Dec 07 11:49
    IgorFedchenko commented #4085
  • Dec 07 10:31
    IgorFedchenko commented #4085
  • Dec 07 08:36
    IgorFedchenko commented #4085
  • Dec 06 20:57
    IgorFedchenko commented #4085
  • Dec 06 20:32
    IgorFedchenko commented #4085
  • Dec 06 20:01
    IgorFedchenko commented #4085
  • Dec 06 19:55
    IgorFedchenko commented #4085
  • Dec 06 16:22
    Aaronontheweb labeled #3997
  • Dec 06 16:22
    Aaronontheweb closed #3997
Zetanova
@Zetanova
MyBase.dll
MySystem.dll
yes it can work, but its slow and very error prone
Vagif Abilov
@object
@Horusiath PR is submitted with clarification in PR comment.
Jeff Cyr
@JeffCyr
@mmisztal1980 When you run multiple service fabric node on the same physical host, the service endpoint's port is not shared, all service instance will be assigned a different private port that is retrievable through the service endpoint
Zetanova
@Zetanova
@Ciantic its a realy good idea to imeplement the messages in a shared assembly. It is basicly the contract definition without it you can pass JSON strings around, that would be even better then the interfaces
Maciek Misztal
@mmisztal1980
@JeffCyr Hi Jeff, can you point me to some material on this matter please?
Arjen Smits
@Danthar
@Ciantic What if you deploy multiple actors which "implement" the same interface ? (because your using a router/pool) How would your glue code handle that ?
Jari Pennanen
@Ciantic
@Danthar I haven't really thought this out, but I just find the idea that my listener need not to agree on one message assembly intriguing, it would allow me to write e.g. user service, and if I don't update my listeners they still work if their message fields matches with it
it is more error prone yes
but the listener could be even in different language
they just agree that with this string, I get this json
Arjen Smits
@Danthar
what is the role of your listener ? Where does it sit in your architecture ?
Jari Pennanen
@Ciantic
well the listnere need to be able to talk back in that example
e.g. "ResetPassword"
Arjen Smits
@Danthar
Ok, well because it sounds to me what your looking for is an "magic" solution to API versioning.
Jari Pennanen
@Ciantic
well, if the listener is in different language, it couldn't be bound to as
shared message assembly
it has to agree like string "MyCompany.OtherAssembly.Greet" matches with { Greet: string }
{ Who: string }
Arjen Smits
@Danthar
Akka.net is .net only. We dont have wire level compatibility with the JVM version. (yet) So im not sure thats actually a problem.
Jari Pennanen
@Ciantic
I have to look how the Scala version's HTTP layer works
it can be used from other languages
Arjen Smits
@Danthar
Not familiar with the framework. But im guessing it works because of the common well known protocol namely HTTP ?
Jari Pennanen
@Ciantic
@Danthar yes, but if you send Something.Greet, it must send the name of the item also
not only the json
Zetanova
@Zetanova
@Ciantic Newton Json serializer includes the type into the payload
But i dont know how u will conect to akka system with a differnt "languge" that cant reference akka.remote assembly
Jari Pennanen
@Ciantic
@Zetanova apparently I can't, but someday when .NET Akka supports HTTP it maybe possible
looking now how to "curl in to Akka.io"
Zetanova
@Zetanova
write an warpper
with WebAPI and singularR and hosted with owin or IIS
it includes security too
there you can map the messages, handle unrelated commands like subscription/unsubscriptions connect/disconnect
and make versioning easy happen
its good for native apps too,
Zetanova
@Zetanova
singnalR has some support for different languages
Marc Piechura
@marcpiechura
@Ciantic if you refer to Akka.http, I wouldn't wait for it ;) it took 4 people and two years or so to build this on the jvm
Arjen Smits
@Danthar
I do think that a small abstraction layer between something like Nancy and Akka.net could go a long way
But even then you'd have come up with a communication protocol. And... well..... before you know it, your redefining something like the SOAP envelope :P
Bartosz Sypytkowski
@Horusiath
@Ciantic Akka.Http is a web framework written on top of akka, not a transport layer for the cluster
@object thx, I'll try to take a look at it this evening
ilhadad
@ilhadad

Ok got rid of the ask pattern and instead used a message scheduler to time out. here is the new code and config on the sender side:
CODE:

            //Attempt to get a list of supervisors from the SupervisorRegistry
            SupervisorRegistryGetListRequest request = new SupervisorRegistryGetListRequest(Self);
            _SupervisorRegistry.Tell(request);

            var timeout = Context.System.Scheduler.ScheduleTellOnceCancelable(1000, Self, new SupervisorRegistryGetListEvent(request, null, false), Self);

            Receive<SupervisorRegistryGetListEvent>(e => {

                if(e.Success)
                {
                    _logger.Info("{0} Received supervisor list.", Self.Path.ToStringWithAddress());

                    timeout.Cancel();

                    // Save the list for internal use
                    _AreaToSupervisorActor = e.ResponseGetList.SupervisorDictionary;

                    _logger.Debug("Actor {0} is Initialized, moving to Ready state.", _ActorType);
                    Become(Ready);

                }
                else
                {
                    _logger.Warning("{0} Cannot retrieve list of supervisors. Unable to initialize.  {1} retries.", Self.Path.ToStringWithAddress(), _FetchSupervisorListReties);

                    // retry the request and increase the timeout
                    _FetchSupervisorListReties++;

                    // Set up the timeout
                    timeout = Context.System.Scheduler.ScheduleTellOnceCancelable(1000*_FetchSupervisorListReties, Self, new SupervisorRegistryGetListEvent(request, null, false), Self);

                    // Send the request again
                    _SupervisorRegistry.Tell(request);

                }

and the config on the sender side:

akka {
                    # here we are configuring log levels
                    log-config-on-start = off
                    stdout-loglevel = DEBUG
                    loglevel = DEBUG

          // Define an Nlog logger for the Akka system
          loggers = ["Akka.Logger.NLog.NLogLogger, Akka.Logger.NLog"]

            actor {
              provider = "Akka.Remote.RemoteActorRefProvider, Akka.Remote"
            }

            remote {
                            log-remote-lifecycle-events = DEBUG
                            log-received-messages = on

            helios.tcp {
                                hostname = "127.0.0.1"
                                port = 8777
              }
            }
And here is the new config and code on the receiver side:
        private void HandleGetListRequest(SupervisorRegistryGetListRequest r)
        {
            ImmutableDictionary<MicroServices.Area,IActorRef> immutableDictOfSupervisorsActors = 
                _KnownSupervisorsActors.ToImmutableDictionary(kvp => kvp.Key, kvp => kvp.Value.SupervisorActorReference);

            Sender.Tell(new SupervisorRegistryGetListResponse(r.Requestor,immutableDictOfSupervisorsActors,r));

        }
                akka {
                    # here we are configuring log levels
                    log-config-on-start = off
                    stdout-loglevel = DEBUG
                    loglevel = DEBUG

          // Define an Nlog logger for the Akka system
          loggers = ["Akka.Logger.NLog.NLogLogger, Akka.Logger.NLog"]

          // Enables connectivity to the remote ActorSystemBridge
          actor {
              provider = "Akka.Remote.RemoteActorRefProvider, Akka.Remote"
          }

          remote {
            helios.tcp {
                port = 8888
                hostname = "127.0.0.1"
            }
          }

                }

@Horusiath I took out the cluster

Ok got rid of the ask pattern and instead used a message scheduler to time out. here is the new code and config on the sender side:
CODE

            //Attempt to get a list of supervisors from the SupervisorRegistry
            SupervisorRegistryGetListRequest request = new SupervisorRegistryGetListRequest(Self);
            _SupervisorRegistry.Tell(request);

            var timeout = Context.System.Scheduler.ScheduleTellOnceCancelable(1000, Self, new SupervisorRegistryGetListEvent(request, null, false), Self);

            Receive<SupervisorRegistryGetListEvent>(e => {

                if(e.Success)
                {
                    _logger.Info("{0} Received supervisor list.", Self.Path.ToStringWithAddress());

                    timeout.Cancel();

                    // Save the list for internal use
                    _AreaToSupervisorActor = e.ResponseGetList.SupervisorDictionary;

                    _logger.Debug("Actor {0} is Initialized, moving to Ready state.", _ActorType);
                    Become(Ready);

                }
                else
                {
                    _logger.Warning("{0} Cannot retrieve list of supervisors. Unable to initialize.  {1} retries.", Self.Path.ToStringWithAddress(), _FetchSupervisorListReties);

                    // retry the request and increase the timeout
                    _FetchSupervisorListReties++;

                    // Set up the timeout
                    timeout = Context.System.Scheduler.ScheduleTellOnceCancelable(1000*_FetchSupervisorListReties, Self, new SupervisorRegistryGetListEvent(request, null, false), Self);

                    // Send the request again
                    _SupervisorRegistry.Tell(request);

                }

and the config on the sender side:


akka {
                    # here we are configuring log levels
                    log-config-on-start = off
                    stdout-loglevel = DEBUG
                    loglevel = DEBUG

          // Define an Nlog logger for the Akka system
          loggers = ["Akka.Logger.NLog.NLogLogger, Akka.Logger.NLog"]

            actor {
              provider = "Akka.Remote.RemoteActorRefProvider, Akka.Remote"
            }

            remote {
                            log-remote-lifecycle-events = DEBUG
                            log-received-messages = on

            helios.tcp {
                                hostname = "127.0.0.1"
                                port = 8777
              }
            }
ilhadad
@ilhadad
How can I examine dead letters to see what's going on? Also how do I get the logger to give me more info as to the root issue? Any other suggestions?
Kris Schepers
@schepersk
Any idea when the new SqlServer persistence package will be available?
ilhadad
@ilhadad
@Horusiath I was able to subscribe to the event stream to pull the dead letters it seems the messages are arriving at the remote system but they are all landing in deadletters. Not sure how to figure out what's wrong by looking at the deadletters. Any suggestions?
Bartosz Sypytkowski
@Horusiath
@ilhadad either the message recipient is dead, was not created, or its address is wrong