Embedded Search / Enterprise Search
Given two names due to licensing reasons. Enterprise Search is related to standalone ‘Enterprise Search’, the term embedded search refers to the use of ‘enterprise search’ within a or several Business Suite Applications. So in terms of SRM we use embedded search USING enterprise search technology.
So embedded search reads the data from the TREX server, it is considered a faster option than direct database read when dealing with large amounts of document data.
How does it work?
A set of models are defined in the Enterprise Search Modelling Wizard to simulate the structure of the SRM Document
Available models are:
Central Contract Header
Central Contract Item
Purchase Order Header
Purchase Order Item
Shopping Cart Header
Shopping Cart Item
No support for Bidding or Invoicing in embedded search
Original Specifications called for various methods of updating/loading data to the enterprise search, the initial load was carried out via report ESH_ADM_INDEX_ALL_SC (where SC stands for search not shopping cart!) and the idea was for delta loads to be taken care of by Changepointer processing , Fast Push and Fast Delta Update.
Only the Changepointer processing was adopted due to performance concerns with the other two delta loading options. Changepointer processing allowed for the implementation of a scheduled job, expected to be run on a schedule of approx every 2 minutes, the report is ESH_IX_PROCESS_CHANGE_POINTERS and this can also be executed directly from the ESH Cockpit as of NW 7.02 (So not available in any of our SRM systems yet). The report checked to see if any documents were ready to be loaded to TREX and processed accordingly.
Handled by a Badi, BADI_ESH_IF_OBJECT_DATA interface IF_BADI_ESH_IF_OBJECT_DATA
Here there are two main methods
IF_BADI_ESH_IF_OBJECT_DATA~NEXT - Packagewise reading for initial load
IF_BADI_ESH_IF_OBJECT_DATA~GET_DATA - Delta Load for Delta Processing
The search itself is transparent for users, it is not apparent to which agent the search is transmitted, the results are the same, database search is default, if the ES flag is selected in BBP_BACKEND_DEST then embedded search is used:
It is possible to switch on (or off) embedded search for single users via a parameter in SU01
Param ID: /SAPSRM/ES_ACTIVE
Value = X (explicitly on)
Value = 'O‚ (explicitly off) )
Method DETERMINE_ACTIVE_SERVICE reads the user parameter:
* read the user toggle
GET PARAMETER ID '/SAPSRM/ES_ACTIVE' FIELD lv_es_active. "#EC NOTEXT
IF lv_es_active = abap_true.
gv_es_connected = abap_true.
ELSEIF lv_es_active = 'O'. "#EC NOTEXT
* ls_es_active = 'OFF'
gv_es_connected = abap_false. " switched off
* read the general activation flag
gv_es_connected = /sapsrm/cl_src_agent_cust=>get_cust_es_connected( ).
gv_conne_requested = abap_true.
ESH_ADM_INDEX_ALL_SC – reindex all data
(be carefull as the all data in ES is deleted and ES is unusable for a while, only use in agreement with the customer)
ESH_IX_PROCESS_CHANGE_POINTERS – Change pointer processing, plan job
ESH_OBJECTS_INDEX_TEST – test indexing in dummy process
(no F4 help – insert SW component (SRM_SERVER) and model name manually)
ESH_TEST_SEARCH – test search in ES manually
(very helpfull to test if search is working – for complete BO‘s or single indexes/tables)
TREX_ADMIN – admin tool by TREX team – indexes etc (you have to insert the RFC connection)
Z_CC_TEST_SEARCH_AGENT_CLIENT - Search for object types: