• Resolved Balvant

    (@balvantk)


    Hello,

    It’s blocking any request on product retrievals or inserts when more than 1 thread at a time is called

    • Example:
      – Product retrievals are paginated, limited to 100 products at a time.
      – If I multithread the product retrieval, for example call 10 calls retrieving 100 products each (1-page), to receive a total of 1000 products, we get 503 errors.
      – If I call one page retrieval at a time it works, but this is too slow.
      – Standard WooCommerce API call allows for this, Dokan seems thread limited

    I basically figure out how many pages are required to call, then spawn off threads for each page making the call to this function. I use this exact same code successfully with WooCommerce API. I increment the page number as needed.

    params = {“page”: 1, “per_page”: 100} Get first page of results

    endpoint = f”{self.base_url}/wp-json/dokan/v1/stores/{self.vendor_id}/products”
    results = requests.get(endpoint, headers=self.get_headers(), params=params)

    • Standard WooCommerce API call allows for this, Dokan seems thread limited
    • This topic was modified 1 month, 2 weeks ago by Balvant.
Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Tanvir Hasan

    (@tanvirh)

    Hi @balvantk

    As you’ve identified, Dokan has a thread limitation that is causing the 503 errors when multiple threads are used for product retrieval or inserts. Unfortunately, increasing the thread limit would require advanced customization of Dokan’s codebase.

    To achieve this, we recommend consulting with a professional API integration expert who can assist you in modifying the existing functionality to suit your requirements.

    Thanks!

    Thread Starter Balvant

    (@balvantk)

    Tanvir Hasan Thank you for reply.

    Ok, tell me how to customize the plugin code.

    Plugin Support Tanvir Hasan

    (@tanvirh)

    Hi @balvantk

    Due to our support policy, we are unable to assist with modifying Dokan functionality. We recommend consulting with a professional WordPress and Dokan customization expert for further assistance.

    Thanks!

    Plugin Support Tanvir Hasan

    (@tanvirh)

    Hi @balvantk

    As we haven’t heard back from you for a while, we’ll consider this topic resolved. If you encounter any further issues, please don’t hesitate to open a new topic.

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.