web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Suggested answer

Regarding batch Job

(0) ShareShare
ReportReport
Posted on by 10

I have a staging table that stores product receipt data, which is populated via a custom service integration. Now, I need to trigger a batch job asynchronously whenever new data is inserted into this table. The batch job should perform standard validations and post the product receipt.

I've completed the part where data is successfully pushed into the staging table through the service. I’m now looking for guidance on creating the batch job.

Can this be achieved using just a single service operation class? Is it necessary to include a contract and controller class? Also, how can I ensure the batch runs asynchronously?

Categories:
I have the same question (0)
  • Suggested answer
    Martin Dráb Profile Picture
    236,638 Most Valuable Professional on at
    Regarding batch Job
    You didn't mention with D365 product you're talking about, but I'm assuming you mean F&O and the SysOperation framework.
     
    You don't need a contract class if you don't need any parameters. You may want the batch to process a specific record (which requires a parameter identifying the record) or to process all (pending) records (and then you don't need any parameter).
     
    You technically can utilize the standard controller, but you should rather create a custom controller inheriting from the standard one. This allows you to give the batch a name and to identify the service inside the controller.
     
    Batch processing is asynchronous by definition. The execution mode for batches is SysOperationExecutionMode::ScheduledBatch, although you may also want to use ReliableAsynchronous.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 69 Super User 2025 Season 2

#2
CA Neeraj Kumar Profile Picture

CA Neeraj Kumar 60

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 50 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans