Skip to content

Commit

Permalink
[Azure Cognitive Search] Various Swagger improvements (Azure#9301)
Browse files Browse the repository at this point in the history
* [Azure Cognitive Search] Add warning to Delete Index description

* [Azure Cognitive Search] Rename searchMode to SuggesterSearchMode

Trying to avoid ambiguity between generated model names in SDK code.

* [Azure Cognitive Search] Remove access-condition parameter group

The parameter group was for codegen purposes, but it turns out that clients
will use a different pattern for exposing ETag capabilities, so this is no
longer needed. However, we're keeping the If-Match and If-None-Match
parameters themselves for REST API documentation purposes.

Fixes Azure#9205

* [Azure Cognitive Search] Clarify docs for pattern analyzer & tokenizer

Fixes Azure#9145

* [Azure Cognitive Search] Document more enums

Fixes Azure#9146

* [Azure Cognitive Search] Make List Indexes "fake pageable"

This makes codegen easier for now, with the expectation that this API may
become pageable in the future.

Fixes Azure#9274

* [Azure Cognitive Search] Rename models per arch board feedback

Fixes Azure#9295

* [Azure Cognitive Search] Add names to dictionary

* [Azure Cognitive Search] Improve the description of analyzingInfixMatching

* [Azure Cognitive Search] Change prefix match example to pacify spell checker

Co-authored-by: Bruce Johnston <brjohnst@microsoft.com>
  • Loading branch information
2 people authored and 00Kai0 committed Oct 12, 2020
1 parent f793334 commit 7a582f8
Show file tree
Hide file tree
Showing 3 changed files with 1,494 additions and 140 deletions.
3 changes: 3 additions & 0 deletions custom-words.txt
Original file line number Diff line number Diff line change
Expand Up @@ -760,9 +760,11 @@ Kiswahili
Knowledgebase
knowledgebases
koelner
Kölner
koreacentral
koreasouth
Kpis
Kraaij
Ksettings
kstem
kube
Expand Down Expand Up @@ -1081,6 +1083,7 @@ pixelated
pkcs
playready
Plex
Pohlmann
policyassignments
policydefinitions
policyinsights
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,19 @@
],
"x-ms-enum": {
"name": "QueryType",
"modelAsString": false
"modelAsString": false,
"values": [
{
"value": "simple",
"name": "Simple",
"description": "Uses the simple query syntax for searches. Search text is interpreted using a simple query language that allows for symbols such as +, * and \"\". Queries are evaluated across all searchable fields by default, unless the searchFields parameter is specified."
},
{
"value": "full",
"name": "Full",
"description": "Uses the full Lucene query syntax for searches. Search text is interpreted using the Lucene query language which allows field-specific and weighted searches, as well as other advanced features."
}
]
},
"x-nullable": false,
"description": "A value that specifies the syntax of the search query. The default is 'simple'. Use 'full' if your query uses the Lucene query syntax.",
Expand Down Expand Up @@ -243,7 +255,19 @@
],
"x-ms-enum": {
"name": "SearchMode",
"modelAsString": false
"modelAsString": false,
"values": [
{
"value": "any",
"name": "Any",
"description": "Any of the search terms must be matched in order to count the document as a match."
},
{
"value": "all",
"name": "All",
"description": "All of the search terms must be matched in order to count the document as a match."
}
]
},
"x-nullable": false,
"description": "A value that specifies whether any or all of the search terms must be matched in order to count the document as a match.",
Expand Down Expand Up @@ -716,7 +740,24 @@
],
"x-ms-enum": {
"name": "AutocompleteMode",
"modelAsString": false
"modelAsString": false,
"values": [
{
"value": "oneTerm",
"name": "OneTerm",
"description": "Only one term is suggested. If the query has two terms, only the last term is completed. For example, if the input is 'washington medic', the suggested terms could include 'medicaid', 'medicare', and 'medicine'."
},
{
"value": "twoTerms",
"name": "TwoTerms",
"description": "Matching two-term phrases in the index will be suggested. For example, if the input is 'medic', the suggested terms could include 'medicare coverage' and 'medical assistant'."
},
{
"value": "oneTermWithContext",
"name": "OneTermWithContext",
"description": "Completes the last term in a query with two or more terms, where the last two terms are a phrase that exists in the index. For example, if the input is 'washington medic', the suggested terms could include 'washington medicaid' and 'washington medical'."
}
]
},
"description": "Specifies the mode for Autocomplete. The default is 'oneTerm'. Use 'twoTerms' to get shingles and 'oneTermWithContext' to use the current context while producing auto-completed terms.",
"x-ms-parameter-grouping": {
Expand Down Expand Up @@ -1024,7 +1065,29 @@
],
"x-ms-enum": {
"name": "IndexActionType",
"modelAsString": false
"modelAsString": false,
"values": [
{
"value": "upload",
"name": "Upload",
"description": "Inserts the document into the index if it is new and updates it if it exists. All fields are replaced in the update case."
},
{
"value": "merge",
"name": "Merge",
"description": "Merges the specified field values with an existing document. If the document does not exist, the merge will fail. Any field you specify in a merge will replace the existing field in the document. This also applies to collections of primitive and complex types."
},
{
"value": "mergeOrUpload",
"name": "MergeOrUpload",
"description": "Behaves like merge if a document with the given key already exists in the index. If the document does not exist, it behaves like upload with a new document."
},
{
"value": "delete",
"name": "Delete",
"description": "Removes the specified document from the index. Any field you specify in a delete operation other than the key field will be ignored. If you want to remove an individual field from a document, use merge instead and set the field explicitly to null."
}
]
},
"x-ms-client-name": "ActionType",
"x-nullable": false,
Expand Down Expand Up @@ -1093,7 +1156,19 @@
],
"x-ms-enum": {
"name": "SearchMode",
"modelAsString": false
"modelAsString": false,
"values": [
{
"value": "any",
"name": "Any",
"description": "Any of the search terms must be matched in order to count the document as a match."
},
{
"value": "all",
"name": "All",
"description": "All of the search terms must be matched in order to count the document as a match."
}
]
},
"description": "Specifies whether any or all of the search terms must be matched in order to count the document as a match."
},
Expand All @@ -1105,7 +1180,19 @@
],
"x-ms-enum": {
"name": "QueryType",
"modelAsString": false
"modelAsString": false,
"values": [
{
"value": "simple",
"name": "Simple",
"description": "Uses the simple query syntax for searches. Search text is interpreted using a simple query language that allows for symbols such as +, * and \"\". Queries are evaluated across all searchable fields by default, unless the searchFields parameter is specified."
},
{
"value": "full",
"name": "Full",
"description": "Uses the full Lucene query syntax for searches. Search text is interpreted using the Lucene query language which allows field-specific and weighted searches, as well as other advanced features."
}
]
},
"description": "Specifies the syntax of the search query. The default is 'simple'. Use 'full' if your query uses the Lucene query syntax."
},
Expand All @@ -1118,7 +1205,24 @@
],
"x-ms-enum": {
"name": "AutocompleteMode",
"modelAsString": false
"modelAsString": false,
"values": [
{
"value": "oneTerm",
"name": "OneTerm",
"description": "Only one term is suggested. If the query has two terms, only the last term is completed. For example, if the input is 'washington medic', the suggested terms could include 'medicaid', 'medicare', and 'medicine'."
},
{
"value": "twoTerms",
"name": "TwoTerms",
"description": "Matching two-term phrases in the index will be suggested. For example, if the input is 'medic', the suggested terms could include 'medicare coverage' and 'medical assistant'."
},
{
"value": "oneTermWithContext",
"name": "OneTermWithContext",
"description": "Completes the last term in a query with two or more terms, where the last two terms are a phrase that exists in the index. For example, if the input is 'washington medic', the suggested terms could include 'washington medicaid' and 'washington medical'."
}
]
},
"description": "Specifies the mode for Autocomplete. The default is 'oneTerm'. Use 'twoTerms' to get shingles and 'oneTermWithContext' to use the current context in producing autocomplete terms."
},
Expand Down
Loading

0 comments on commit 7a582f8

Please sign in to comment.