Skip to content

Commit

Permalink
More logging cleanup.
Browse files Browse the repository at this point in the history
  • Loading branch information
ScottArbeit committed Oct 28, 2023
1 parent 0d88ed5 commit e5a4c64
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/Grace.Actors/Branch.Actor.fs
Original file line number Diff line number Diff line change
Expand Up @@ -118,14 +118,13 @@ module Branch =
actorStartTime <- getCurrentInstant()
logScope <- log.BeginScope("Actor {actorName}", actorName)
currentCommand <- String.Empty
//log.LogInformation("{CurrentInstant}: Started {ActorName}.{MethodName} Id: {Id}.", getCurrentInstantExtended(), actorName, context.MethodName, this.Id)
log.LogTrace("{CurrentInstant}: Started {ActorName}.{MethodName} Id: {Id}.", getCurrentInstantExtended(), actorName, context.MethodName, this.Id)

// This checks if the actor is still active, but in an undefined state, which will _almost_ never happen.
// isDisposed is set when the actor is deleted, or if an error occurs where we're not sure of the state and want to reload from the database.
if isDisposed then
this.OnActivateAsync().Wait()
isDisposed <- false

Task.CompletedTask

override this.OnPostActorMethodAsync(context) =
Expand Down
2 changes: 1 addition & 1 deletion src/Grace.Actors/Diff.Actor.fs
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ module Diff =
override this.OnPreActorMethodAsync(context) =
actorStartTime <- getCurrentInstant()
logScope <- log.BeginScope("Actor {actorName}", actorName)
//log.LogInformation("{CurrentInstant}: Started {ActorName}.{MethodName} Id: {Id}.", getCurrentInstantExtended(), actorName, context.MethodName, this.Id)
log.LogTrace("{CurrentInstant}: Started {ActorName}.{MethodName} Id: {Id}.", getCurrentInstantExtended(), actorName, context.MethodName, this.Id)
Task.CompletedTask

override this.OnPostActorMethodAsync(context) =
Expand Down
2 changes: 0 additions & 2 deletions src/Grace.Actors/Owner.Actor.fs
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,6 @@ module Owner =
if isDisposed then
this.OnActivateAsync().Wait()
isDisposed <- false

//log.LogInformation("{CurrentInstant}: Started {ActorName}.{MethodName} Id: {Id}.", getCurrentInstantExtended(), actorName, context.MethodName, this.Id)
Task.CompletedTask

override this.OnPostActorMethodAsync(context) =
Expand Down

0 comments on commit e5a4c64

Please sign in to comment.