Jump to content

Web service - speed up improvement


fred04

Recommended Posts

Hi,

 

I'm updating the database via the web service. All is working fine but it's very very long !!

I have to update a huge quantity of products with a huge quantity of features (above 160,000).

Just to check if each product feature is already in the database the server do it in five or six hours.

I'm on a dedicated server, my cache is active and I do this test in order to know if we will update it :

try{
$webService_feature = new PrestaShopWebservice(PS_SHOP_PATH, PS_WS_AUTH_KEY, DEBUG);
$opt = array('resource' => 'product_feature_values',
	     'filter[id]' => '['.$id.']');
$xml = $webService->get($opt);
}
catch{}
if (sizeof($schema) == 0)
{
...
}

Is there a way to improve the performance ?

Regards.

Link to comment
Share on other sites

Hi fred04,

 

I would do the following:

 

1) Download the product information (and product features) to a local database

 

2) Check in the local database if the features are included in the product or not

 

3) Upload only the changes to Prestashop

 

Checking will be much faster in a local database. And you don't have to create a Prestashop local database, you can only create the fields that you need to change.

 

Hope it helps!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...