Base solution for your next web application
Open Closed

External API call - Exception occurred while trying to invoke service #7865


User avatar
0
thinkn.tech created

Hi Guys,

Just wonder, if you guys experience before invoke External WCF web service (Third Party WebService) call error in release mode? It run successully in debug mode (window locally) and even i manually created a console to execute via API called at Application project.

My trigger point at Web.Host (Controller) to Application project. At Application project it will fire external third party webservices using "Connected Services"

Error Message as as following:-

ERROR 2019-10-18 00:01:35,722 [54 ] Mvc.ExceptionHandling.AbpExceptionFilter - Exception occurred while trying to invoke service method generatePolicy System.ServiceModel.FaultException: Exception occurred while trying to invoke service method generatePolicy at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc) at System.ServiceModel.Channels.ServiceChannel.EndCall(String action, Object[] outs, IAsyncResult result) at System.ServiceModel.Channels.ServiceChannelProxy.TaskCreator.<>c__DisplayClass1_0.<CreateGenericTask>b__0(IAsyncResult asyncResult) --- End of stack trace from previous location where exception was thrown --- at ThinknInsurTech.ExternalIntg.ExternalIntg.TravelGeneratePolicy(IntegrationTravelGeneratePolicyInput input) at lambda_method(Closure , Object ) at Microsoft.Extensions.Internal.ObjectMethodExecutorAwaitable.Awaiter.GetResult() at Microsoft.AspNetCore.Mvc.Internal.ActionMethodExecutor.AwaitableObjectResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.InvokeActionMethodAsync() at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.InvokeNextActionFilterAsync() at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.Rethrow(ActionExecutedContext context) at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted) at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.InvokeInnerFilterAsync() at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeNextExceptionFilterAsync()


2 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi @thinkn.tech

    We haven't faced anything like that. Are you hosting your app on a different machine when you run it in release mode ? If so, the problem could be related to server configuration you are using (firewall, virus program etc...).

  • User Avatar
    0
    thinkn.tech created

    hi @ismcagdas,

    You are correct. We found out some outbound in firewall not granted.

    Thank you for your hints