Open Closed

Getting The operation was canceled excpetion with 7.4.2. #6862


User avatar
0
arvind.srivastava.tas created

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, and please first use the search on the homepage. Provide us with the following info:

  • ABP Framework version: 7.4.2
  • UI Type: Angular /
  • Database System: EF Core (PostgreSQL.)
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes
  • Exception message and full stack trace: Timestamp - 03/07/2024 09:25:16 +00:00 | Level - Error | Message The operation was canceled. { "SourceContext": { "Value": "Volo.Abp.AspNetCore.ExceptionHandling.AbpExceptionHandlingMiddleware" }, "RequestId": { "Value": "0HN1UG5GQEH55:00000005" }, "RequestPath": { "Value": "/invoice/api/InvoiceManagement/AR/FX/invoice/getInvoicesListByStatusId" }, "ConnectionId": { "Value": "0HN1UG5GQEH55" }, "TenantName": { "Value": "Product" } }

Exception - System.OperationCanceledException: The operation was canceled.

at System.Threading.CancellationToken.ThrowOperationCanceledException()

at Npgsql.Internal.NpgsqlConnector.g__DoStartUserAction|279_0(ConnectorState newState, NpgsqlCommand command, <&gt;c__DisplayClass279_0&)

at Npgsql.Internal.NpgsqlConnector.StartUserAction(ConnectorState newState, NpgsqlCommand command, CancellationToken cancellationToken, Boolean attemptPgCancellation)

at Npgsql.NpgsqlTransaction.Commit(Boolean async, CancellationToken cancellationToken)

at Microsoft.EntityFrameworkCore.Storage.RelationalTransaction.CommitAsync(CancellationToken cancellationToken)

at Microsoft.EntityFrameworkCore.Storage.RelationalTransaction.CommitAsync(CancellationToken cancellationToken)

at Volo.Abp.Uow.EntityFrameworkCore.EfCoreTransactionApi.CommitAsync(CancellationToken cancellationToken)

at Volo.Abp.Uow.UnitOfWork.CommitTransactionsAsync(CancellationToken cancellationToken)

at Volo.Abp.Uow.UnitOfWork.CompleteAsync(CancellationToken cancellationToken)

at Volo.Abp.AspNetCore.Uow.AbpUnitOfWorkMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)

at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass6_1.<b__1>d.MoveNext()

--- End of stack trace from previous location ---

at Volo.Abp.AspNetCore.ExceptionHandling.AbpExceptionHandlingMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)

  • Steps to reproduce the issue:

Sample code we are using [Obsolete] public async Task&lt;List> GetListAsyncByStatusId( DateTime? fromDueDate, DateTime? toDueDate, bool isActive, int statusId = 0, string sorting = null, int maxResultCount = int.MaxValue, int skipCount = 0, string invoiceNumber = null, List buyerCodes = null, List BuyerMarketUserCodes = null, List invoiceCurreincies = null, List invoiceDueStatuses = null, List proofAvailables = null, CancellationToken cancellationToken = default) { var query = ApplyFilterByStatusId(DbSet, fromDueDate, toDueDate, isActive, statusId, invoiceNumber, buyerCodes, BuyerMarketUserCodes, invoiceCurreincies, invoiceDueStatuses, proofAvailables); query = query.OrderBy(string.IsNullOrWhiteSpace(sorting) ? InvoiceConsts.DefaultSorting : sorting); return await query.PageBy(skipCount, maxResultCount).ToListAsync(cancellationToken); }

Markdown supported.
Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)

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

    Hello ,

    Can you give more steps to reproduce the issue ?

    Thank you.

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    arvind.srivastava.tas created

    Getting this error when we are invoking this API. invoice/api/InvoiceManagement/AR/FX/invoice/getInvoicesListByStatusId

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.8.0-preview. Updated on September 16, 2026, 07:12
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.