function apachesolr_document_id in Apache Solr Search 8
Same name and namespace in other branches
- 5.2 apachesolr.module \apachesolr_document_id()
- 6.3 apachesolr.module \apachesolr_document_id()
- 6 apachesolr.module \apachesolr_document_id()
- 6.2 apachesolr.module \apachesolr_document_id()
- 7 apachesolr.module \apachesolr_document_id()
Generate a unique ID for an entity being indexed.
Parameters
$id: An id number (or string) unique to this site, such as a node ID.
$entity: A string like 'node', 'file', 'user', or some other Drupal object type.
Return value
A string combining the parameters with the site hash.
7 calls to apachesolr_document_id()
- apachesolr_index_delete_entity_from_index in ./
apachesolr.index.inc - Delete an entity from the index.
- apachesolr_index_nodeapi_mass_delete in ./
apachesolr.index.inc - Mass delete nodes from the solr indexer tables.
- apachesolr_index_nodeapi_mass_update in ./
apachesolr.index.inc - Mass Update nodes from the solr indexer table
- apachesolr_search_block_view in ./
apachesolr_search.module - Implements hook_block_view().
- DrupalApacheSolrNodeAccess::testIndexing in apachesolr_access/
tests/ apachesolr_access.test - Tests indexing and check if it adds the correct grants for those specific users
File
- ./
apachesolr.module, line 598 - Integration with the Apache Solr search application.
Code
function apachesolr_document_id($id, $entity_type = 'node') {
return apachesolr_site_hash() . "/{$entity_type}/" . $id;
}