Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Power Apps Pro Dev & ISV
Unanswered

Where can I find the 'optimized APIs for bulk data operations' documents?

(0) ShareShare
ReportReport
Posted on by

I have seen it in wave2 document: https://learn.microsoft.com/en-us/power-platform-release-plan/2022wave2/data-platform/use-optimized-apis-bulk-data-operations?source=recommendations

 

We are very eager to use this feature to improve performance when some business logic need to do bulk update/insert.

 

I saw in October it should became public preview, but I can't find it anywhere. Can somebody help? Thanks in advance.

  • Community Power Platform Member Profile Picture
    on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    @MattB-MSFT wrote:

    @Anonymous wrote:

    executeMultiple is not supported in plugin, any request in plugin have to executed one by one.


    for clarity sake,  ExecuteMultiple can be called from a plugin.   
    I think your meaning to say "I cannot attach a plugin to the invocation of ExecuteMultiple",  that is correct, you cannot do that.  This is a lot to do with what ExecuteMultiple is designed to do and how it works in the SDK. ExecuteMultiple is a 'batch' concept where messages can be anything.


    ExecuteMultiple is not supported inside a plugin, check this out:

    https://learn.microsoft.com/en-us/power-apps/developer/data-platform/best-practices/business-logic/avoid-batch-requests-plugin?source=recommendations

     

    I have struggled, tested for these stuff for a long time, the fact is the document is right. Even you can use ExecuteMultiple in plugin by force, the requests still not go into DB concurrently, as the document said, it has same effect of 

     

     

    foreach (request in requests) service.Execute(request)

     

     

     

    On the server side, the operations included in a batch request are executed sequentially and aren't done in parallel. 

     

    Currently I cannot find one single way to do parallel DB actions inside a plugin, that's why I saw the new API as my savior.

  • MattB-MSFT Profile Picture
    Microsoft Employee on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    @Anonymous wrote:

    executeMultiple is not supported in plugin, any request in plugin have to executed one by one.


    for clarity sake,  ExecuteMultiple can be called from a plugin.   
    I think your meaning to say "I cannot attach a plugin to the invocation of ExecuteMultiple",  that is correct, you cannot do that.  This is a lot to do with what ExecuteMultiple is designed to do and how it works in the SDK. ExecuteMultiple is a 'batch' concept where messages can be anything.

  • Community Power Platform Member Profile Picture
    on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    Absolutely right now 100 records' creation should not be put in plugin, because they will executed in plugin one by one most likely it will hit 2mins timeout as you said. But if the creation requests can be concurrent executed as the document said, even 100 records will take few times then it can be inside a plugin reduce a lot of effort.

    Plugin meant for short transactions that's the point I totally agree, but batch update a middle volume(10-100) of records should not be a long action, that' why I need a multiple message. 

  • Guido Preite Profile Picture
    1,488 Super User 2024 Season 1 on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    plugins have a timeout of 2 minutes, let's say you need to create100 records from the plugin, you can't know if they will be created under 2 minutes or not (for example these records can have sync plugins registered too), an executeMultiple also if works as expected probably will not solve this kind of issues. Plugins are meant for short transactions, working on records that require a "multiple" message usually is not.

  • camer314 Profile Picture
    173 on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    Thanks @cchannon. Yes that is another solution, although it is likely we will have server side components anyway, but this may be a neater approach given the necessity to double hop if we do use an api.

  • Community Power Platform Member Profile Picture
    on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    executeMultiple is not supported in plugin, any request in plugin have to executed one by one. That's the pain point while the document in topic said the new api could be used in plugin.

    I understand the idea of Microsoft trying to make any complex logic should not happened in plugin, but in real world it is inevitable that have to implement some critical business logics in plugin, than it become a performance issue when the logic need to have bulk update/insert.

  • cchannon Profile Picture
    4,702 Super User 2025 Season 1 on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    Ah, OK. I missed that you were trying to do this from a PCF in canvas app. Yeah, that does add a fair bit of complexity.

     

    But, it is worth noting that the webAPI object is not supported in PCFs in canvas apps, not the webAPI itself. So, it would still be considered a supported approach to have your own MSAL get token silent, then call the webAPI directly by REST message. Not the easiest thing to put together, but at least it wouldn't require an extra server-side component.

  • camer314 Profile Picture
    173 on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    Thanks @cchannon,

     

    I was hoping to get support directly in a PCF control, as part of a canvas app, which executeMultiple does not support. But yes, I could, at a stretch, have a server side implementation using the .NET SDK as per your link and my PCF communicates with that

  • cchannon Profile Picture
    4,702 Super User 2025 Season 1 on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    OK, well if all you are looking for is to send an array of transactions in one message, I think you should take another look at executeMultiple. There are limitations, to be sure, but this does let you do exactly as you've suggested: throw a whole stack of transactions at the db all in one actual request.

     

    There's also a walkthrough code sample that shows exactly how to use it.

  • camer314 Profile Picture
    173 on at
    Re: Where can I find the 'optimized APIs for bulk data operations' documents?

    This is a weird one because bulk update is literally the same message and mechanics as single update except with an array payload instead of record. You would think this would have been standard functionality 3 years ago. Unfortunately for me, this is the exact functionality, or lack of, that is impacting our use of the platform in a big way.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Leaderboard > Power Apps - Power Apps Pro Dev & ISV

#1
WarrenBelz Profile Picture

WarrenBelz 109 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 82 Super User 2025 Season 1

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 72

Overall leaderboard