File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -172,13 +172,17 @@ private static SubscriptionWorker ConfigureOrderedSubscriptions(ISubscriptionRep
172172
173173 private static void OperatorLogon ( String operatorId )
174174 {
175+ try {
176+ Logger . LogInformation ( $ "About to do auto logon for operator Id [{ operatorId } ]") ;
177+ Func < String , IOperatorProxy > resolver = Startup . ServiceProvider . GetService < Func < String , IOperatorProxy > > ( ) ;
178+ IOperatorProxy proxy = resolver ( operatorId ) ;
175179
176- Logger . LogInformation ( $ "About to do auto logon for operator Id [ { operatorId } ]" ) ;
177- Func < String , IOperatorProxy > resolver = Startup . ServiceProvider . GetService < Func < String , IOperatorProxy > > ( ) ;
178- IOperatorProxy proxy = resolver ( operatorId ) ;
179-
180- OperatorResponse logonResult = proxy . ProcessLogonMessage ( null , CancellationToken . None ) . Result ;
181- Logger . LogInformation ( $ "Auto logon for operator Id [ { operatorId } ] status [ { logonResult . IsSuccessful } ]" ) ;
180+ OperatorResponse logonResult = proxy . ProcessLogonMessage ( null , CancellationToken . None ) . Result ;
181+ Logger . LogInformation ( $ "Auto logon for operator Id [ { operatorId } ] status [ { logonResult . IsSuccessful } ]" ) ;
182+ }
183+ catch ( Exception ex ) {
184+ Logger . LogWarning ( $ "Auto logon for operator Id [ { operatorId } ] failed." ) ;
185+ }
182186 }
183187 }
184188
You can’t perform that action at this time.
0 commit comments