public async Task Consume(ConsumeContext <IStandardIdentifierMap> context)
 {
     if (EasyAccessMessageFilter.OfInterest(context.Message, MachineOrigin))
     {
         await _resourceService.UpdateInstanceIdMap(context.Message);
     }
 }
 public Task Consume(ConsumeContext <IStandardAttachment> context)
 {
     Debug.WriteLine(context.Message.ToString());
     if (EasyAccessMessageFilter.OfInterest(context.Message, MachineOrigin))
     {
         //Do stuff
     }
     return(Task.FromResult(0));
 }
 public Task Consume(ConsumeContext <IStandardComment> context)
 {
     Debug.WriteLine(context.Message.Content);
     if (EasyAccessMessageFilter.OfInterest(context.Message, MachineOrigin))
     {
         _resourceService.CreateCommentAsync(context.Message);
     }
     return(Task.FromResult(0));
 }
        public async Task Consume(ConsumeContext <IStandardInstance> context)
        {
            var instance = context.Message;

            Debug.WriteLine("Consumed IStandardInstance at EasyAccess: " + context.Message.ToString());
            if (EasyAccessMessageFilter.OfInterest(context.Message, MachineOrigin))
            {
                switch (context.Message.Action.ToLower())
                {
                case "created":
                    Debug.WriteLine("Creating instance...");
                    var handledInstance = await HandleCreation(instance);

                    break;

                case "updated":
                    Debug.WriteLine("Updating instance...");
                    await HandleUpdate(instance);

                    break;
                }
            }
        }