Expand my Community achievements bar.

We are excited to introduce our latest innovation to enhance the Adobe Campaign user experience — the Adobe Campaign v8 Web User Interface!

Concurrent REST API calls

Avatar

Level 3

We are using the ACS REST API to insert/update records on submission of a web form. The web form is a basic registration form with first name, last name, email address.

The API is able to insert/update records in the Profile table.

However, when there are simultaneous web form submissions, each web form having it's own API call, we expect only ONE record in the database. One of the API would insert and the other API would update the record.

However, we see 2 records inserted in the Profile table since the API is called at the same time

Does anyone know how this "race condition" is handled within REST API calls?

Do the ACS API calls run sequentially?

Do we need to add unique constraints in the DB to avoid double inserts? 

What is the best practice to avoid such conditions?

Thanks,

Ishani

2 Replies

Avatar

Employee

Hi Ishani,

Are you using a pre-loading inside the webapp?

Avatar

Level 3

Hi Vipul,

The web apps are created by the client and are residing on their website . They're not pre-loading data.

They're using ACS REST API calls to insert/update data in Profile table.

Thanks,

Ishani