REST API: Contact are wrongly created when creating in parallel

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • PiotrB
    Junior Member
    • Jan 2019
    • 3

    REST API: Contact are wrongly created when creating in parallel

    Hi, I'm creating 10 contacts in parallel:

    Code:
    for i in `seq 1 10`;
    do
      curl "https://donald-syncduck.espocloud.eu/api/v1/contact" \
        -H "Espo-Authorization: $AUTH" \
        -X POST -H "Content-Type: application/json" \
        -d "{\"emailAddress\": \"test-bug-003-$i@syncduck.com\"}" \
        -v -i > response-$i.log &
    done
    Not all contacts are created as expected. For example this one:

    Code:
    → cat response-4.log
    HTTP/1.1 200 OK
    Server: nginx
    Date: Mon, 21 Jan 2019 13:58:00 GMT
    Content-Type: text/html;charset=UTF-8
    Transfer-Encoding: chunked
    Connection: keep-alive
    Strict-Transport-Security: max-age=63072000; includeSubdomains; preload
    X-Frame-Options: DENY
    There is no body returned.

    See how it looks like in the UI:

    Click image for larger version

Name:	screenshot-2019-01-21-15-02.png
Views:	131
Size:	72.2 KB
ID:	45142

    You can see that 4 emails are missing there
  • yuri
    Member
    • Mar 2014
    • 8440

    #2
    Hi Piotr,

    Did you try on 5.5.6 version?

    Thanks
    If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.

    Comment

    • PiotrB
      Junior Member
      • Jan 2019
      • 3

      #3
      It seems to be fixed in 5.5.6 version. I can't reproduce it any more. Thanks

      Comment

      Working...