-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Documentation done, time to organise
- Loading branch information
Aaron Carlino
committed
Jun 15, 2020
1 parent
f4c5f1f
commit dfab239
Showing
3 changed files
with
54 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,50 @@ | ||
# Implementations | ||
|
||
This module is a set of abstractions for creating search-as-a-service integrations. This section | ||
of the documentation covers the details of each one. | ||
|
||
## Elastic AppSearch | ||
|
||
This module comes bundled with an implementation for [Elastic AppSearch](https://www.elastic.co/app-search/). While most of the details are abstracted away in the `AppSearchService` class, there are some key things to know about configuring AppSearch. | ||
|
||
### Activating AppSearch | ||
|
||
To start using AppSearch, simply define an environment variable containing your private API key | ||
and endpoint. | ||
|
||
``` | ||
APP_SEARCH_ENDPOINT="https://abc123.app-search.ap-southeast-2.aws.found.io" | ||
APP_SEARCH_API_KEY="private-abc123" | ||
``` | ||
|
||
### Configuring AppSearch | ||
|
||
The most notable configuration surface for AppSearch is the schema, which determines how data | ||
is stored in your AppSearch index (engine). There are four types of data in AppSearch: | ||
|
||
* Text (default) | ||
* Date | ||
* Number | ||
* Geolocation | ||
|
||
You can specify these data types in the `options` node of your fields. | ||
|
||
```yaml | ||
SilverStripe\SearchService\Service\IndexConfiguration: | ||
indexes: | ||
myindex: | ||
includeClasses: | ||
SilverStripe\CMS\Model\SiteTree: | ||
fields: | ||
title: | ||
property: Title | ||
options: | ||
type: text | ||
``` | ||
**Note**: Be careful about whimsically changing your schema. AppSearch may need to be fully | ||
reindexed if you change the data type of a field. | ||