ePages 6.14.0 - DE_EPAGES/RemoteSearch/API/Object/ProductBatchProcessHandler.pm

Package DE_EPAGES::RemoteSearch::API::Object::ProductBatchProcessHandler

Handles batch-updates of products to pass them to the remote search. Implements Interface DE_EPAGES::Trigger::API::Object::BatchProcessHandler
Uses DE_EPAGES::RemoteSearch::API::Object::SearchIndex

Base
DE_EPAGES::Trigger::API::Object::BatchProcessHandler

Functions

new
processItemList

new

Pass optional parameter 'BatchSize' to define the number of items queued before processItemList() is called automatically. Call processItemList() manualy before discarding the Handler to ensure that all items are processed.

see DE_EPAGES::Trigger::API::Object::BatchProcessHandler for inherited methods

Syntax
my $Handler = DE_EPAGES::RemoteSearch::API::Object::ProductBatchProcessHandler->new( {BatchSize => 50} );
my $Handler = DE_EPAGES::RemoteSearch::API::Object::ProductBatchProcessHandler->new();
Input
$hOptions (ref.hash)
  • BatchSize - this limit trigger automated processing while adding Products(optional) - integer > 1
  • RemoteSearch - Custom RemoteSearch adapter for testing/debugging
Return
$Object (DE_EPAGES::RemoteSearch::API::Object::ProductBatchProcessHandler)
new batch process handler

processItemList

Stored products are passed to SearchIndex object and flushed. On first call of this method the search initialized with parameters from first Object in item list.

see DE_EPAGES::RemoteSearch::API::Object::SearchIndex.

Syntax
$Handler->processItemList();