2022-01-12 17:19:51.055 +08:00 [INF] User profile is available. Using 'C:\Users\changketec\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
2022-01-12 17:19:51.979 +08:00 [INF] Now listening on: https://localhost:9977
2022-01-12 17:31:46.374 +08:00 [INF] User profile is available. Using 'C:\Users\changketec\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
2022-01-12 17:31:47.037 +08:00 [INF] Now listening on: https://localhost:9977
2022-01-12 17:33:11.114 +08:00 [INF] User profile is available. Using 'C:\Users\changketec\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
2022-01-12 17:33:12.190 +08:00 [INF] Now listening on: https://localhost:9977
2022-01-12 17:35:05.837 +08:00 [INF] User profile is available. Using 'C:\Users\changketec\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
2022-01-12 17:35:06.422 +08:00 [INF] Now listening on: https://localhost:9977
2022-01-12 17:36:29.281 +08:00 [INF] User profile is available. Using 'C:\Users\changketec\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
2022-01-12 17:36:29.844 +08:00 [INF] Now listening on: https://localhost:9977
2022-01-12 17:37:16.733 +08:00 [INF] Executed action method Win_in.Sfs.Scp.WebApi.XmlHost.Controllers.PurchaseOrderController.CreateAsync (Win_in.Sfs.Scp.WebApi.Xml.Host), returned result Microsoft.AspNetCore.Mvc.OkObjectResult in 20166.7287ms.
2022-01-12 17:37:16.749 +08:00 [INF] Executing OkObjectResult, writing value of type 'Win_in.Sfs.Scp.WebApi.PurchaseOrderDTO'.
2022-01-12 17:37:16.777 +08:00 [INF] Executed action Win_in.Sfs.Scp.WebApi.XmlHost.Controllers.PurchaseOrderController.CreateAsync (Win_in.Sfs.Scp.WebApi.Xml.Host) in 28470.3143ms
2022-01-12 17:37:16.781 +08:00 [ERR] An unhandled exception has occurred while executing the request.
System.Runtime.Serialization.InvalidDataContractException: Type 'Win_in.Sfs.Scp.WebApi.PurchaseOrderDetailDTO' with CollectionDataContractAttribute attribute is an invalid collection type since it does not implement IEnumerable interface.
at System.Runtime.Serialization.DataContract.DataContractCriticalHelper.CreateDataContract(Type type)
at System.Runtime.Serialization.DataContract.DataContractCriticalHelper.CreateDataContract(Int32 id, RuntimeTypeHandle typeHandle, Type type)
at System.Runtime.Serialization.DataContract.DataContractCriticalHelper.GetDataContractSkipValidation(Int32 id, RuntimeTypeHandle typeHandle, Type type)
at System.Runtime.Serialization.XmlObjectSerializerContext.GetDataContract(Int32 id, RuntimeTypeHandle typeHandle)
at WritePurchaseOrderDTOToXml(XmlWriterDelegator , Object , XmlObjectSerializerWriteContext , ClassDataContract )
at System.Runtime.Serialization.ClassDataContract.WriteXmlValue(XmlWriterDelegator xmlWriter, Object obj, XmlObjectSerializerWriteContext context)
at System.Runtime.Serialization.XmlObjectSerializerWriteContext.WriteDataContractValue(DataContract dataContract, XmlWriterDelegator xmlWriter, Object obj, RuntimeTypeHandle declaredTypeHandle)
at System.Runtime.Serialization.XmlObjectSerializerWriteContext.SerializeWithoutXsiType(DataContract dataContract, XmlWriterDelegator xmlWriter, Object obj, RuntimeTypeHandle declaredTypeHandle)
at System.Runtime.Serialization.DataContractSerializer.InternalWriteObjectContent(XmlWriterDelegator writer, Object graph, DataContractResolver dataContractResolver)
at System.Runtime.Serialization.DataContractSerializer.InternalWriteObject(XmlWriterDelegator writer, Object graph, DataContractResolver dataContractResolver)
at System.Runtime.Serialization.XmlObjectSerializer.WriteObjectHandleExceptions(XmlWriterDelegator writer, Object graph, DataContractResolver dataContractResolver)
at System.Runtime.Serialization.DataContractSerializer.WriteObject(XmlWriter writer, Object graph)
at Microsoft.AspNetCore.Mvc.Formatters.XmlDataContractSerializerOutputFormatter.WriteResponseBodyAsync(OutputFormatterWriteContext context, Encoding selectedEncoding)
at Microsoft.AspNetCore.Mvc.Formatters.XmlDataContractSerializerOutputFormatter.WriteResponseBodyAsync(OutputFormatterWriteContext context, Encoding selectedEncoding)
at Microsoft.AspNetCore.Mvc.Formatters.XmlDataContractSerializerOutputFormatter.WriteResponseBodyAsync(OutputFormatterWriteContext context, Encoding selectedEncoding)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeResultAsync>g__Logged|21_0(ResourceInvoker invoker, IActionResult result)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResultFilterAsync>g__Awaited|29_0[TFilter,TFilterAsync](ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResultExecutedContextSealed context)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.ResultNext[TFilter,TFilterAsync](State& next, Scope& scope, Object& state, Boolean& isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeResultFilters()
--- End of stack trace from previous location ---
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResourceFilter>g__Awaited|24_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeFilterPipelineAsync>g__Awaited|19_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Logged|17_1(ResourceInvoker invoker)
at Microsoft.AspNetCore.Routing.EndpointMiddleware.<Invoke>g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger)
at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
at Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.Invoke(HttpContext httpContext)
at Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider)
at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddleware.Invoke(HttpContext context)
2022-01-12 17:38:14.457 +08:00 [INF] User profile is available. Using 'C:\Users\changketec\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
2022-01-12 17:38:15.160 +08:00 [INF] Now listening on: https://localhost:9977
2022-01-12 17:38:33.377 +08:00 [INF] Executed action method Win_in.Sfs.Scp.WebApi.XmlHost.Controllers.PurchaseOrderController.CreateAsync (Win_in.Sfs.Scp.WebApi.Xml.Host), returned result Microsoft.AspNetCore.Mvc.OkObjectResult in 2003.0938ms.
2022-01-12 17:38:33.386 +08:00 [INF] Executing OkObjectResult, writing value of type 'Win_in.Sfs.Scp.WebApi.PurchaseOrderDTO'.
2022-01-12 17:38:33.402 +08:00 [INF] Executed action Win_in.Sfs.Scp.WebApi.XmlHost.Controllers.PurchaseOrderController.CreateAsync (Win_in.Sfs.Scp.WebApi.Xml.Host) in 3855.5986ms