Example #1
0
 private void RunAction(Action <IAssemblyBootstrapper> action, IAssemblyBootstrapper instance, string name)
 {
     try
     {
         action(instance);
     }
     catch (Exception e)
     {
         Console.WriteLine($"Failed to {name} in bootstrapper. Type={instance.GetType().FullName}. Exception={e}");
     }
 }
Example #2
0
 private static Assembly GetAssemblyFromBootstrapper(IAssemblyBootstrapper bootstrapper)
 {
     return(Assembly.GetAssembly(bootstrapper.GetType()));
 }
        private void RunAction(Action <IAssemblyBootstrapper> action, IAssemblyBootstrapper instance, string name)
        {
            try
            {
                action(instance);
            }
            catch (Exception e)
            {
#pragma warning disable Serilog004 // Constant MessageTemplate verifier
                Log.Warning(e, $"Failed to {name} in bootstrapper. Type={{BootstrapperType}}", instance.GetType().FullName);
#pragma warning restore Serilog004 // Constant MessageTemplate verifier
            }
        }