diff --git a/sdk/search/ci.yml b/sdk/search/ci.yml index fae333597373..96466526e9a2 100644 --- a/sdk/search/ci.yml +++ b/sdk/search/ci.yml @@ -23,7 +23,8 @@ pr: extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: - ServiceDirectory: search + ServiceDirectory: search + TestProxy: true Artifacts: - name: azure-search-documents safeName: azuresearchdocuments diff --git a/sdk/search/search-documents/karma.conf.js b/sdk/search/search-documents/karma.conf.js index 554afd8cac83..e2d80a1d94dc 100644 --- a/sdk/search/search-documents/karma.conf.js +++ b/sdk/search/search-documents/karma.conf.js @@ -1,12 +1,10 @@ // https://github.com/karma-runner/karma-chrome-launcher process.env.CHROME_BIN = require("puppeteer").executablePath(); require("dotenv").config(); -const { - jsonRecordingFilterFunction, - isPlaybackMode, - isSoftRecordMode, - isRecordMode, -} = require("@azure-tools/test-recorder"); +const { relativeRecordingsPath } = require("@azure-tools/test-recorder"); + +process.env.RECORDINGS_RELATIVE_PATH = relativeRecordingsPath(); + module.exports = function (config) { config.set({ // base path that will be used to resolve all patterns (eg. files, exclude) @@ -27,15 +25,13 @@ module.exports = function (config) { "karma-coverage", "karma-sourcemap-loader", "karma-junit-reporter", - "karma-json-to-file-reporter", - "karma-json-preprocessor", ], // list of files / patterns to load in the browser files: [ "dist-test/index.browser.js", { pattern: "dist-test/index.browser.js.map", type: "html", included: false, served: true }, - ].concat(isPlaybackMode() || isSoftRecordMode() ? ["recordings/browsers/**/*.json"] : []), + ], // list of files / patterns to exclude exclude: [], @@ -44,7 +40,6 @@ module.exports = function (config) { // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor preprocessors: { "**/*.js": ["sourcemap", "env"], - "recordings/browsers/**/*.json": ["json"], // IMPORTANT: COMMENT following line if you want to debug in your browsers!! // Preprocess source file to calculate code coverage, however this will make source file unreadable "dist-test/index.js": ["coverage"], @@ -53,12 +48,18 @@ module.exports = function (config) { // inject following environment values into browser testing with window.__env__ // environment values MUST be exported or set with same console running "karma start" // https://www.npmjs.com/package/karma-env-preprocessor - envPreprocessor: ["TEST_MODE", "ENDPOINT", "SEARCH_API_ADMIN_KEY", "SEARCH_API_ADMIN_KEY_ALT"], + envPreprocessor: [ + "TEST_MODE", + "ENDPOINT", + "SEARCH_API_ADMIN_KEY", + "SEARCH_API_ADMIN_KEY_ALT", + "RECORDINGS_RELATIVE_PATH", + ], // test results reporter to use // possible values: 'dots', 'progress' // available reporters: https://npmjs.org/browse/keyword/karma-reporter - reporters: ["mocha", "coverage", "junit", "json-to-file"], + reporters: ["mocha", "coverage", "junit"], coverageReporter: { // specify a common output directory @@ -81,11 +82,6 @@ module.exports = function (config) { properties: {}, // key value pair of properties to add to the section of the report }, - jsonToFileReporter: { - filter: jsonRecordingFilterFunction, - outputPath: ".", - }, - // web server port port: 9876, @@ -116,10 +112,6 @@ module.exports = function (config) { browserDisconnectTimeout: 10000, browserDisconnectTolerance: 3, - browserConsoleLogOptions: { - terminal: !isRecordMode(), - }, - client: { mocha: { // change Karma's debug.html to the mocha web reporter diff --git a/sdk/search/search-documents/package.json b/sdk/search/search-documents/package.json index 10aa7f5bee63..05aa48aee32c 100644 --- a/sdk/search/search-documents/package.json +++ b/sdk/search/search-documents/package.json @@ -18,8 +18,8 @@ "clean": "rimraf dist dist-* temp types *.tgz *.log", "extract-api": "tsc -p . && api-extractor run --local", "format": "prettier --write --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.ts\" \"test/**/*.ts\" \"samples-dev/**/*.ts\" \"*.{js,json}\"", - "integration-test:browser": "karma start --single-run", - "integration-test:node": "nyc mocha -r esm --require source-map-support/register --reporter ../../../common/tools/mocha-multi-reporter.js --timeout 5000000 --full-trace dist-esm/**/*.spec.js --harmony", + "integration-test:browser": "dev-tool run test:browser", + "integration-test:node": "dev-tool run test:node-js-input -- --timeout 5000000 'dist-esm/test/**/*.spec.js'", "integration-test": "npm run integration-test:node && npm run integration-test:browser", "lint:fix": "eslint package.json api-extractor.json src test --ext .ts --fix --fix-type [problem,suggestion]", "lint": "eslint package.json api-extractor.json src test --ext .ts", @@ -27,8 +27,8 @@ "test:browser": "npm run build:test && npm run unit-test:browser", "test:node": "npm run build:test && npm run unit-test:node", "test": "npm run build:test && npm run unit-test", - "unit-test:browser": "karma start --single-run", - "unit-test:node": "mocha -r esm --require ts-node/register --reporter ../../../common/tools/mocha-multi-reporter.js --timeout 1200000 --full-trace \"test/{,!(browser)/**/}*.spec.ts\"", + "unit-test:browser": "dev-tool run test:browser", + "unit-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 \"test/**/*.spec.ts\" \"test/**/**/*.spec.ts\"", "unit-test": "npm run unit-test:node && npm run unit-test:browser" }, "files": [ @@ -87,7 +87,7 @@ "@azure/test-utils": "^1.0.0", "@azure/dev-tool": "^1.0.0", "@azure/eslint-plugin-azure-sdk": "^3.0.0", - "@azure-tools/test-recorder": "^1.0.0", + "@azure-tools/test-recorder": "^2.0.0", "@microsoft/api-extractor": "^7.18.11", "@types/chai": "^4.1.6", "@types/mocha": "^7.0.2", diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_the_correct_autocomplete_result.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_the_correct_autocomplete_result.js deleted file mode 100644 index ae43c135c4f1..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_the_correct_autocomplete_result.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "e6e51af42f80c313fa0afd316079a755"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.post.autocomplete`, {"search":"sec","suggesterName":"sg"}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffc519bbf6b3f7af451934febbcfd68f4d12f5ae7f5f5cb72ddbc09bef825dfff25ff0f9aa508c636000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '18af2b56-b25e-4e9e-bd8f-acd4061f6f00', - 'elapsed-time', - '19', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:38:38 GMT', - 'Content-Length', - '164' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_the_correct_autocomplete_result.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_the_correct_autocomplete_result.json new file mode 100644 index 000000000000..482adac3b096 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_the_correct_autocomplete_result.json @@ -0,0 +1,1230 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "cbafb213-f730-4d51-b45e-f9ae49250436" + }, + "RequestBody": { + "name": "hotel-live-test-1058842", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:56:41 GMT", + "elapsed-time": "656", + "ETag": "W/\u00220x8D9E74F4BE15E8F\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1058842\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "cbafb213-f730-4d51-b45e-f9ae49250436", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F4BE15E8F\u0022", + "name": "hotel-live-test-1058842", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1058842\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "2d8582eb-c41b-4896-b991-5d5dff3d7d5d" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:56:44 GMT", + "elapsed-time": "154", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "2d8582eb-c41b-4896-b991-5d5dff3d7d5d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1058842\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "aa2cd70b-3f69-44aa-b321-8f910a218911" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:56:44 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "aa2cd70b-3f69-44aa-b321-8f910a218911", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1058842\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "37155002-8a74-484a-bbaf-41cc6b9967d1" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:56:49 GMT", + "elapsed-time": "12", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "37155002-8a74-484a-bbaf-41cc6b9967d1", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1058842\u0027)/docs/search.post.autocomplete?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "37", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ca3f3b81-ad09-4f4a-9357-37a5b6064887" + }, + "RequestBody": { + "search": "sec", + "suggesterName": "sg" + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "54", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:56:53 GMT", + "elapsed-time": "99", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ca3f3b81-ad09-4f4a-9357-37a5b6064887", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "text": "secret", + "queryPlusText": "secret" + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1058842\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c7892482-18b3-45a9-b002-bfe4ee4ab5e1" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:56:53 GMT", + "elapsed-time": "188", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "c7892482-18b3-45a9-b002-bfe4ee4ab5e1", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1058842" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_zero_results_for_invalid_query.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_zero_results_for_invalid_query.js deleted file mode 100644 index 6a56fb015588..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_zero_results_for_invalid_query.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "24d5222a36c4b91ba2f86374fb2fb30a"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.post.autocomplete`, {"search":"garbxyz","suggesterName":"sg"}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bdefff92ff0742ea40440c000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '89237a00-faa9-4bfe-b35f-be0c4773b63c', - 'elapsed-time', - '18', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:38:56 GMT', - 'Content-Length', - '133' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_zero_results_for_invalid_query.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_zero_results_for_invalid_query.json new file mode 100644 index 000000000000..2c415e4f5644 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_autocomplete_returns_zero_results_for_invalid_query.json @@ -0,0 +1,1225 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e41fbc3d-427f-4fe0-8054-5861f5b2b375" + }, + "RequestBody": { + "name": "hotel-live-test-1044190", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:56:58 GMT", + "elapsed-time": "575", + "ETag": "W/\u00220x8D9E74F561C6523\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1044190\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e41fbc3d-427f-4fe0-8054-5861f5b2b375", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F561C6523\u0022", + "name": "hotel-live-test-1044190", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1044190\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "2eed93cd-a2a2-4029-8baf-8ff7b50558b4" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:57:02 GMT", + "elapsed-time": "175", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "2eed93cd-a2a2-4029-8baf-8ff7b50558b4", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1044190\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "70432c04-22cf-471e-b8d4-2c4d14db33ce" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:02 GMT", + "elapsed-time": "8", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "70432c04-22cf-471e-b8d4-2c4d14db33ce", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1044190\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e5ecf532-b523-4b42-a6f5-a22be3ad865b" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:06 GMT", + "elapsed-time": "9", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e5ecf532-b523-4b42-a6f5-a22be3ad865b", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1044190\u0027)/docs/search.post.autocomplete?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "41", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e83d935b-b445-4292-8e3f-2b885a1af526" + }, + "RequestBody": { + "search": "garbxyz", + "suggesterName": "sg" + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "12", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:57:10 GMT", + "elapsed-time": "12", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e83d935b-b445-4292-8e3f-2b885a1af526", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1044190\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "366a273e-bbef-4458-8aa8-279208f6c52f" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:57:10 GMT", + "elapsed-time": "171", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "366a273e-bbef-4458-8aa8-279208f6c52f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1044190" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_count_returns_the_correct_document_count.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_count_returns_the_correct_document_count.js deleted file mode 100644 index d550d356c45e..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_count_returns_the_correct_document_count.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "c17602420e23796fc9bb03ed67cbb7a3"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71fdcddf97f00bbe0538805000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '7bd013e4-9a35-4913-91c6-b04e08fde020', - 'elapsed-time', - '8', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:38:21 GMT', - 'Content-Length', - '127' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_count_returns_the_correct_document_count.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_count_returns_the_correct_document_count.json new file mode 100644 index 000000000000..5ea8f8d06318 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_count_returns_the_correct_document_count.json @@ -0,0 +1,1188 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d707fcfa-55b8-4d1b-bb99-b4d4c2c1d89a" + }, + "RequestBody": { + "name": "hotel-live-test-1002385", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:56:26 GMT", + "elapsed-time": "1742", + "ETag": "W/\u00220x8D9E74F43B16AD5\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1002385\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d707fcfa-55b8-4d1b-bb99-b4d4c2c1d89a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F43B16AD5\u0022", + "name": "hotel-live-test-1002385", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1002385\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f8ef4007-cf95-46a9-bd12-2e2bc0ad850d" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:56:32 GMT", + "elapsed-time": "468", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "f8ef4007-cf95-46a9-bd12-2e2bc0ad850d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1002385\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "2e82302b-257a-4f0e-ba9c-2582a1d54384" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:56:32 GMT", + "elapsed-time": "32", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "2e82302b-257a-4f0e-ba9c-2582a1d54384", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1002385\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4fc97fe4-2935-4df4-8b2e-3265d7601893" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:56:36 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "4fc97fe4-2935-4df4-8b2e-3265d7601893", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1002385\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "7827b97c-38f5-441f-a1c6-8bfaac1e94af" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:56:36 GMT", + "elapsed-time": "197", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "7827b97c-38f5-441f-a1c6-8bfaac1e94af", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1002385" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_documents.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_documents.js deleted file mode 100644 index 38b9871be533..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_documents.js +++ /dev/null @@ -1,101 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "e6a92c9ca9a4dc9496a78a94e90281d6"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('8')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3e3af868247fbdc816f9478f96ebb21c7d34cb9b695dacdaa25a52936f674dda548b3cadab6c962eaba2c9d36c394b8b265de6efdab4add2769ea797797d9daeaab298e669d36678799c3ec9da795d558b269dd3bb8baacecb745a51d36279d18ca96fafab6735757656a6d76996ced6e9a45e176d3acbd332a39ed76d9ee66d4a5db7f4c7659efebeeb9d9d7c279de2e7f97e8b1ff9436daedde32f41689c3ecf69105959d20ffa749215cb34bbcc8a7c892e9ab4ce2f1942d6e60bfa8c1b11b6055e009a53fae2a2aaaf0d85daeca2f9e8d1f7be3ffa6895d56f693067cb69b99ee5445269d02c2a7c7c5c96d595fbb4cc9af655beac2e19bfa704d47c53d327cb0bf357595187d4c2fc9dcd6675de508ff2275314ddff92ff07355dccd3cb010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'f89960d2-2ba8-413a-8c8d-def2e9f8c362', - 'elapsed-time', - '9', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:40:57 GMT', - 'Content-Length', - '411' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"delete","hotelId":"8","hotelName":null,"description":"Has some road noise and is next to the very police station. Bathrooms had morel coverings.","descriptionFr":"Il y a du bruit de la route et se trouve à côté de la station de police. Les salles de bain avaient des revêtements de morilles.","category":null,"tags":[],"parkingIncluded":null,"smokingAllowed":null,"lastRenovationDate":null,"rating":null,"location":null,"address":null,"rooms":[]}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471f1d7c34faa869b376dd7cf4a8add7f9e8a3bcaeabfa8bbc69b20b6ab85c97a5697152cde893bd9d9d5ff2fd5ff2ff0038a311724a000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'b5eacc2d-62db-409d-bc63-15e1b0cb6a01', - 'elapsed-time', - '29', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:40:57 GMT', - 'Content-Length', - '184' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71f7cf8ff00fca50b5a04000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'e5c8e072-740d-4f90-a51e-11f9c235d2e8', - 'elapsed-time', - '7', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:41:01 GMT', - 'Content-Length', - '126' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_documents.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_documents.json new file mode 100644 index 000000000000..d8a1cc22b9a6 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_documents.json @@ -0,0 +1,1322 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d549d2f4-7be8-4ce2-b7eb-5b77b237d520" + }, + "RequestBody": { + "name": "hotel-live-test-1032671", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:58:58 GMT", + "elapsed-time": "608", + "ETag": "W/\u00220x8D9E74F9DD3F708\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d549d2f4-7be8-4ce2-b7eb-5b77b237d520", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F9DD3F708\u0022", + "name": "hotel-live-test-1032671", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "43e66284-3694-4bc9-9719-061833f2fd29" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:02 GMT", + "elapsed-time": "135", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "43e66284-3694-4bc9-9719-061833f2fd29", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "1564e166-89b4-4ed2-9bca-5ad6bbdbb305" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:02 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "1564e166-89b4-4ed2-9bca-5ad6bbdbb305", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3779c6e2-035e-429c-8125-76beb583329d" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:06 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "3779c6e2-035e-429c-8125-76beb583329d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)/docs(\u00278\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "464d8721-66c9-4246-bd16-6c5a0dc5d06e" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "459", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:10 GMT", + "elapsed-time": "13", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "464d8721-66c9-4246-bd16-6c5a0dc5d06e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "8", + "hotelName": null, + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles.", + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "481", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0df3314e-a073-4d37-aba9-475971486a35" + }, + "RequestBody": { + "value": [ + { + "@search.action": "delete", + "hotelId": "8", + "hotelName": null, + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles.", + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "74", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:10 GMT", + "elapsed-time": "27", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0df3314e-a073-4d37-aba9-475971486a35", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 200 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "42651fdf-2c78-4a1d-a926-ab7902e04898" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:14 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "42651fdf-2c78-4a1d-a926-ab7902e04898", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF9" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1032671\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ce06faeb-ce8d-4687-bfc7-9169196e6449" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:59:14 GMT", + "elapsed-time": "246", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "ce06faeb-ce8d-4687-bfc7-9169196e6449", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1032671" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_keykeynames.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_keykeynames.js deleted file mode 100644 index 82e493f4724b..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_keykeynames.js +++ /dev/null @@ -1,69 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "b2a93b2af0de470c1b36ed1f0168d72d"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"delete","hotelId":"9"},{"@search.action":"delete","hotelId":"10"}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471f3dfc68f451d366edbaf9e8515baff3d147795d57f51779d36417d470b92e4bd3e2a49ad1277b3b3bbf64645edfddf95aef7fff97fc3fafab5d608a000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '15503ff6-b214-4a53-847d-66dbd41c5610', - 'elapsed-time', - '36', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:41:18 GMT', - 'Content-Length', - '191' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71f3cf87f006a950c2d04000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '8b17f2ea-614f-4354-b6c8-f63ee466c36d', - 'elapsed-time', - '5', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:41:22 GMT', - 'Content-Length', - '126' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_keykeynames.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_keykeynames.json new file mode 100644 index 000000000000..12cb43679146 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_deletedocuments_delete_a_document_by_keykeynames.json @@ -0,0 +1,1276 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f20ce90e-c812-4d78-984f-3b39401f1f38" + }, + "RequestBody": { + "name": "hotel-live-test-1075001", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:59:19 GMT", + "elapsed-time": "637", + "ETag": "W/\u00220x8D9E74FAA71C093\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1075001\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "f20ce90e-c812-4d78-984f-3b39401f1f38", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74FAA71C093\u0022", + "name": "hotel-live-test-1075001", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1075001\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "785a8bda-2b74-42df-a238-3d9260ee0d04" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:23 GMT", + "elapsed-time": "154", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "785a8bda-2b74-42df-a238-3d9260ee0d04", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1075001\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "569d6d7a-2b4c-4c17-b153-cbfdb4c61a42" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:23 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "569d6d7a-2b4c-4c17-b153-cbfdb4c61a42", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1075001\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "73236604-be5a-4d98-a181-a0cccdf9ccef" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:27 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "73236604-be5a-4d98-a181-a0cccdf9ccef", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1075001\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "96", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f650a18b-4242-4c2f-8130-10cec1224df9" + }, + "RequestBody": { + "value": [ + { + "@search.action": "delete", + "hotelId": "9" + }, + { + "@search.action": "delete", + "hotelId": "10" + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "138", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:31 GMT", + "elapsed-time": "38", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "f650a18b-4242-4c2f-8130-10cec1224df9", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 200 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 200 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1075001\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "25467adc-d98a-4faf-8598-ea534f588629" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:36 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "25467adc-d98a-4faf-8598-ea534f588629", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF8" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1075001\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "efe3a0ed-4487-4679-b362-c71046e93e94" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:59:36 GMT", + "elapsed-time": "213", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "efe3a0ed-4487-4679-b362-c71046e93e94", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1075001" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_returns_the_correct_document_result.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_returns_the_correct_document_result.js deleted file mode 100644 index 3164aec0237f..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_returns_the_correct_document_result.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "0d0464f02ba0f535ca2bbc2510a50ee2"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('8')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3e3af868247fbdc816f9478f96ebb21c7d34cb9b695dacdaa25a52936f674dda548b3cadab6c962eaba2c9d36c394b8b265de6efdab4add2769ea797797d9daeaab298e669d36678799c3ec9da795d558b269dd3bb8baacecb745a51d36279d18ca96fafab6735757656a6d76996ced6e9a45e176d3acbd332a39ed76d9ee66d4a5db7f4c7659efebeeb9d9d7c279de2e7f97e8b1ff9436daedde32f41689c3ecf69105959d20ffa749215cb34bbcc8a7c892e9ab4ce2f1942d6e60bfa8c1b11b6055e009a53fae2a2aaaf0d85daeca2f9e8d1f7be3ffa6895d56f693067cb69b99ee5445269d02c2a7c7c5c96d595fbb4cc9af655beac2e19bfa704d47c53d327cb0bf357595187d4c2fc9dcd6675de508ff2275314ddff92ff07355dccd3cb010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '299d7826-e4d5-404e-8861-b684065dbc1d', - 'elapsed-time', - '11', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:40:22 GMT', - 'Content-Length', - '411' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_returns_the_correct_document_result.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_returns_the_correct_document_result.json new file mode 100644 index 000000000000..632223a277ee --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_returns_the_correct_document_result.json @@ -0,0 +1,1232 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "188f05d8-d3eb-4b3c-9649-d3e6dfe07e58" + }, + "RequestBody": { + "name": "hotel-live-test-1006866", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:58:24 GMT", + "elapsed-time": "624", + "ETag": "W/\u00220x8D9E74F893336AE\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1006866\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "188f05d8-d3eb-4b3c-9649-d3e6dfe07e58", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F893336AE\u0022", + "name": "hotel-live-test-1006866", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1006866\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e92b2f67-c13d-48f1-b1c7-687c446aba6a" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:58:28 GMT", + "elapsed-time": "168", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e92b2f67-c13d-48f1-b1c7-687c446aba6a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1006866\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f144e76e-d99a-4f86-8ccd-2f5790cf1a0d" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:58:28 GMT", + "elapsed-time": "7", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "f144e76e-d99a-4f86-8ccd-2f5790cf1a0d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1006866\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8b9806a2-c937-402a-bf75-f4abf7357381" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:58:32 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8b9806a2-c937-402a-bf75-f4abf7357381", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1006866\u0027)/docs(\u00278\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "bdda7a79-9320-41e4-a385-fc3536e31dfa" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "459", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:58:36 GMT", + "elapsed-time": "41", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "bdda7a79-9320-41e4-a385-fc3536e31dfa", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "8", + "hotelName": null, + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles.", + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1006866\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "a0d436b1-8322-4f4c-90b2-439a31bb1749" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:58:36 GMT", + "elapsed-time": "175", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "a0d436b1-8322-4f4c-90b2-439a31bb1749", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1006866" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_throws_error_for_invalid_getdocument_value.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_throws_error_for_invalid_getdocument_value.js deleted file mode 100644 index 949453fa71c6..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_throws_error_for_invalid_getdocument_value.js +++ /dev/null @@ -1,27 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "304fc79e14e53d4f8d6e5ff9bf9d1357"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('garbxyz')`) - .query(true) - .reply(404, "", [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Expires', - '-1', - 'request-id', - '210e152b-dd11-479a-b643-e9f31ad1f6dc', - 'elapsed-time', - '6', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:40:39 GMT', - 'Content-Length', - '0' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_throws_error_for_invalid_getdocument_value.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_throws_error_for_invalid_getdocument_value.json new file mode 100644 index 000000000000..a5a86992f454 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_getdocument_throws_error_for_invalid_getdocument_value.json @@ -0,0 +1,1213 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "fafc20c6-d0f4-4006-a0d5-ed63666a04e3" + }, + "RequestBody": { + "name": "hotel-live-test-1017523", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:58:41 GMT", + "elapsed-time": "989", + "ETag": "W/\u00220x8D9E74F93A04246\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1017523\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "fafc20c6-d0f4-4006-a0d5-ed63666a04e3", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F93A04246\u0022", + "name": "hotel-live-test-1017523", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1017523\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "889647ad-fad0-4ee1-ad15-278b68bfc603" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:58:45 GMT", + "elapsed-time": "243", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "889647ad-fad0-4ee1-ad15-278b68bfc603", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1017523\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0b49ffb3-39f2-4d41-9548-a32a219f6f46" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:58:45 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0b49ffb3-39f2-4d41-9548-a32a219f6f46", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF5" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1017523\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8c53aefd-8343-4257-be38-ce3778867e27" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:58:49 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8c53aefd-8343-4257-be38-ce3778867e27", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1017523\u0027)/docs(\u0027garbxyz\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "bf2ded0e-d5f8-43b6-8744-7fd8c59450ac" + }, + "RequestBody": null, + "StatusCode": 404, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "0", + "Date": "Thu, 03 Feb 2022 19:58:53 GMT", + "elapsed-time": "14", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "bf2ded0e-d5f8-43b6-8744-7fd8c59450ac", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1017523\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "b80fb9f6-cb6c-474f-9264-9c1c2a124a12" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:58:53 GMT", + "elapsed-time": "166", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "b80fb9f6-cb6c-474f-9264-9c1c2a124a12", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1017523" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_deletes_existing_documents.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_deletes_existing_documents.js deleted file mode 100644 index 97c0d8c430c7..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_deletes_existing_documents.js +++ /dev/null @@ -1,69 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "38fbeabbfdc18faf4809698fb0e96a48"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"delete","hotelId":"9"},{"@search.action":"delete","hotelId":"10"}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471f3dfc68f451d366edbaf9e8515baff3d147795d57f51779d36417d470b92e4bd3e2a49ad1277b3b3bbf64645edfddf95aef7fff97fc3fafab5d608a000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'da9a60bd-1be3-4268-817a-fec3f3fe8fee', - 'elapsed-time', - '30', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:43:26 GMT', - 'Content-Length', - '191' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71f3cf87f006a950c2d04000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '3d07e702-1095-45bc-98bc-ce9a4874eac0', - 'elapsed-time', - '6', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:43:30 GMT', - 'Content-Length', - '126' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_deletes_existing_documents.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_deletes_existing_documents.json new file mode 100644 index 000000000000..e5c8a640093a --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_deletes_existing_documents.json @@ -0,0 +1,1276 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "1409e850-c853-4f94-a638-85b81b94b4bb" + }, + "RequestBody": { + "name": "hotel-live-test-1025954", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:01:26 GMT", + "elapsed-time": "690", + "ETag": "W/\u00220x8D9E74FF6A337DC\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1025954\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "1409e850-c853-4f94-a638-85b81b94b4bb", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74FF6A337DC\u0022", + "name": "hotel-live-test-1025954", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1025954\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "36e28078-a055-490d-816a-f787f2aed74e" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:01:31 GMT", + "elapsed-time": "146", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "36e28078-a055-490d-816a-f787f2aed74e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1025954\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c35a8a1b-bc54-4d58-8abd-60f332f34325" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:31 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "c35a8a1b-bc54-4d58-8abd-60f332f34325", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1025954\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "fa0da59e-0811-492c-9756-41fe465a9d13" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:35 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "fa0da59e-0811-492c-9756-41fe465a9d13", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1025954\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "96", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c4539d5e-c956-41ff-a434-f6b35c57f2db" + }, + "RequestBody": { + "value": [ + { + "@search.action": "delete", + "hotelId": "9" + }, + { + "@search.action": "delete", + "hotelId": "10" + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "138", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:01:39 GMT", + "elapsed-time": "30", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "c4539d5e-c956-41ff-a434-f6b35c57f2db", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 200 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 200 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1025954\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "cd4eae20-02c0-4278-9682-35a49342999f" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:43 GMT", + "elapsed-time": "8", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "cd4eae20-02c0-4278-9682-35a49342999f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF8" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1025954\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c836db95-685b-4939-8d3a-b989d13be95f" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:01:43 GMT", + "elapsed-time": "166", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "c836db95-685b-4939-8d3a-b989d13be95f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1025954" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_merges_an_existing_document.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_merges_an_existing_document.js deleted file mode 100644 index e0a895e4a988..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_merges_an_existing_document.js +++ /dev/null @@ -1,69 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "e6e20817a1db5a320d0e6f875a42c167"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"merge","hotelId":"8","description":"Modified Description"}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471f1d7c34faa869b376dd7cf4a8add7f9e8a3bcaeabfa8bbc69b20b6ab85c97a5697152cde893bd9d9d5ff2fd5ff2ff0038a311724a000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '1083a1c9-9f53-44a5-b8e0-7c4643e50647', - 'elapsed-time', - '36', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:43:47 GMT', - 'Content-Length', - '184' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('8')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3e3af868247fbdc816f9478f96ebb21c7d34cb9b695dacdaa25a52932faa59715ee4b3f4a9f771d0e8594dcdcecaf43acdd2d93a9dd4eba24d67795a66695daddb3ccddbb4c9d396feb8ccd3df77bdb393efa453fc3cdf6ff1237fa8cd9b360340fcb5aaca629a8fd3e77993365959d20ffa749215cb34bbcc8a7c892e9ab4ce2f1942d6e60bfa8c1b2daabac00b6342734a5f5c54f5b5195b9b5d341f3dfadef7471fadb2fa6db1bc385b4ecbf52c276248836651e1e3e3b2acaedca765d6b4aff26575c9f83d25a0e69b9a3e595e98bfca8a3aa416e6ef6c36abf3867a943febaa5ad01fdffbfe2ff97f0015ab79db85010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'd0d2ee22-c801-4e48-8b1a-1e4f88e72d86', - 'elapsed-time', - '10', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:43:51 GMT', - 'Content-Length', - '364' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_merges_an_existing_document.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_merges_an_existing_document.json new file mode 100644 index 000000000000..3af8d63d0a08 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_merges_an_existing_document.json @@ -0,0 +1,1281 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6ae79f14-bb56-48f8-86e8-7fd3967d076b" + }, + "RequestBody": { + "name": "hotel-live-test-1083418", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:01:48 GMT", + "elapsed-time": "626", + "ETag": "W/\u00220x8D9E75003339712\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1083418\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6ae79f14-bb56-48f8-86e8-7fd3967d076b", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E75003339712\u0022", + "name": "hotel-live-test-1083418", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1083418\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4807d97d-6099-4687-8bef-176e080e954d" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:01:52 GMT", + "elapsed-time": "200", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "4807d97d-6099-4687-8bef-176e080e954d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1083418\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "73a65f41-b3a6-41dd-ab2e-c71a3b201992" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:52 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "73a65f41-b3a6-41dd-ab2e-c71a3b201992", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1083418\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ad5162b2-602a-4b74-aa43-062a60f946d6" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:56 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ad5162b2-602a-4b74-aa43-062a60f946d6", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1083418\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "89", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "5725778e-8474-4fd0-a4b4-c36a7004c14d" + }, + "RequestBody": { + "value": [ + { + "@search.action": "merge", + "hotelId": "8", + "description": "Modified Description" + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "74", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:02:00 GMT", + "elapsed-time": "35", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "5725778e-8474-4fd0-a4b4-c36a7004c14d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 200 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1083418\u0027)/docs(\u00278\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "36e2d93c-f3bb-4ff2-8863-a3129891e92c" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "389", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:02:05 GMT", + "elapsed-time": "9", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "36e2d93c-f3bb-4ff2-8863-a3129891e92c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "8", + "hotelName": null, + "description": "Modified Description", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles.", + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1083418\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c2afed89-0ed8-46ab-9358-a28c4c36fddc" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:05 GMT", + "elapsed-time": "229", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "c2afed89-0ed8-46ab-9358-a28c4c36fddc", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1083418" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_mergeupload_documents.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_mergeupload_documents.js deleted file mode 100644 index eb90def00adc..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_mergeupload_documents.js +++ /dev/null @@ -1,101 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "e86b72b972365694cbfb2a0fdf479744"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"mergeOrUpload","hotelId":"8","description":"Modified Description"},{"@search.action":"mergeOrUpload","hotelId":"11","description":"New Hotel Description","lastRenovationDate":null}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471f1d7c34faa869b376dd7cf4a8add7f9e8a3bcaeabfa8bbc69b20b6ab85c97a5697152cde893bd9d9d5f3232afefee7e8df7777fc9f77fc9ff03dc317a548a000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '370065a6-f113-49de-97e5-040424793292', - 'elapsed-time', - '45', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:08 GMT', - 'Content-Length', - '194' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('8')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3e3af868247fbdc816f9478f96ebb21c7d34cb9b695dacdaa25a52932faa59715ee4b3f4a9f771d0e8594dcdcecaf43acdd2d93a9dd4eba24d67795a66695daddb3ccddbb4c9d396feb8ccd3df77bdb393efa453fc3cdf6ff1237fa8cd9b360340fcb5aaca629a8fd3e77993365959d20ffa749215cb34bbcc8a7c892e9ab4ce2f1942d6e60bfa8c1b2daabac00b6342734a5f5c54f5b5195b9b5d341f3dfadef7471fadb2fa6db1bc385b4ecbf52c276248836651e1e3e3b2acaedca765d6b4aff26575c9f83d25a0e69b9a3e595e98bfca8a3aa416e6ef6c36abf3867a943febaa5ad01fdffbfe2ff97f0015ab79db85010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'c3fdce1a-e509-436b-be1c-3ce023dfb230', - 'elapsed-time', - '9', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:12 GMT', - 'Content-Length', - '364' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71fdcddfd7f002dd054ff05000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '233109be-d3d2-48e0-aeac-38d000fdb903', - 'elapsed-time', - '4', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:12 GMT', - 'Content-Length', - '127' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_mergeupload_documents.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_mergeupload_documents.json new file mode 100644 index 000000000000..b59310428d26 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_mergeupload_documents.json @@ -0,0 +1,1323 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "2d9906aa-8da7-4ace-9cd3-6c008eba161f" + }, + "RequestBody": { + "name": "hotel-live-test-1026460", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:10 GMT", + "elapsed-time": "883", + "ETag": "W/\u00220x8D9E7500FFD9B7D\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "2d9906aa-8da7-4ace-9cd3-6c008eba161f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7500FFD9B7D\u0022", + "name": "hotel-live-test-1026460", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8744b361-32b3-436a-9755-0376bf847e4b" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:02:14 GMT", + "elapsed-time": "145", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8744b361-32b3-436a-9755-0376bf847e4b", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0bef8202-8306-4084-a8df-5490a037895e" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:02:14 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0bef8202-8306-4084-a8df-5490a037895e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0ee15712-5185-4944-b8e6-7c96f1567dd0" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:02:18 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0ee15712-5185-4944-b8e6-7c96f1567dd0", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "211", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "56b0e347-5cb9-437e-a11b-daaa5902a2e5" + }, + "RequestBody": { + "value": [ + { + "@search.action": "mergeOrUpload", + "hotelId": "8", + "description": "Modified Description" + }, + { + "@search.action": "mergeOrUpload", + "hotelId": "11", + "description": "New Hotel Description", + "lastRenovationDate": null + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "138", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:02:22 GMT", + "elapsed-time": "42", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "56b0e347-5cb9-437e-a11b-daaa5902a2e5", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 200 + }, + { + "key": "11", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)/docs(\u00278\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ee650bdf-2109-4805-ad8d-6f32838187ca" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "389", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:02:26 GMT", + "elapsed-time": "12", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ee650bdf-2109-4805-ad8d-6f32838187ca", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "8", + "hotelName": null, + "description": "Modified Description", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles.", + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6da4e085-ec1c-4cc0-9d00-d08a5f38c0da" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:02:26 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6da4e085-ec1c-4cc0-9d00-d08a5f38c0da", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF11" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1026460\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f9c965b9-5335-4454-b236-ee6e1b23600c" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:26 GMT", + "elapsed-time": "222", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "f9c965b9-5335-4454-b236-ee6e1b23600c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1026460" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_upload_a_new_document.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_upload_a_new_document.js deleted file mode 100644 index a6013232db04..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_upload_a_new_document.js +++ /dev/null @@ -1,69 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "14735b3a185e3a0e8563e031006f7043"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"upload","hotelId":"11","description":"New Hotel Description","lastRenovationDate":null}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471fedee7e34faa869b376dd7cf4a8add7f9e8a3bcaeabfa8bbc69b20b6ab95c97a5697152cde893bd9ddd5ff2fd5ff2ff00bc77d14f4b000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '4bc53e00-1a7b-42ba-b280-d651ff78422c', - 'elapsed-time', - '30', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:43:05 GMT', - 'Content-Length', - '185' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71fdcddfd7f002dd054ff05000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'b469722c-a008-496a-ab73-96badeaa2c19', - 'elapsed-time', - '7', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:43:09 GMT', - 'Content-Length', - '127' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_upload_a_new_document.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_upload_a_new_document.json new file mode 100644 index 000000000000..dccbd2a49ed8 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_indexdocuments_upload_a_new_document.json @@ -0,0 +1,1268 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3edf4796-363e-4ffb-aed8-86dca33763cb" + }, + "RequestBody": { + "name": "hotel-live-test-1045770", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:01:06 GMT", + "elapsed-time": "836", + "ETag": "W/\u00220x8D9E74FEA03E6E5\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1045770\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "3edf4796-363e-4ffb-aed8-86dca33763cb", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74FEA03E6E5\u0022", + "name": "hotel-live-test-1045770", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045770\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "29ebbeb4-cd54-40e8-8d5f-f630e1bfa685" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:01:09 GMT", + "elapsed-time": "179", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "29ebbeb4-cd54-40e8-8d5f-f630e1bfa685", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045770\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "adb9784b-b2cb-466a-bfcc-89c437a53feb" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:09 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "adb9784b-b2cb-466a-bfcc-89c437a53feb", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045770\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8d552110-8d64-4286-9b5f-461b2bea1f2c" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:14 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8d552110-8d64-4286-9b5f-461b2bea1f2c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045770\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "118", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ff8b9917-9d50-49b1-a21f-d00e1663a682" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "11", + "description": "New Hotel Description", + "lastRenovationDate": null + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "75", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:01:18 GMT", + "elapsed-time": "24", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ff8b9917-9d50-49b1-a21f-d00e1663a682", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "11", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045770\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "9fbf6402-7765-4bd3-8d2b-111d9db4e3f6" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:22 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "9fbf6402-7765-4bd3-8d2b-111d9db4e3f6", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF11" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045770\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "7c83aa21-2590-4d7a-be47-88a9f7c98ac9" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:01:22 GMT", + "elapsed-time": "173", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "7c83aa21-2590-4d7a-be47-88a9f7c98ac9", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1045770" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergedocuments_modify__merge_an_existing_document.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergedocuments_modify__merge_an_existing_document.js deleted file mode 100644 index 263e78986313..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergedocuments_modify__merge_an_existing_document.js +++ /dev/null @@ -1,101 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "26f342e9075a6b1ad1cb8966051ad336"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('6')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3efaf4a391fcf5225be41f3d5aaecb72f4d12c6fa675b16a8b6a494d5eafeb555d34c5f2a2bc4ef377ab7cd91497f938fda29ae565daac8b366fd2797699a7d932ada679b6dcbe2cf2ab3141f6003dab0df469d6e617557d6dfe6eb38be6a347dffbfee8a35556bfa56ece96d3723dcb093d69d02c2a7c7c5c96d595fbb4cc9af655beac2e33807f4a40cd37357db2bc307f951575482dccdfd96c56e70df5287fd655b5a03fbef7fd5ff2ff00978a208417010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '01b54adb-0f82-42bb-ac18-907e4523b830', - 'elapsed-time', - '17', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:42:22 GMT', - 'Content-Length', - '301' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"merge","hotelId":"6","hotelName":null,"description":"Modified Description","descriptionFr":null,"category":null,"tags":[],"parkingIncluded":null,"smokingAllowed":null,"lastRenovationDate":null,"rating":null,"location":null,"address":null,"rooms":[]}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471f7dfad1e8a3a6cdda75f3d1a3b65ee7a38ff2baaeea2ff2a6c92ea8e1725d96a6c54935a34ff676767ec9f77fc9ff037255c7d34a000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '63a0a7cf-3070-4926-87d8-fc956831fd2c', - 'elapsed-time', - '35', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:42:22 GMT', - 'Content-Length', - '184' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('6')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3efaf4a391fcf5225be41f3d5aaecb72f4d12c6fa675b16a8b6a494dbea866c57991cfd2a7dec741a367b579739ab5f945555f9bbfdbeca2f9e8d1f7be3ffa6895d56f8be5c5d9725aae6739752d0d9a45858f8fcbb2ba729f9659d3beca97d56506f04f09a8f9a6a64f9617e6afb2a20ea985f93b9bcdeabca11ee5cfbaaa16f4c7f7beff4bfe1fcc8e7273f3000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'e34f4883-94e3-4c96-b01a-6d2f8b66efa8', - 'elapsed-time', - '13', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:42:26 GMT', - 'Content-Length', - '264' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergedocuments_modify__merge_an_existing_document.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergedocuments_modify__merge_an_existing_document.json new file mode 100644 index 000000000000..8b888967df81 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergedocuments_modify__merge_an_existing_document.json @@ -0,0 +1,1336 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d50bdf3b-4c77-4bd9-a30e-c22eb5c3e4c8" + }, + "RequestBody": { + "name": "hotel-live-test-1057474", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:00:23 GMT", + "elapsed-time": "585", + "ETag": "W/\u00220x8D9E74FD0855F9D\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d50bdf3b-4c77-4bd9-a30e-c22eb5c3e4c8", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74FD0855F9D\u0022", + "name": "hotel-live-test-1057474", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "53345b61-0981-4f1a-bebc-7f1d5a608bd8" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:26 GMT", + "elapsed-time": "183", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "53345b61-0981-4f1a-bebc-7f1d5a608bd8", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "94ecd667-dc6c-425b-8ffc-f5b84d2ea868" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:00:26 GMT", + "elapsed-time": "7", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "94ecd667-dc6c-425b-8ffc-f5b84d2ea868", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "796c6e09-e649-4b62-b7df-faa74b621824" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:00:31 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "796c6e09-e649-4b62-b7df-faa74b621824", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)/docs(\u00276\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3f51f965-ad81-4b27-b203-5dcaeba6875f" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "279", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:34 GMT", + "elapsed-time": "13", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "3f51f965-ad81-4b27-b203-5dcaeba6875f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "6", + "hotelName": null, + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "descriptionFr": null, + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "280", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0b9677c7-2d1d-4190-8384-17e8ddecf7c8" + }, + "RequestBody": { + "value": [ + { + "@search.action": "merge", + "hotelId": "6", + "hotelName": null, + "description": "Modified Description", + "descriptionFr": null, + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "74", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:35 GMT", + "elapsed-time": "29", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0b9677c7-2d1d-4190-8384-17e8ddecf7c8", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 200 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)/docs(\u00276\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8b89f7e7-c1e4-4cc6-a3e7-df289f31fa1d" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "243", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:39 GMT", + "elapsed-time": "8", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8b89f7e7-c1e4-4cc6-a3e7-df289f31fa1d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "6", + "hotelName": null, + "description": "Modified Description", + "descriptionFr": null, + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1057474\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0fd5df0a-b6d3-4c74-883c-fdee77dfc387" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:00:39 GMT", + "elapsed-time": "185", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "0fd5df0a-b6d3-4c74-883c-fdee77dfc387", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1057474" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_merge_a_new_document.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_merge_a_new_document.js deleted file mode 100644 index d9b8aca95459..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_merge_a_new_document.js +++ /dev/null @@ -1,69 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "4aaf03617c2e3881d1eba05a82827be3"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"mergeOrUpload","hotelId":"11","description":"New Hotel Description","lastRenovationDate":null}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471fedee7e34faa869b376dd7cf4a8add7f9e8a3bcaeabfa8bbc69b20b6ab95c97a5697152cde893bd9ddd5ff2fd5ff2ff00bc77d14f4b000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '983cc1b8-6fcd-484f-ae55-56d269090e25', - 'elapsed-time', - '26', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:42:01 GMT', - 'Content-Length', - '185' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71fdcddfd7f002dd054ff05000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'c90ee76f-b719-43fb-88f0-12be99d8edac', - 'elapsed-time', - '10', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:42:05 GMT', - 'Content-Length', - '127' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_merge_a_new_document.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_merge_a_new_document.json new file mode 100644 index 000000000000..61b53c81c5f3 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_merge_a_new_document.json @@ -0,0 +1,1268 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6c31f111-2b64-4249-9efb-da60ed8da9be" + }, + "RequestBody": { + "name": "hotel-live-test-1097426", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:00:02 GMT", + "elapsed-time": "761", + "ETag": "W/\u00220x8D9E74FC3F6876E\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1097426\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6c31f111-2b64-4249-9efb-da60ed8da9be", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74FC3F6876E\u0022", + "name": "hotel-live-test-1097426", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1097426\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "11d53318-449a-49fe-992f-04968c7e1908" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:06 GMT", + "elapsed-time": "154", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "11d53318-449a-49fe-992f-04968c7e1908", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1097426\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "9fd8fd60-69dd-45c1-a00c-4cfbd1c78072" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:00:06 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "9fd8fd60-69dd-45c1-a00c-4cfbd1c78072", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1097426\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "b201e4cd-45dd-4ec0-87f8-944275ac616e" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:00:09 GMT", + "elapsed-time": "7", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "b201e4cd-45dd-4ec0-87f8-944275ac616e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1097426\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "125", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6ba8a755-cf9f-4410-a5df-0c450717df47" + }, + "RequestBody": { + "value": [ + { + "@search.action": "mergeOrUpload", + "hotelId": "11", + "description": "New Hotel Description", + "lastRenovationDate": null + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "75", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:14 GMT", + "elapsed-time": "34", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6ba8a755-cf9f-4410-a5df-0c450717df47", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "11", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1097426\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ddc27b26-2ddb-47ba-a84a-7a09a661923c" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:00:18 GMT", + "elapsed-time": "7", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ddc27b26-2ddb-47ba-a84a-7a09a661923c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF11" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1097426\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "46f1d52c-3f33-4232-bd70-e939ad4407eb" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:00:18 GMT", + "elapsed-time": "188", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "46f1d52c-3f33-4232-bd70-e939ad4407eb", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1097426" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_modify__merge_an_existing_document.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_modify__merge_an_existing_document.js deleted file mode 100644 index 225e4bb583a8..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_modify__merge_an_existing_document.js +++ /dev/null @@ -1,101 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "36fe28d07fa12d4edea66b24e92f68a2"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('6')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3efaf4a391fcf5225be41f3d5aaecb72f4d12c6fa675b16a8b6a494d5eafeb555d34c5f2a2bc4ef377ab7cd91497f938fda29ae565daac8b366fd2797699a7d932ada679b6dcbe2cf2ab3141f6003dab0df469d6e617557d6dfe6eb38be6a347dffbfee8a35556bfa56ece96d3723dcb093d69d02c2a7c7c5c96d595fbb4cc9af655beac2e33807f4a40cd37357db2bc307f951575482dccdfd96c56e70df5287fd655b5a03fbef7fd5ff2ff00978a208417010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '4a5667da-7377-4260-9fa5-a7ffc70a3ac6', - 'elapsed-time', - '14', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:41:38 GMT', - 'Content-Length', - '301' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"mergeOrUpload","hotelId":"6","hotelName":null,"description":"Modified Description","descriptionFr":null,"category":null,"tags":[],"parkingIncluded":null,"smokingAllowed":null,"lastRenovationDate":null,"rating":null,"location":null,"address":null,"rooms":[]}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471f7dfad1e8a3a6cdda75f3d1a3b65ee7a38ff2baaeea2ff2a6c92ea8e1725d96a6c54935a34ff676767ec9f77fc9ff037255c7d34a000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'c5eff099-5a41-47c9-9c8d-9adb4986c6ff', - 'elapsed-time', - '32', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:41:38 GMT', - 'Content-Length', - '184' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs('6')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147f3aacdcbb3d9478f3efaf4a391fcf5225be41f3d5aaecb72f4d12c6fa675b16a8b6a494dbea866c57991cfd2a7dec741a367b579739ab5f945555f9bbfdbeca2f9e8d1f7be3ffa6895d56f8be5c5d9725aae6739752d0d9a45858f8fcbb2ba729f9659d3beca97d56506f04f09a8f9a6a64f9617e6afb2a20ea985f93b9bcdeabca11ee5cfbaaa16f4c7f7beff4bfe1fcc8e7273f3000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '4aa275a3-409d-48a6-96ff-9231d357435e', - 'elapsed-time', - '15', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:41:43 GMT', - 'Content-Length', - '264' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_modify__merge_an_existing_document.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_modify__merge_an_existing_document.json new file mode 100644 index 000000000000..d26e4dba4a6d --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_mergeoruploaddocuments_modify__merge_an_existing_document.json @@ -0,0 +1,1336 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "04ec8b29-6e9d-49d7-9d52-98c0848636f4" + }, + "RequestBody": { + "name": "hotel-live-test-1052869", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:59:41 GMT", + "elapsed-time": "1053", + "ETag": "W/\u00220x8D9E74FB74D7480\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "04ec8b29-6e9d-49d7-9d52-98c0848636f4", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74FB74D7480\u0022", + "name": "hotel-live-test-1052869", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "22983208-e978-4a46-b0e2-b645f135abcd" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:44 GMT", + "elapsed-time": "149", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "22983208-e978-4a46-b0e2-b645f135abcd", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3548a932-2df7-45d8-991e-3de7a15c5e89" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:44 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "3548a932-2df7-45d8-991e-3de7a15c5e89", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8a83f285-f874-4698-89a3-ce121e6fda9c" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:59:49 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8a83f285-f874-4698-89a3-ce121e6fda9c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)/docs(\u00276\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "7b555e98-cbc0-49a8-acb1-8de90b8bd4e3" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "279", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:53 GMT", + "elapsed-time": "14", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "7b555e98-cbc0-49a8-acb1-8de90b8bd4e3", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "6", + "hotelName": null, + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "descriptionFr": null, + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "288", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "b46bfc22-0a5e-47b2-8c81-fe9dc16538f1" + }, + "RequestBody": { + "value": [ + { + "@search.action": "mergeOrUpload", + "hotelId": "6", + "hotelName": null, + "description": "Modified Description", + "descriptionFr": null, + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "74", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:53 GMT", + "elapsed-time": "29", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "b46bfc22-0a5e-47b2-8c81-fe9dc16538f1", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 200 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)/docs(\u00276\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c51fe1e0-2445-4a15-a7e9-d0e9d3db77f4" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "243", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:59:56 GMT", + "elapsed-time": "8", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "c51fe1e0-2445-4a15-a7e9-d0e9d3db77f4", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "hotelId": "6", + "hotelName": null, + "description": "Modified Description", + "descriptionFr": null, + "category": null, + "tags": [], + "parkingIncluded": null, + "smokingAllowed": null, + "lastRenovationDate": null, + "rating": null, + "location": null, + "address": null, + "rooms": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1052869\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f6bc029f-4b6e-4078-8b6c-ee91f50cad1e" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:59:56 GMT", + "elapsed-time": "174", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "f6bc029f-4b6e-4078-8b6c-ee91f50cad1e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1052869" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_the_correct_search_result.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_the_correct_search_result.js deleted file mode 100644 index 4c6c4e295a0d..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_the_correct_search_result.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "b890d1edeacdac4882dcb2316400e1bd"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.post.search`, {"count":true,"search":"budget","skip":0,"top":5}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cadd6cbf6a3479f8e3ebaccca75fed1a3efd1574d9ed5d3f9b89956357db23bdebfb773ffde8307a38fe6559b9767b38f1e7d74ef23fdeb45b6a0361f9d4eab65f5bacdaee9f359de4ceb62d516d592bef9c9bcbe4e57d56a5d6675caafa4c5326dabab65d8f4594d8dbffdfbae7776cef7d1a8ccd355b96ef4d5a2ced37c995e166599d37bd3accd2faafa9a5e79b29e5de42d7dd666170de1ffd155715ed09f13f9fcfba38f5659fdb6585e9c2da7e57a9613f66dbdce471f358b0a1f1f976575854fcfb3b2a18fcbac695fe5cbea3203564fa923ea64f7e1c3fbdb3b0fb67776dfec3c78b4b343fffb29eaa3a636cb8b8f1eed8f77e8c58ab0a2573e7af48b3f6aaf5778ed6555107509ddaaaa67c5926001c3edddbdbdf1eebdddfb44d2fd4fc79f3e38b87fb04b784e6bfad6bebb046109f9ba5ae5755be0cd5f2c1f12b55fbefefcd1febdbd4f3ffa25bfe4978c3eca66b33a6fa8c1725d968455552de88fef7dff978c2293b97b40cf1e4d38cf054fe6ee0e75c47fea6c9e802beaeba698e5e9b7f1397def4d15b5789d5de6e97a45f398dedff9ddd3eafc3c6deb6c56e0ebac94796ec669faaccef3f4bbc5b362945ed479d6a6864ae992f04a67c4066085517a4ea8a76f8b763acfe9afabac99e775fa0bd3597d9dd7a3746fffee83b459af5655dd8ed249755512ddd38c98e19a5e2dda250d3f9de6cb965eca96b37441831d8748337f81bda60fc1ab8ba2c97f90fef4baf945eb8ff169bec30369d635715e93cef1193362e306b6a4bf684c180e8d266bd70521d3d6689a1f34e9a4200e6d8a76cd1f3c4c57f69bd99a91abf36d66e0513a5d174db1ccd369b55895d2aaa58f4ba2eabac969dc0d7ff890a8417f8f082d1e3ad3c18e9fc030d09466c9d0206f53969a7c89f9060988dc83a2b2b7bf3daf68c4e775b56c094cf3366df2fab29882f3a634a9347924ac65359940b089c9da6c5d67c4d3c4ae3db15201eaca9548db90583ddcdea1ff7d1a15ab7bef27560f0ec60ff777f60fee8deedd1f3fdcd9dffd94b0fc70a1fac51f3544e4bc3d361f7cf4e9c3dd9df459769db76dce139abe9a11d469d182ca4fd7f53c5bd0df44ac367f595797c59208fae8a31727f4212b5c9e8daf5e1fd3dfab8a9a9527d50c2df61e3cd8bdf711756e44f817fb1c4c0d5e13cb113beca6bf1711287d92cfd2ade345be24eecc9b3b04cd6bcdfc6edb3b2e25c62501298b36dd7a2d73cd6f2a81f805fa739235f92b42ffa3477be3fd7dfa3b9f7dc96009ab8f5cf7d4b229f37cd5b0c6a0c6f47774fa0dc729532db2b779fd112b280f65022d2c9abea2f103ed9f58e72453d4d10de33c218a4f4812304823dfbf88fa25109bc7ebf5471fba513f187ffa90fe0e476db1a1a6370d5b856160dc3cf28e6ade193ff8f4c1ce2efa65f5c9aaf92175c57fa9667e9d4f6bc2972520fd025f50038f1ad4e4cd3c17fd9b164d4a1a9cb4e435893049119191146f4bdf2f32126b523e8bbc9e16a4afb39a34e735a971fe168c0cb9c7ef73c2b1c5172ff2abf4f7a9eab7e3f4383da7df17c5724d8297665719356ed237c522ffb8495fffa2754613019af3eb45d356753135aa8a00e163f4304ab326bdca49edd3cf8a3ead497565343d6844c3cb49da5a6a4d460364b308d018180e310401cea8cf05c9509ab5a4a7a76d4176099d4f2b9a915545f39ed1489971a00d3d5231e33cffd869fa14fd1533fc9d3fccca9c18aef5f539db868cd43ac973b1a206201b7f77402373d464854c0d453510c7acca9ca839a5a6bbf7ef1110fada0c06d424462de9ff340e25295980b6aed6341282c234810569f3c58a143b9950ea8c50a33e95baf432605263ee92085b2c9b0270d3d9c7d99a5a362400f9fa1dfd4984253c6838a21088b8bf685da4e7a2ff2d5a69f9f19aa84cd41290f43efd9f2d8ba33323e3e84c7f1384f2e3e305437ec87881e6e03c6381aa758b8fe9532319abaa020f938747b09662684990e823fa735ae4f545fe8d599b073be4c16def1ebcd939205343fff3adcd7b3a710fee8d1f3eb8bfbf736fb40fc9ddb97ff0b3666e1e3c48efb7f3f4f812c0889741493353f4091990d0cefc3ef4e1463bb3bbb3b3b7b7c9ce786a113ad42abe74eb84ba875f081deabdc3c2743b2d0c3980c0e1074915f317a029cdbcaee943a7911f7ea84616ce306c7739adefce2e67a48b49137b0321b01e0640ddd8ba74eb0bc026d94a7fb2c8af80b2f7de4d04881ae01ec01b687030dee9d3c0e0472dbf1e09461ffd74365dffe00745daae2744102649cf38edddbf77efdec37b04958d0b5ba73d7a97ff52ebf4aacaa6f301b374429664050dcb2f9082a7d8e16a394ecf96e7a44e4867911aa72fa030bc1799ac6154b8207924671ff682e69ed9c741592fe97b6a083024c956ef3041e93333766e447fbf7794289f0ee89783bded9dfded3dd22f116f76f7fdf4cbae172412efff3083c4f864ef5347fc974ef6e9bb1500329736f49d376bf4ed4b7253c88bb8a8aa99cc78d882e7f5b8410c36219fc419616a46141a9cb71f05f74c6dccdbf77fc9ff03a337a51ac6110000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '94a78f43-5902-4a62-aac7-a8f0c6ebffea', - 'elapsed-time', - '37', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:39:13 GMT', - 'Content-Length', - '1958' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_the_correct_search_result.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_the_correct_search_result.json new file mode 100644 index 000000000000..f1d030ad16f0 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_the_correct_search_result.json @@ -0,0 +1,1449 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0ef32269-d51a-4994-8d6b-f397b4b2d425" + }, + "RequestBody": { + "name": "hotel-live-test-1062762", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:57:14 GMT", + "elapsed-time": "650", + "ETag": "W/\u00220x8D9E74F604F2FBC\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1062762\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0ef32269-d51a-4994-8d6b-f397b4b2d425", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F604F2FBC\u0022", + "name": "hotel-live-test-1062762", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1062762\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "b37eb5fe-2912-4b14-9310-cf6415bd5744" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:57:19 GMT", + "elapsed-time": "134", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "b37eb5fe-2912-4b14-9310-cf6415bd5744", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1062762\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "50b4d2a8-b9e2-441d-800b-7926289d5e8b" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:19 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "50b4d2a8-b9e2-441d-800b-7926289d5e8b", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1062762\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f909aa66-5a68-4650-9e2b-1988bb2761f9" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:23 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "f909aa66-5a68-4650-9e2b-1988bb2761f9", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1062762\u0027)/docs/search.post.search?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "49", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f57c1269-5135-4851-9349-23ca934c0a04" + }, + "RequestBody": { + "count": true, + "search": "budget", + "skip": 0, + "top": 5 + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4550", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:57:26 GMT", + "elapsed-time": "101", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "f57c1269-5135-4851-9349-23ca934c0a04", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.count": 6, + "value": [ + { + "@search.score": 1.4305377, + "hotelId": "3", + "hotelName": "EconoStay", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00Z", + "rating": 4.0, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": null, + "rooms": [] + }, + { + "@search.score": 1.1888826, + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00Z", + "rating": 3.0, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + }, + { + "@search.score": 0.7670169, + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00Z", + "rating": 4.0, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.score": 0.25333932, + "hotelId": "2", + "hotelName": "Roach Motel", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00Z", + "rating": 1.0, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": null, + "rooms": [] + }, + { + "@search.score": 0.25333932, + "hotelId": "4", + "hotelName": "Express Rooms", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00Z", + "rating": 4.0, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": null, + "rooms": [] + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1062762\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "58127674-a96c-4384-850d-3c374b9972e7" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:57:27 GMT", + "elapsed-time": "169", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "58127674-a96c-4384-850d-3c374b9972e7", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1062762" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_zero_results_for_invalid_query.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_zero_results_for_invalid_query.js deleted file mode 100644 index e4598e076e5c..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_zero_results_for_invalid_query.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "a0ed10fc192c453e9341f1d5b37cdd15"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.post.search`, {"count":true,"search":"garbxyz","skip":0,"top":5}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cadd6cbf6a3473ba38f2eb3729d7ff4e87bdfff25ff0f36f0f25c1d000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'a38077fb-a955-4a5f-b2dd-79179740fd92', - 'elapsed-time', - '18', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:39:31 GMT', - 'Content-Length', - '149' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_zero_results_for_invalid_query.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_zero_results_for_invalid_query.json new file mode 100644 index 000000000000..39b17c8d09ff --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_search_returns_zero_results_for_invalid_query.json @@ -0,0 +1,1228 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8bcc0f91-16a2-41d2-a60c-e3d67c710bde" + }, + "RequestBody": { + "name": "hotel-live-test-1021392", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:57:32 GMT", + "elapsed-time": "604", + "ETag": "W/\u00220x8D9E74F6A85F181\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1021392\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8bcc0f91-16a2-41d2-a60c-e3d67c710bde", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F6A85F181\u0022", + "name": "hotel-live-test-1021392", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1021392\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "a79c838e-dd22-4acb-8b50-e59803eaa02c" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:57:36 GMT", + "elapsed-time": "135", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "a79c838e-dd22-4acb-8b50-e59803eaa02c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1021392\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "89d0652a-7430-4758-9524-47dd7d6c5cbd" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:36 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "89d0652a-7430-4758-9524-47dd7d6c5cbd", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1021392\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6ce601a9-22d4-432a-9fbd-a0afb22bb0f5" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:40 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6ce601a9-22d4-432a-9fbd-a0afb22bb0f5", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1021392\u0027)/docs/search.post.search?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "50", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4761f923-0058-4448-9b49-0d98d82d08ca" + }, + "RequestBody": { + "count": true, + "search": "garbxyz", + "skip": 0, + "top": 5 + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "29", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:57:44 GMT", + "elapsed-time": "42", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "4761f923-0058-4448-9b49-0d98d82d08ca", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.count": 0, + "value": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1021392\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "39bb7fc1-57f6-4167-adf5-abe69a9a599a" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:57:44 GMT", + "elapsed-time": "188", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "39bb7fc1-57f6-4167-adf5-abe69a9a599a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1021392" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_the_correct_suggestions.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_the_correct_suggestions.js deleted file mode 100644 index 1674317f417f..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_the_correct_suggestions.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "9fb0a05d02b53e7fd6bc513813be0cc6"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.post.suggest`, {"search":"WiFi","suggesterName":"sg"}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1efd9e4593d9d8fdbfc5dfbd1a38f5e679779ba5ea56d95dedff9ddd3eafc3c6deb6c56b445b5ccca745eb579d98cd3f4599de7e9778b67c528bda8f3ac4dcb6a9aa151ba2478e9acba5ab6f4ff517abe2ecbf46dd14ee739fd759535f3bc4e7f613aabaff37a94eeeddf7d9036ebd5aaaadb513aa9aeca6279916665995fd3ab45bbcc9b269de6cb965eca96b37451d5f9f8a3d1478cc7d98c10deddf9e8977cff97fc3f4bd5b195d2000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'a9b08fd6-667d-4665-aff2-6a1875d39137', - 'elapsed-time', - '69', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:39:48 GMT', - 'Content-Length', - '295' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_the_correct_suggestions.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_the_correct_suggestions.json new file mode 100644 index 000000000000..4a536a098b68 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_the_correct_suggestions.json @@ -0,0 +1,1230 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c70e9d0c-ff12-4694-a07d-3f8caf287f6c" + }, + "RequestBody": { + "name": "hotel-live-test-1084813", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:57:49 GMT", + "elapsed-time": "588", + "ETag": "W/\u00220x8D9E74F74AFBD04\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1084813\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "c70e9d0c-ff12-4694-a07d-3f8caf287f6c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F74AFBD04\u0022", + "name": "hotel-live-test-1084813", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1084813\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "793c038a-bd1f-42ce-9583-d639f8cb68ac" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:57:53 GMT", + "elapsed-time": "197", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "793c038a-bd1f-42ce-9583-d639f8cb68ac", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1084813\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "be0471fd-11b8-4d54-8efe-fad562080f34" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:53 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "be0471fd-11b8-4d54-8efe-fad562080f34", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1084813\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d73f3248-9b0a-446a-b17e-123a70bdd3b9" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:57:57 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d73f3248-9b0a-446a-b17e-123a70bdd3b9", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1084813\u0027)/docs/search.post.suggest?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "38", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "345af2dd-9775-4f02-bcc5-fa3eaf93a87b" + }, + "RequestBody": { + "search": "WiFi", + "suggesterName": "sg" + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "210", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:58:01 GMT", + "elapsed-time": "79", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "345af2dd-9775-4f02-bcc5-fa3eaf93a87b", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "@search.text": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "hotelId": "10" + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1084813\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "051961f0-f594-4207-b67b-af2ba8e9d54d" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:58:01 GMT", + "elapsed-time": "188", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "051961f0-f594-4207-b67b-af2ba8e9d54d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1084813" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_zero_suggestions_for_invalid_input.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_zero_suggestions_for_invalid_input.js deleted file mode 100644 index 063aa1407eb9..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_zero_suggestions_for_invalid_input.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "0e4bf6b0847d12d104c5a8c4f1b8e4e5"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.post.suggest`, {"search":"garbxyz","suggesterName":"sg"}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bdefff92ff0742ea40440c000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '94a73d75-79da-40be-96ea-0f5c04fb8da4', - 'elapsed-time', - '14', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:40:05 GMT', - 'Content-Length', - '133' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_zero_suggestions_for_invalid_input.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_zero_suggestions_for_invalid_input.json new file mode 100644 index 000000000000..c3f29e66ae73 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_suggest_returns_zero_suggestions_for_invalid_input.json @@ -0,0 +1,1225 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "a9d3d17b-5b23-4074-8bcc-aefd512d0449" + }, + "RequestBody": { + "name": "hotel-live-test-1045663", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 19:58:06 GMT", + "elapsed-time": "720", + "ETag": "W/\u00220x8D9E74F7EFE2236\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1045663\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "a9d3d17b-5b23-4074-8bcc-aefd512d0449", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74F7EFE2236\u0022", + "name": "hotel-live-test-1045663", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045663\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "511f0b47-fd87-45a3-98bd-6d072458e095" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:58:11 GMT", + "elapsed-time": "180", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "511f0b47-fd87-45a3-98bd-6d072458e095", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045663\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8d052c7f-1cf4-4ac0-98fa-b2926aa93fcd" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:58:11 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8d052c7f-1cf4-4ac0-98fa-b2926aa93fcd", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045663\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ae47ca4f-d29c-4460-aeb2-e3dbfae82b67" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 19:58:14 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ae47ca4f-d29c-4460-aeb2-e3dbfae82b67", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045663\u0027)/docs/search.post.suggest?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "41", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0b5498ef-9129-4298-ba79-05d43fc01412" + }, + "RequestBody": { + "search": "garbxyz", + "suggesterName": "sg" + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "12", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 19:58:19 GMT", + "elapsed-time": "36", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0b5498ef-9129-4298-ba79-05d43fc01412", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1045663\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d70578ca-0ff4-4f8b-9c8a-4674f545a5fa" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 19:58:19 GMT", + "elapsed-time": "179", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "d70578ca-0ff4-4f8b-9c8a-4674f545a5fa", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1045663" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_uploaddocuments_upload_a_set_of_documents.js b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_uploaddocuments_upload_a_set_of_documents.js deleted file mode 100644 index 2b4b16e44098..000000000000 --- a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_uploaddocuments_upload_a_set_of_documents.js +++ /dev/null @@ -1,69 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "572c1712144b6077bad21ebad40a9de2"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .post(`/indexes('hotel-live-test1')/docs/search.index`, {"value":[{"@search.action":"upload","hotelId":"11","description":"New Hotel Description","lastRenovationDate":null},{"@search.action":"upload","hotelId":"12","description":"New Hotel II Description","lastRenovationDate":null}]}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef1479759b9ce3f7af4bd5ffcd1dbfcfaa3471fedee7e34faa869b376dd7cf4a8add7f9e8a3bcaeabfa8bbc69b20b6ab95c97a5697152cde893bd9ddd5f32b2efef7dadf7bfff4bfe1fabe085b98b000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=none', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - '7012cd5d-67ab-49cd-9909-0d39f88bb84b', - 'elapsed-time', - '38', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:42:43 GMT', - 'Content-Length', - '191' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test1')/docs/$count`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f22fec7bff71fdcddfb7f0097815d6605000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'text/plain', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'a6155741-0327-4957-968f-f3d07f0ad49c', - 'elapsed-time', - '6', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:42:46 GMT', - 'Content-Length', - '127' -]); diff --git a/sdk/search/search-documents/recordings/node/searchclient_tests/recording_uploaddocuments_upload_a_set_of_documents.json b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_uploaddocuments_upload_a_set_of_documents.json new file mode 100644 index 000000000000..c4733ed315a1 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchclient_tests/recording_uploaddocuments_upload_a_set_of_documents.json @@ -0,0 +1,1280 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "3356", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "a0574db6-80c9-4997-9f5d-e2c7f03940ba" + }, + "RequestBody": { + "name": "hotel-live-test-1030860", + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": false + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": true, + "facetable": true + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "en.lucene" + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": "fr.lucene" + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": true + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "sortable": false, + "facetable": true + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functions": [ + { + "type": "distance", + "fieldName": "location", + "boost": 2, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100 + } + } + ], + "functionAggregation": "sum" + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ] + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "6727", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:00:44 GMT", + "elapsed-time": "811", + "ETag": "W/\u00220x8D9E74FDD3CA195\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1030860\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "a0574db6-80c9-4997-9f5d-e2c7f03940ba", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E74FDD3CA195\u0022", + "name": "hotel-live-test-1030860", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1030860\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "6379", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "b15e11ef-f2d4-46c4-a46a-2137ac5bd6aa" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "1", + "description": "Best hotel in town if you like luxury hotels. They have an amazing infinity pool, a spa, and a really helpful concierge. The location is perfect -- right downtown, close to all the tourist attractions. We highly recommend this hotel.", + "descriptionFr": "Meilleur h\u00F4tel en ville si vous aimez les h\u00F4tels de luxe. Ils ont une magnifique piscine \u00E0 d\u00E9bordement, un spa et un concierge tr\u00E8s utile. L\u0027emplacement est parfait \u2013 en plein centre, \u00E0 proximit\u00E9 de toutes les attractions touristiques. Nous recommandons fortement cet h\u00F4tel.", + "hotelName": "Fancy Stay", + "category": "Luxury", + "tags": [ + "pool", + "view", + "wifi", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": false, + "lastRenovationDate": "2010-06-27T00:00:00.000Z", + "rating": 5, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 47.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "2", + "description": "Cheapest hotel in town. Infact, a motel.", + "descriptionFr": "H\u00F4tel le moins cher en ville. Infact, un motel.", + "hotelName": "Roach Motel", + "category": "Budget", + "tags": [ + "motel", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": true, + "lastRenovationDate": "1982-04-28T00:00:00.000Z", + "rating": 1, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 49.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "3", + "description": "Very popular hotel in town", + "descriptionFr": "H\u00F4tel le plus populaire en ville", + "hotelName": "EconoStay", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "4", + "description": "Pretty good hotel", + "descriptionFr": "Assez bon h\u00F4tel", + "hotelName": "Express Rooms", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "1995-07-01T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 46.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "5", + "description": "Another good hotel", + "descriptionFr": "Un autre bon h\u00F4tel", + "hotelName": "Comfy Place", + "category": "Budget", + "tags": [ + "wifi", + "budget" + ], + "parkingIncluded": true, + "smokingAllowed": false, + "lastRenovationDate": "2012-08-12T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -122.131577, + 48.678581 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + } + }, + { + "@search.action": "upload", + "hotelId": "6", + "description": "Surprisingly expensive. Model suites have an ocean-view.", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "7", + "description": "Modern architecture, very polite staff and very clean. Also very affordable.", + "descriptionFr": "Architecture moderne, personnel poli et tr\u00E8s propre. Aussi tr\u00E8s abordable.", + "hotelName": "Modern Stay" + }, + { + "@search.action": "upload", + "hotelId": "8", + "description": "Has some road noise and is next to the very police station. Bathrooms had morel coverings.", + "descriptionFr": "Il y a du bruit de la route et se trouve \u00E0 c\u00F4t\u00E9 de la station de police. Les salles de bain avaient des rev\u00EAtements de morilles." + }, + { + "@search.action": "upload", + "hotelId": "9", + "hotelName": "Secret Point Motel", + "description": "The hotel is ideally located on the main commercial artery of the city in the heart of New York. A few minutes away is Time\u0027s Square and the historic centre of the city, as well as other places of interest that make New York one of America\u0027s most attractive and cosmopolitan cities.", + "descriptionFr": "L\u0027h\u00F4tel est id\u00E9alement situ\u00E9 sur la principale art\u00E8re commerciale de la ville en plein c\u0153ur de New York. A quelques minutes se trouve la place du temps et le centre historique de la ville, ainsi que d\u0027autres lieux d\u0027int\u00E9r\u00EAt qui font de New York l\u0027une des villes les plus attractives et cosmopolites de l\u0027Am\u00E9rique.", + "category": "Boutique", + "tags": [ + "pool", + "air conditioning", + "concierge" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1970-01-18T00:00:00.000Z", + "rating": 4, + "location": { + "type": "Point", + "coordinates": [ + -73.975403, + 40.760586 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "677 5th Ave", + "city": "New York", + "stateProvince": "NY", + "country": "USA", + "postalCode": "10022" + }, + "rooms": [ + { + "description": "Budget Room, 1 Queen Bed (Cityside)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (c\u00F4t\u00E9 ville)", + "type": "Budget Room", + "baseRate": 9.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd" + ] + }, + { + "description": "Budget Room, 1 King Bed (Mountain View)", + "descriptionFr": "Chambre \u00C9conomique, 1 tr\u00E8s grand lit (Mountain View)", + "type": "Budget Room", + "baseRate": 8.09, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "vcr/dvd", + "jacuzzi tub" + ] + } + ] + }, + { + "@search.action": "upload", + "hotelId": "10", + "hotelName": "Countryside Hotel", + "description": "Save up to 50% off traditional hotels. Free WiFi, great location near downtown, full kitchen, washer \u0026 dryer, 24/7 support, bowling alley, fitness center and more.", + "descriptionFr": "\u00C9conomisez jusqu\u0027\u00E0 50% sur les h\u00F4tels traditionnels. WiFi gratuit, tr\u00E8s bien situ\u00E9 pr\u00E8s du centre-ville, cuisine compl\u00E8te, laveuse \u0026 s\u00E9cheuse, support 24/7, bowling, centre de fitness et plus encore.", + "category": "Budget", + "tags": [ + "24-hour front desk service", + "coffee in lobby", + "restaurant" + ], + "parkingIncluded": false, + "smokingAllowed": true, + "lastRenovationDate": "1999-09-06T00:00:00.000Z", + "rating": 3, + "location": { + "type": "Point", + "coordinates": [ + -78.940483, + 35.90416 + ], + "crs": { + "type": "name", + "properties": { + "name": "EPSG:4326" + } + } + }, + "address": { + "streetAddress": "6910 Fayetteville Rd", + "city": "Durham", + "stateProvince": "NC", + "country": "USA", + "postalCode": "27713" + }, + "rooms": [ + { + "description": "Suite, 1 King Bed (Amenities)", + "descriptionFr": "Suite, 1 tr\u00E8s grand lit (Services)", + "type": "Suite", + "baseRate": 2.44, + "bedOptions": "1 King Bed", + "sleepsCount": 2, + "smokingAllowed": true, + "tags": [ + "coffee maker" + ] + }, + { + "description": "Budget Room, 1 Queen Bed (Amenities)", + "descriptionFr": "Chambre \u00C9conomique, 1 grand lit (Services)", + "type": "Budget Room", + "baseRate": 7.69, + "bedOptions": "1 Queen Bed", + "sleepsCount": 2, + "smokingAllowed": false, + "tags": [ + "coffee maker" + ] + } + ] + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "642", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:49 GMT", + "elapsed-time": "228", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "b15e11ef-f2d4-46c4-a46a-2137ac5bd6aa", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "1", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "2", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "3", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "4", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "5", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "6", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "7", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "8", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "9", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "10", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1030860\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6cce3555-9ba8-47e5-8cad-457479bc3a10" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "4", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:00:49 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6cce3555-9ba8-47e5-8cad-457479bc3a10", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF0" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1030860\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ff947d46-f890-4a59-89e8-afb5e3fc83b2" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:00:53 GMT", + "elapsed-time": "5", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ff947d46-f890-4a59-89e8-afb5e3fc83b2", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF10" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1030860\u0027)/docs/search.index?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "228", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0fbbe5c7-48ce-4fd0-8024-4d2e4010e5e0" + }, + "RequestBody": { + "value": [ + { + "@search.action": "upload", + "hotelId": "11", + "description": "New Hotel Description", + "lastRenovationDate": null + }, + { + "@search.action": "upload", + "hotelId": "12", + "description": "New Hotel II Description", + "lastRenovationDate": null + } + ] + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "139", + "Content-Type": "application/json; odata.metadata=none", + "Date": "Thu, 03 Feb 2022 20:00:56 GMT", + "elapsed-time": "60", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0fbbe5c7-48ce-4fd0-8024-4d2e4010e5e0", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "value": [ + { + "key": "11", + "status": true, + "errorMessage": null, + "statusCode": 201 + }, + { + "key": "12", + "status": true, + "errorMessage": null, + "statusCode": 201 + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1030860\u0027)/docs/$count?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=none", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "95945a64-9e0d-4923-b126-683f8089a670" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "5", + "Content-Type": "text/plain", + "Date": "Thu, 03 Feb 2022 20:01:01 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "95945a64-9e0d-4923-b126-683f8089a670", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": "\uFEFF12" + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1030860\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "26cfdabf-f84f-4a00-82f0-27f01d25b4e6" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:01:01 GMT", + "elapsed-time": "201", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "26cfdabf-f84f-4a00-82f0-27f01d25b4e6", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1030860" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_creates_the_index_object_using_createorupdateindex.js b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_creates_the_index_object_using_createorupdateindex.js deleted file mode 100644 index fbeebbe3d629..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_creates_the_index_object_using_createorupdateindex.js +++ /dev/null @@ -1,91 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "a3a77605173eb97ade41102643ab900c"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .put(`/indexes('hotel-live-test4')`, {"name":"hotel-live-test4","fields":[{"name":"id","type":"Edm.String","key":true,"searchable":false,"filterable":false,"sortable":false,"facetable":false},{"name":"awesomenessLevel","type":"Edm.Double","searchable":false,"filterable":true,"sortable":true,"facetable":true},{"name":"description","type":"Edm.String","searchable":true,"filterable":false,"sortable":false,"facetable":false},{"name":"details","type":"Edm.ComplexType","fields":[{"name":"tags","type":"Collection(Edm.String)","searchable":true,"filterable":false,"sortable":false,"facetable":false}]},{"name":"hiddenWeight","type":"Edm.Int32","retrievable":false,"searchable":false,"filterable":false,"sortable":false,"facetable":false}]}) - .query(true) - .reply(201, {"@odata.context":"https://endpoint/$metadata#indexes/$entity","@odata.etag":"\"0x8D9D237D90746A4\"","name":"hotel-live-test4","defaultScoringProfile":null,"fields":[{"name":"id","type":"Edm.String","searchable":false,"filterable":false,"retrievable":true,"sortable":false,"facetable":false,"key":true,"indexAnalyzer":null,"searchAnalyzer":null,"analyzer":null,"normalizer":null,"synonymMaps":[]},{"name":"awesomenessLevel","type":"Edm.Double","searchable":false,"filterable":true,"retrievable":true,"sortable":true,"facetable":true,"key":false,"indexAnalyzer":null,"searchAnalyzer":null,"analyzer":null,"normalizer":null,"synonymMaps":[]},{"name":"description","type":"Edm.String","searchable":true,"filterable":false,"retrievable":true,"sortable":false,"facetable":false,"key":false,"indexAnalyzer":null,"searchAnalyzer":null,"analyzer":null,"normalizer":null,"synonymMaps":[]},{"name":"details","type":"Edm.ComplexType","fields":[{"name":"tags","type":"Collection(Edm.String)","searchable":true,"filterable":false,"retrievable":true,"sortable":false,"facetable":false,"key":false,"indexAnalyzer":null,"searchAnalyzer":null,"analyzer":null,"normalizer":null,"synonymMaps":[]}]},{"name":"hiddenWeight","type":"Edm.Int32","searchable":false,"filterable":false,"retrievable":false,"sortable":false,"facetable":false,"key":false,"indexAnalyzer":null,"searchAnalyzer":null,"analyzer":null,"normalizer":null,"synonymMaps":[]}],"scoringProfiles":[],"corsOptions":null,"suggesters":[],"analyzers":[],"normalizers":[],"tokenizers":[],"tokenFilters":[],"charFilters":[],"encryptionKey":null,"similarity":{"@odata.type":"#Microsoft.Azure.Search.BM25Similarity","k1":null,"b":null},"semantic":null}, [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237D90746A4"', - 'Location', - "https://endpoint/indexes('hotel-live-test4')?api-version=2021-04-30-Preview", - 'request-id', - '58d3e66f-2d12-4853-a248-e5d54621ca4a', - 'elapsed-time', - '636', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:55 GMT', - 'Content-Length', - '1714' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test4')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195eff71fa307f9737777fb77cd916edf5472303971a5c10d0dff7a39d77074f1f3eddbbf7e0e9c39d07fb9f1eefffbe1f51ab65b6c8e9eb79d5e6e576595ce6dbe8769fbe99e5e7d9ba6c5f4fabba585ebcacabf3a2a4a6cb75598e3e3a2ff272d67cf4e87bbfd8402866f44e7bbdc2efa7b3c5f8758bd7e833413b9be0e5f3ac6c72bc5db6791d7c54e7d43ebf94cfda7a4d1f3555ddcadfdae63c9bd268fc4fdee6d7a63513e0789995d73fc86b83a6f4ddfd34ebfcbdacea455616de27cdf5b25a5e2fbec85618e3f77fc9c80e33bbca9b6a912ff3a6799e5fe6250dd01bf4d36a0df40800771ce0ea0f5a50de3866f9db1bb27cc02356883fa421cff2665a17abb6a89634326fb4d1291634fdc12ab61b47ab6dbce1ea273f27e36db3a26c685cde584faac5aaccdfbdc12784678ffd49cabc374eaab2cca7a0d8165e1642dda1ef055b19a1d0e0ff7b94f269352f66b37cf9ddbcb898b7343c1d3ec67cb66cefedd147d26b80e94d43d6cffe5f3566fa285084fcf1e823faacf99245833ed057d71717a442f39a3e4113d399fee9fad20fdaea6dbeecfefd8c49a49f10f9eae0837c39adafb9d7df0b04d07e8b4551663594ff236b5574427efc8b625a574d75de8e8f7fb0aef3f16ba6cbf8c9177bf75fbbf788a0bb06dc447ef92504385f646454a6fac1ff0354c8b1c5b2060000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237D90746A4"', - 'Vary', - 'Accept-Encoding', - 'request-id', - '544041e1-ea5f-4b54-afbe-2d3cb9e35a30', - 'elapsed-time', - '18', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:55 GMT', - 'Content-Length', - '663' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .delete(`/indexes('hotel-live-test4')`) - .query(true) - .reply(204, "", [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Expires', - '-1', - 'request-id', - '83e49e0b-34c5-4e80-afc4-c58ab0e84782', - 'elapsed-time', - '140', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:55 GMT' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_creates_the_index_object_using_createorupdateindex.json b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_creates_the_index_object_using_createorupdateindex.json new file mode 100644 index 000000000000..6e8ab494713a --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_creates_the_index_object_using_createorupdateindex.json @@ -0,0 +1,731 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "242e5c1f-8328-476f-82ba-de8261264ddc" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:01 GMT", + "elapsed-time": "7", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "242e5c1f-8328-476f-82ba-de8261264ddc", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "436ff9ad-7b4d-4651-9e37-0ec705bf6372" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:01 GMT", + "elapsed-time": "26", + "ETag": "W/\u00220x8D9E750525E342D\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "436ff9ad-7b4d-4651-9e37-0ec705bf6372", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750525E342D\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "340dd1aa-3a89-46f4-9586-0613dd1686cd" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:01 GMT", + "elapsed-time": "22", + "ETag": "W/\u00220x8D9E75052638A91\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "340dd1aa-3a89-46f4-9586-0613dd1686cd", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75052638A91\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d89588b9-1c0c-4944-afdb-144d024fefa1" + }, + "RequestBody": { + "name": "hotel-live-test-1012685", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:01 GMT", + "elapsed-time": "584", + "ETag": "W/\u00220x8D9E75052BC4BD2\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1012685\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d89588b9-1c0c-4944-afdb-144d024fefa1", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E75052BC4BD2\u0022", + "name": "hotel-live-test-1012685", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test4\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "700", + "Content-Type": "application/json", + "Prefer": "return=representation", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "41957458-6892-42a2-914f-d1f9701c7d25" + }, + "RequestBody": { + "name": "hotel-live-test4", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1688", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:06 GMT", + "elapsed-time": "662", + "ETag": "W/\u00220x8D9E7505585FEDA\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test4\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "41957458-6892-42a2-914f-d1f9701c7d25", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7505585FEDA\u0022", + "name": "hotel-live-test4", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test4\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "b275a3d6-7474-4eb1-ab02-3d1ad884313c" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "1688", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:06 GMT", + "elapsed-time": "17", + "ETag": "W/\u00220x8D9E7505585FEDA\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "b275a3d6-7474-4eb1-ab02-3d1ad884313c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7505585FEDA\u0022", + "name": "hotel-live-test4", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test4\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "62d96eaa-cdd0-488e-a33f-4b46445729cc" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:06 GMT", + "elapsed-time": "144", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "62d96eaa-cdd0-488e-a33f-4b46445729cc", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1012685\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f0aed2d1-f3e8-4487-9f50-b6ee8e3212fb" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:06 GMT", + "elapsed-time": "164", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "f0aed2d1-f3e8-4487-9f50-b6ee8e3212fb", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0bd8621d-c6e8-4b66-aa46-a222ad151b20" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:10 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "0bd8621d-c6e8-4b66-aa46-a222ad151b20", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "25355e91-44b0-456d-b463-45e2e409590e" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:10 GMT", + "elapsed-time": "11", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "25355e91-44b0-456d-b463-45e2e409590e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1012685" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_correct_index_object.js b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_correct_index_object.js deleted file mode 100644 index ea5d6f989e51..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_correct_index_object.js +++ /dev/null @@ -1,39 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "e242d2b89f5ca6065201cc0818e47110"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test3')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195eff71fa307f9737777fb77cd916edf5472303971a5c10d0dff7a39d77074f1f3eddbbf7e0e4c9bddd87074f9efcbe1f51ab65b6c8e9eb79d5e6e576595ce6dbe8f61e7d33cbcfb375d9be9e5675b1bc785957e745494d97ebb21c7d745ee4e5acf9e8d1f77eb18150cce89df67a85df4f678bf1eb16afd167827636c1cbe759d9e478bb6cf33af8a8cea97d7e299fb5f59a3e6aaaba95bfb5cd7936a5d1f89fbccdaf4d6b26c0f1322baf7f90d7064de9bbfb69d6f97b59d58bac2cbc4f9aeb65b5bc5e7c91ad30c6efff92911d66769537d5225fe64df33cbfcc4b1aa037e8a7d51ae81100ee38c0d51fb4a0bc71ccf2b73764f98047ac107f48439ee5cdb42e566d512d6964de68a3532c68fa83556c378e56db78c3d54f7e4ec6db6645d9d0b8bcb19e548b5599bf7b834f08cf1efb9394796f9c5465994f41b12dbc2c84ba43df0bb63242a1c1fff728e5d36a5ecc66f9f2bb7971316f69783a7c8cf96cd9dedba38fa4d700d39b86ac9ffdbf6accf451a008f9e3d147f459f3258b067da0afae2f2e4885e6357d8226a633fdd3f5a51fb4d5db7cd9fdfb1993483f21f2d5c107f9725a5f73afbf1708a0fd168ba2cc6a28ff47d6aae884fcf817c5b4ae9aeabc1d1fff605de7e3d74c97f1932ff6eebf76ef1141770db889fcf24b0870bec8c8a84cf583ff071ec204b2b2060000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237CB3198BB"', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'a6047571-0de6-4ba0-9d5b-71d9deab548d', - 'elapsed-time', - '94', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:36 GMT', - 'Content-Length', - '663' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_correct_index_object.json b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_correct_index_object.json new file mode 100644 index 000000000000..17e3810be546 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_correct_index_object.json @@ -0,0 +1,519 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "059e4be3-003a-4324-9106-08575212dd98" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:43 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "059e4be3-003a-4324-9106-08575212dd98", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "47bb3ebe-8de1-4592-a939-2916bdada7b7" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:43 GMT", + "elapsed-time": "22", + "ETag": "W/\u00220x8D9E75047A33962\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "47bb3ebe-8de1-4592-a939-2916bdada7b7", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75047A33962\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "88ddc4c2-7f9a-47a2-a438-2f1affc94aea" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:43 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E75047A7306E\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "88ddc4c2-7f9a-47a2-a438-2f1affc94aea", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75047A7306E\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ac5aa62c-fa11-46fd-a84f-bd53561181bf" + }, + "RequestBody": { + "name": "hotel-live-test-1047340", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:43 GMT", + "elapsed-time": "737", + "ETag": "W/\u00220x8D9E750481746C8\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1047340\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "ac5aa62c-fa11-46fd-a84f-bd53561181bf", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E750481746C8\u0022", + "name": "hotel-live-test-1047340", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1047340\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "c34b759e-d1e8-4eb4-b8bc-de2987f45b3f" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:48 GMT", + "elapsed-time": "25", + "ETag": "W/\u00220x8D9E750481746C8\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "c34b759e-d1e8-4eb4-b8bc-de2987f45b3f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E750481746C8\u0022", + "name": "hotel-live-test-1047340", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1047340\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d933a2fa-f3d1-4f0c-a404-afe0a5d93d5d" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:48 GMT", + "elapsed-time": "143", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "d933a2fa-f3d1-4f0c-a404-afe0a5d93d5d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "181d4646-5723-48c2-b5c9-322a8c809ef2" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:52 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "181d4646-5723-48c2-b5c9-322a8c809ef2", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3481b183-8dd6-4cb4-b1c1-efee7895fbaf" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:52 GMT", + "elapsed-time": "13", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "3481b183-8dd6-4cb4-b1c1-efee7895fbaf", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1047340" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes.js b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes.js deleted file mode 100644 index efbd61ff8364..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "9f60376c3091fcdcc1e6ce9ac7fc330f"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get('/indexes') - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195eff71fa307f97371f8d3ebaccca75fed1a3ef59c8d4e482c0febe1fedbc3b787a70b2bfb7ffe0fec3fb4f1e1cdcff7d3fa2f6cb6c41cd3f9a576d5e6e97c565bedd648b55996fa3ff7bd460969f67ebb27d3dadea6279f1b2aece8b92de58aecb72f4d1799197b386bbf3019dcde8c5f67a850f4e678bf1eb16efd26732886c0208e759d9e40051b6792d1fb5f59a3ea9736a9e5ffa1f3555ddfa7f9f67531a177fa060dee6d7e64b26c6f1322baf7f90d70653e9b9fb69d6f97b59d58bac2cbc4f9aeb65b5bc5e7c91ad30ccefff925138d217f8fde6b10a62dfe450f5f71fd258677933ad8b555b544b1ad9fb8f56b1dd385c6df3b330de8ff2e5b85c4ff325a6ea6b0efb594deffe7f6ee0e7f5d71bf8346bf38baabea6d7de7fccf2c9c621cbdfde88e5830f1eb0fcfd3e2325ed08b5a9a33ca9ca329f62beb7dc80efd0f7d2b18feb7b8e5847f5ff8621afb2fa2d0deb6c392dd7b3bca3aa9f545599679072e958705504df73ccf2f7ff1b86dc2c2a0cf9b82cababfce7c588cbac695fe5cbea3203373f2579a6017aa3c6276f8a45fee5f97993b7f49da020582baaff9f1d7c4d836645e50fb85a03297a8dbb130c15adffcf0eb4ac4853d3fcd2b0bca17e9e571775b69a5fbfac8ae5cfd2dc2a989f833167b3599d379ed2c6904f2a38adefdee013c2b3e796366d9de7ed71ec5551f2f499a02ac3d3f17e2091e4839f031a4d8bf6e781ed6e5a526214915c16cb29a6fdffe7c39d56eb65fbf3c1275b5534b3e54935fbffeda4faa3adab6ae1a9a48e0bea2936f8a17dcde6c528f4bd02c19bdf1cb594223f77e472c4f246fb352332f9e4ff2be3e5f1fdff7f98134a71bd22654ec3f286fa0dba6ce6adff378c359f7dc90cec093d46fbffcb896dca3c5f3527b05c34326fb467cbf6de1e7d245d0a968adaff8747fb430a33cd5bff2f18f2cf9bfc09fd471f0659707c6109b1a47e28654e633d5f2f9904c71717757e21f119f1c67a41df49925f7a30ed040c5b764e2707611d057079bdaa4af99bbe2ad0117da1149f15e42b89fb3ba9c86ffae8d1de788760132ef325621ded6c915d2c8b96f23de603fbe2a35ffc519d9fe7754e7f70c0f832ab090dea96c02fae0917039b46fed4beb5bbb333def9258407961700522844046a8c7a23c89988c297757151e093ef7df4ad8fa8d5227b777c919f2d5fe7b4f0017f8601107dd7171744c4bca68f88264adac669c52fe014520cc8d347f89c2dcf8b775f64ed744e7fa055b5aea7f933d012207c7f81be75297bc655a0e4dc19fde978403f68abb7f9b2fbf733e65bfd8458ba0e3e2022d6d7dcddef05c6c4b008a9625194598d988c48a2eb323a7f3ffe4531adaba63a6fc7c73f58d7f9f8358f73fce48bbdfbafdd7bc4e8bb06dc447e01b9f245b66c8ba9f9c0022719a159718b3e0f9fec7ffaf4d9f1c9f1cecd8b3efbd4e0478b3e81ec1361fd913207dd3c5641ec9b1caafefe431a6b283bef3f5ac576e370b5cdcfc2784914bfdeda8737ecaf196228da3f5703ffd1a28f7c323c52d28effef705a7e7843fed1a2cfcf8311ff68d1078aca1ff037974190bfffdf3050f2c869a85da3fca3459f9e5bfaa3451fc2fbff6fa3a4f8f3478b3e84faffdf06faa3451f4e0671decc536c489ef5359b17a3d0f70a046f7e73d4528afcdc91cb11cb1bedd78cc8e493ffaf8c97c7f7ffff61fe68d1e7ffa713fba3451f7c8e017f9361a679ebff0543fe79933fa1ffe8c3200b8e2f2c2196d40fa5cc69ac6631e7478b3e3f5af4a16111526ef18648a2eb323a7f3fa4459f93fddd873bf79eee3dbd79d1e73e35f8d1a24f20fb44587fa4cc41378f5510fb2687aabfff90c61acacefb8f56b1dd385c6df3b3305e12c5afb7f6e10dfb6b86188af6cfd5c07fb4e8239f0c8f94b4e3cf0fa7c50df9478b3e3f0f46fca3451f282a7fc0df5c0641fefe7fc340c923a7a1768df28f167d7a6ee9ffab167dbad4e8d2483efd101afd68d18706f0ffb7e1fe68d187b0ffffc758fdd1fe68d1e74672396279a3fd9a11997cf2ff95f1f2f8feff3fcc1f2dfafcff74627fb4e883cf31e06f32cc346ffdbf60c83f6ff227f41f7d1864c1f18525c492faa194398dd52ce6fc68d1e7478b3e342c42ca2dde1049745d46e7ef87b2e873ffdea7bbc7bbbbf74eefeddebce8f32935f8d1a24f20fb44587fa4cc41378f5510fb2687aabfff90c61acacefb8f56b1dd385c6df3b3305e12c5afb7f6e10dfb6b86188af6cfd5c07fb4e8239f0c8f94b4e3cf0fa7c50df9478b3e3f0f46fca3451f282a7fc0df5c0641fefe7fc340c923a7a1768df28f167d7a6ee98f167d08efffbf8d92e2cf1f2dfa10eaff7f1be88f167d9c0bea2936f8a17dcde6c528f4bd02c19bdf1cb594223f77e472c4f246fb352332f9e4ff2be3e5f1fdff7f983f5af4f9ffe9c4fe68d1079f63c0df649869defa7fc1907fdee44fe83ffa30c882e30b4b8825f54329731aab59ccf9d1a2cf8f167d685884945bbc2192e8ba8ccedf0f6bd1e7c1c9c37bc7c70727372ffa3ca0063f5af409649f08eb8f9439e8e6b10a62dfe450f5f71fd25843d979ffd12ab61b87ab6d7e16c64ba2f8f5d63ebc617fcd1043d1feb91af88f167de493e1919276fcf9e1b4b821ff68d1e7e7c1887fb4e80345e50ff89bcb20c8dfff6f182879e434d4ae51fed1a24fcf2dfdd1a20fe1fdffb75152fcf9a3451f42fdff6f03fdd1a28f73413dc5063fb4afd9bc1885be572078f39ba39652e4e78e5c8e58de68bf6644269ffc7f65bc3cbeffff0ff3478b3eff3f9dd81f2dfae0730cf89b0c33cd5bff2f18f2cf9bfc09fd471f0659707c6109b1a47e28654e63358b399d459f0f5df42188d4cd8f167df0894c1fe1f3a3459f9b177d1e3eddbbf7e06467efdefdfb9f3e1858f4c16acf3dfae63d577b8a8e921381a7cf64b64450553a0912d129f8e83d255e3f619197d63fab124fe4d461665779532d288dde34cff3cbbca4017a83fe06dd14f9db1bb27cc02356883fa4218782e38d363ac582a63f58c576e368b58d375cfde4e764bc6d56949e29c358bde08bbee8b33f4999f7c6d7347e3aceff9753caa7d5bc98cdf2e577f3e2620e7ba7c3c7986fe9d5e947c190f5b3ff578d993e0a14217f4c5adfb771faaa6fb8a889e94cff747de9076c4aba7f079684c8f7ff7ed372f0f064e7f864efe9fd074f0e4e36989683fbe08af7342e0ce3ec6b5a1891a080c3e423c760f2f7007fc9973fabec4534f547ca7ec9cd6315c4bec9a1eaef3fa4b1fe7fdbb090147ebd15756fd85f3371a568ff5c0dfcbcfe7a03a705aafca2faf990b626c5f8e1de807cb271c43aaaff370c7995d548789c2da72585961d55fd4d663ce4efff370cf98795e391bfffdf30e2326bda57f9b2bae4a5e6a724cf34406fd4f8e44db1c8bf3c3f6f723884828260ada8fe7f76f0350d9a15953fe0ff3f067c94e7a1a1768df2e779755167abf9356786e83be9587055043f74c80ae6e760ccd96c4679324f6963c837057d4d5be7797b1c7b55943c7d26a8caf074bc1f4824f9e0e78046538911fe7f3e4aca6ab63945249705929bffbf1fee140b323f1f7cb215a5adb3f20459e3ff9f8ed51f6d5d550b4f25755c504fb1c10fed6b362f46a1ef1508defce6a8a514f9b92397239637daaf1991c927ff5f192f8fefffffc39c644dfe8a94390dcb1bea37e8b299b7fedf30565a596306f6841ea3fdffe5c436659eaf9a13582e1a9937da5b269d05f1ffcf8cf68714669ab7fe5f30e49f37f913fa8f3e0cb2e0f8c2126249fd50d29cc67abe5e32098e2f2eeafc42e233e28df582be6bf377b4da2f3d987602862d3ba79383b08e02b8bc5e55a5fc4d5f15e888be508acfccda3ead0360b9ffa3477be31d824db8ccb1f4693a5b6417cba2a57c8ff9c0be484b10757e9ed7b4549173c0f832ab090dea96c02fae0917039b46fed4beb5bbb333dea1350762000129142202b965965ffc5126a2f0655d5c14f8e47b1f7deb236ab5c8de1d5fe467cbd7f9b45ac29f6100445f7f45c692b6715af10b38851403f2f4113e67cbf3e2dd17593b9dd31f6855adeb69fe0cb40408df5fa06f5dca9e7115283977467f3a1ed00f787da7fb77b0bc432cfdff81f59e67f7f61f9c9edebfbf7bff6964bd6795d7e7bcde435ffc68b127907922a83f52e69c9bc72a887d9343d5df7f48630d65e6fd47abd86e1caeb6f959182f89e0d75bf3f086fd35430b45fbe76ae03f5aec914f86474a5af1e787b3e286fca3c59e9f0723fed1620f14953fe06f2e73207fffbf61a0e489d350bb46f9478b3d3db7f4478b3d84f7ffdf464971e78f167b08f5ffbf0df4478b3dce05f5141bfcd0be66f36214fa5e81e0cd6f8e5a4a919f3b72396279a3fd9a11997cf2ff95f1f2f8feff3fcc1f2df6fcff74627fb4d883cf31e06f32cc346ffdbf60c83f6ff227f41f7d1864c1f18525c492fa918cb959c4f9d162cf8f167b685884945bb42192e87a8ccedf0f61b1e7e1a74f1fec9e3c39b8ffe47477afb7d8d36c37195ccc6d961efaf23d177cbe0d203f8b0b3ee6ada8e0cbaf8c7957c2a5e7eea766cacddf6ececd275db927a2fa2365eeb979ac82983f541dc77b8e553fe1c1eaef5f6bb4c498e385e134c2f57dc6fd34f765e8fff7238f8ffcf73ff794ee074dfb0f75da6901e8eb4efb09f9e33f9b6b403a2e6fd4d2e2c307fd01bcfee6ffebeecc870c9e0c3fdcd79ffd8521f3d6373e7af9fb7dc6fcfc1b5e27d18f360e5ffef646af2ffd1c0c9f826e9a711a963fe46f2eec96bfbd91ca073f07038da6febde41a7dd1f76d48e03f70d54007b99148dac6a3927ef2c164fa106570226ee7fb0f593e79cf114b8b9fd301bffe61ac26e8e0fedf35f29714db653fabf9761dd9ffbb86cd59a99f17fe8d3feae72eb7e00dfbffdf4bc6af3e6c89c50b03e87b0582376fc92c3ad88dd4d2363f0be47a7f767184f346fef32f000243d02bef3f64f9e43d472c2d3e7cc01f30db4f7e1eadc23ca1a424f3b5a71730daff9f4ff1eb0deb319feed347d2b9e0ab48febf65dcf2f77b8df6e7df7acccfc304863ffca233cb3262fa4cba154c153d7fc4fa513064fd6cd398f5930f1eb4fc7df350dd40ebff9f8f94d652fa8b6df4217de6d697f4d56f7ad14803febb1a02db3fa135395e607ff2aefa07fa07e48ed1966e041bfad30d553fe055a4eedfc12212cddeff075695ee1f1c3f78f6e0e1b34f1f3c3bf55795ea3ca3d94230bdbdfed0c5a592961ba9ddd75d5ed28f025e1735755b5697d68c7d97a7a5efeea766f6cddf6efacd275d4e27faea6827398d3e182859e57b7bf491f415a0e78f53b0dc384cf9db1ba57cc08354883fac5166edfce7c130c395676fb051e61534fdc12ab61b47ab6dbce1ea271f3c5e5239ef6985a323fffd49f1fe7f70f0b3fc1b19fccfbb88d91f7c8197ff3f37f8a2fd46064fdecaff07079f37dfc8e05725bdfcffb9c1afca6f64f0cb1b074f6fc8b0fe5f34f8e5d71f7cf38bf8156fbeff7f69cdb3ebe6cbe517b440ce8bc0ff3f1f2dbcf7f56d5498a2f59e03356ffdbf61a41cfad1a86e1aa960e80f54117dcf91ea271f3cd40f71d096ebc584dafdfc1a74c36bf9f4d2cfa741af97ffdf74c33e60c83cd69b87ace8f96396f1bde790a5c5078f58fe7e9f714e258173d33805bfffb70cf34326b6ce2fc8c1a2977efe0c792a19c713e42f6f1eb762e90f5c3f7acf91eb271f3c74f9fb7d06bcaa9af696a39561f883954fde73acd2e283874ae6255bceb27a362ed7d37c8901bccfb8cb6a9a217ca0d7bc717f9e571775b69a5fbfac0a5eaf132c0471c5f63d09207f7be357301f4c00f9fb7dc6bcaa8baee745bef437b408297f7be3940f7e0e86d9cec9db5a66c56de242c5cc1fab7eb471b0dac61bad7ef273315cac83d891febc587f74835fe5152d76d04b1f367c45ff3dc7af9f7c38013e4c9555f54546cb5bacce3e9c137420ffdf2485d1ea3fcfc940fdafe675d6f849d19f8f7428b3e5c53abbc06b4a053774fa4c7a178c654cffbf19795b67cba6a415e1d9efdfe6efa055ff3f4700b20a5f6be8aba2f8fd735a4d6f8b0dec7f526191fcdd1bfa1232d05f07ffff2ad53e906d30dc9f77a36ed6131ef1cfbb8157e7e74d37434711c16db2ebfad1cfd1b8e5eff7196a992f2fda398debffff436da6550d4ef046fab45a03297a8b7b0b30fcffde50fdc12eb2e6edff878ddcd791dfefd34734c534ba977545632133471f8f287755375ff29a287da0afae2f2ef286064b9f38dbd638b27c81d4cf23c588209e2dcf8b775f64ed744e7fa015afd63c33e6d12d643426b9af59519b2bf4134a884c195f812f68d09f6e8cfa415bbdcd298409ff7ec6d3a49fd00cd6c107f9725a5ff3687f2fcc828eb75814655603a547bff8a3dfb39a656d3656a6f8f12f4c8c393efec1bacec7af9902e3275fecdd7feddea359dd35e026f2cb2f21c0f922239f626a3eb0c089232e08f8effbd1cebb83a70fef1f1c3f383e7e76727aef60eff7fd886029c55b9a04669026abb39fce16197d35cbcfb375d9bea669235aeb54525bfaaaef8e1433fa580732c8ddca890487c8147cf401ec2dad19f92e1f4bdfdd4fcd5c9bbf9795996cf3c937ced03df2861c8e2682157571138713a5192379413aa23fff3fcfb2dfff25ff0fdd5ae62e07010100"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'f02e5044-b9e6-48ac-aaee-1cddaa3ebd90', - 'elapsed-time', - '236', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:18 GMT', - 'Content-Length', - '4917' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes.json b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes.json new file mode 100644 index 000000000000..d8f3368765fb --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes.json @@ -0,0 +1,3079 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e08c7866-04d3-4565-ab50-de4a14bf7e55" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:25 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e08c7866-04d3-4565-ab50-de4a14bf7e55", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "54b170ee-49b7-44a4-ad58-85dd60672001" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:25 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E7503CC1A984\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "54b170ee-49b7-44a4-ad58-85dd60672001", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7503CC1A984\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d988e1a9-6562-424d-a320-2cedcf15f8c2" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:25 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E7503CC5C7A1\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d988e1a9-6562-424d-a320-2cedcf15f8c2", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7503CC5C7A1\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e329cd0b-2d86-43b9-8959-7f3d525e318a" + }, + "RequestBody": { + "name": "hotel-live-test-1068467", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:25 GMT", + "elapsed-time": "700", + "ETag": "W/\u00220x8D9E7503D308792\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1068467\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e329cd0b-2d86-43b9-8959-7f3d525e318a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7503D308792\u0022", + "name": "hotel-live-test-1068467", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0fad2445-ed7b-43b6-b125-f604436e30ba" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "41518", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:30 GMT", + "elapsed-time": "234", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0fad2445-ed7b-43b6-b125-f604436e30ba", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes", + "value": [ + { + "@odata.etag": "\u00220x8D9E7503D308792\u0022", + "name": "hotel-live-test-1068467", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E29C78B084A8\u0022", + "name": "hotel-live-test1", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E29E4A44833F\u0022", + "name": "hotel-live-test2", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E2A14026D526\u0022", + "name": "hotel-live-test21297", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E2A14801B25E\u0022", + "name": "hotel-live-test22884", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E29B61E88EBC\u0022", + "name": "hotel-live-test3", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E2985986F248\u0022", + "name": "hotel-live-test322", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E2A0109ED0D0\u0022", + "name": "hotel-live-test420", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E29F20782150\u0022", + "name": "hotel-live-test688", + "defaultScoringProfile": null, + "fields": [ + { + "name": "hotelId", + "type": "Edm.String", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "hotelName", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "category", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "parkingIncluded", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastRenovationDate", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "rating", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "location", + "type": "Edm.GeographyPoint", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "address", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "streetAddress", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "city", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "stateProvince", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "country", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "postalCode", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "rooms", + "type": "Collection(Edm.ComplexType)", + "fields": [ + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "en.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "descriptionFr", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": "fr.lucene", + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "type", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "baseRate", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "bedOptions", + "type": "Edm.String", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "sleepsCount", + "type": "Edm.Int32", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "smokingAllowed", + "type": "Edm.Boolean", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + } + ], + "scoringProfiles": [ + { + "name": "nearest", + "functionAggregation": "sum", + "text": null, + "functions": [ + { + "fieldName": "location", + "interpolation": "linear", + "type": "distance", + "boost": 2.0, + "freshness": null, + "magnitude": null, + "distance": { + "referencePointParameter": "myloc", + "boostingDistance": 100.0 + }, + "tag": null + } + ] + } + ], + "corsOptions": { + "allowedOrigins": [ + "*" + ], + "maxAgeInSeconds": null + }, + "suggesters": [ + { + "name": "sg", + "searchMode": "analyzingInfixMatching", + "sourceFields": [ + "description", + "hotelName" + ] + } + ], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + }, + { + "@odata.etag": "\u00220x8D9E29F28587C0F\u0022", + "name": "hotel-live-test758", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1068467\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "fae13bbd-7c47-4dcc-ba37-7d2da3089721" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:30 GMT", + "elapsed-time": "134", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "fae13bbd-7c47-4dcc-ba37-7d2da3089721", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "2b9c23c9-a144-4233-b528-d18ab3f87677" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:34 GMT", + "elapsed-time": "14", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "2b9c23c9-a144-4233-b528-d18ab3f87677", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ab8ab7de-7579-45f2-ad33-e7bc0874a578" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:34 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "ab8ab7de-7579-45f2-ad33-e7bc0874a578", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1068467" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes_names.js b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes_names.js deleted file mode 100644 index 5ace86705407..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes_names.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "1b4fe2da28d70a753bc1115dbce11860"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get('/indexes') - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195eff71fa307f97375bcb6c91dff968f4d16556aef38f1e7def177f844f00b56af372bb2c2ef3ed265bacca7c1bf0ef7df44b463734d9bfb9c9fd9b9b7c7a739307034df0dd109ef8eee0fe5effdb555e9ff3b7bdaf1ad32793ccffbaceb392dec8da7c7b3ddc0a40f9c326abb39fce16d947bfe4fbbfe4ff01b8321fa2c7010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'cb28642d-8e97-4384-b4d1-85c4953a1c36', - 'elapsed-time', - '37', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:27 GMT', - 'Content-Length', - '295' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes_names.json b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes_names.json new file mode 100644 index 000000000000..0852c0fe48d9 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_gets_the_list_of_indexes_names.json @@ -0,0 +1,449 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "5521738c-900f-417e-9f14-e931c62ac885" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:34 GMT", + "elapsed-time": "8", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "5521738c-900f-417e-9f14-e931c62ac885", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e7311bfa-4854-4918-b1a6-538d2c4f139a" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:34 GMT", + "elapsed-time": "21", + "ETag": "W/\u00220x8D9E750424692B5\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e7311bfa-4854-4918-b1a6-538d2c4f139a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750424692B5\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "185a19ad-28bf-4545-8f4f-6ef9d21b0f25" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:34 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E750424A62BE\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "185a19ad-28bf-4545-8f4f-6ef9d21b0f25", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750424A62BE\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "27b40a18-c21a-4839-8a62-1943a28cef48" + }, + "RequestBody": { + "name": "hotel-live-test-1037349", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:34 GMT", + "elapsed-time": "671", + "ETag": "W/\u00220x8D9E75042B152AE\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1037349\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "27b40a18-c21a-4839-8a62-1943a28cef48", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E75042B152AE\u0022", + "name": "hotel-live-test-1037349", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "17107f4c-5d26-42da-ad52-09a2e5674fb6" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "374", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:39 GMT", + "elapsed-time": "26", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "17107f4c-5d26-42da-ad52-09a2e5674fb6", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes(name)", + "value": [ + { + "name": "hotel-live-test-1037349" + }, + { + "name": "hotel-live-test1" + }, + { + "name": "hotel-live-test2" + }, + { + "name": "hotel-live-test21297" + }, + { + "name": "hotel-live-test22884" + }, + { + "name": "hotel-live-test3" + }, + { + "name": "hotel-live-test322" + }, + { + "name": "hotel-live-test420" + }, + { + "name": "hotel-live-test688" + }, + { + "name": "hotel-live-test758" + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1037349\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "70d4b443-0a54-4e14-85cd-8aabd80f60f9" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:39 GMT", + "elapsed-time": "149", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "70d4b443-0a54-4e14-85cd-8aabd80f60f9", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "78b952fb-9b9a-4d24-a37b-6dfb2150d17a" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:43 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "78b952fb-9b9a-4d24-a37b-6dfb2150d17a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "5673d699-cd19-46d9-9d76-3e29e9d53c1e" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:43 GMT", + "elapsed-time": "11", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "5673d699-cd19-46d9-9d76-3e29e9d53c1e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1037349" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_modify_and_updates_the_index_object.js b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_modify_and_updates_the_index_object.js deleted file mode 100644 index 9243f42e3208..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_modify_and_updates_the_index_object.js +++ /dev/null @@ -1,107 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "519361aa90cd30f52b9baa528fb4cd71"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test3')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195eff71fa307f9737777fb77cd916edf5472303971a5c10d0dff7a39d77074f1f3eddbbf7e0e9c9fed3d39d27a7bfef47d46a992d72fa7a5eb579b95d1697f936babd47dfccf2f36c5db6afa7555d2c2f5ed6d5795152d3e5ba2c471f9d1779396b3e7af4bd5f6c2014337aa7bd5ee1f7d3d962fcbac56bf499a09d4df0f279563639de2edbbc0e3eaa736a9f5fca676dbda68f9aaa6ee56f6d739e4d6934fe276ff36bd39a0970bccccaeb1fe4b54153faee7e9a75fe5e56f5222b0bef93e67a592daf175f642b8cf1fbbf646487995de54db5c89779d33ccf2ff39206e80dfa69b5067a04803b0e70f5072d286f1cb3fced0d593ee0112bc41fd290677933ad8b555b544b1a9937dae8140b9afe6015db8da3d536de70f5939f93f1b6595136342e6fac27d56255e6efdee013c2b3c7fe2465de1b275559e653506c0b2f0ba1eed0f782ad8c5068f0ff3d4af9b49a17b359befc6e5e5ccc5b1a9e0e1f633e5bb6f7f6e823e935c0f4a621eb67ffaf1a337d142842fe78f4117dd67cc9a2411fe8abeb8b0b52a1794d9fa089e94cff747de9076df5365f76ff7ec624d24f887c75f041be9cd6d7dcebef050268bfc5a228b31acaff91b52a3a213ffe4531adaba63a6fc7c73f58d7f9f835d365fce48bbdfbafdd7b44d05d036e22bffc12029c2f32322a53fde0ff01f82fc1d9b2060000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237DC4DE0BE"', - 'Vary', - 'Accept-Encoding', - 'request-id', - '9c3b446d-0cbd-4aad-89c8-2720af8685b3', - 'elapsed-time', - '45', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:46:04 GMT', - 'Content-Length', - '663' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .put(`/indexes('hotel-live-test3')`, {"name":"hotel-live-test3","fields":[{"name":"id","type":"Edm.String","key":true,"retrievable":true,"searchable":false,"filterable":false,"sortable":false,"facetable":false,"analyzer":null,"searchAnalyzer":null,"indexAnalyzer":null,"normalizer":null,"synonymMaps":[]},{"name":"awesomenessLevel","type":"Edm.Double","key":false,"retrievable":true,"searchable":false,"filterable":true,"sortable":true,"facetable":true,"analyzer":null,"searchAnalyzer":null,"indexAnalyzer":null,"normalizer":null,"synonymMaps":[]},{"name":"description","type":"Edm.String","key":false,"retrievable":true,"searchable":true,"filterable":false,"sortable":false,"facetable":false,"analyzer":null,"searchAnalyzer":null,"indexAnalyzer":null,"normalizer":null,"synonymMaps":[]},{"name":"details","type":"Edm.ComplexType","fields":[{"name":"tags","type":"Collection(Edm.String)","key":false,"retrievable":true,"searchable":true,"filterable":false,"sortable":false,"facetable":false,"analyzer":null,"searchAnalyzer":null,"indexAnalyzer":null,"normalizer":null,"synonymMaps":[]}]},{"name":"hiddenWeight","type":"Edm.Int32","key":false,"retrievable":false,"searchable":false,"filterable":false,"sortable":false,"facetable":false,"analyzer":null,"searchAnalyzer":null,"indexAnalyzer":null,"normalizer":null,"synonymMaps":[]},{"name":"lastUpdatedOn","type":"Edm.DateTimeOffset","searchable":false,"filterable":true,"sortable":false,"facetable":false}],"scoringProfiles":[],"defaultScoringProfile":null,"corsOptions":null,"suggesters":[],"analyzers":[],"tokenizers":[],"tokenFilters":[],"charFilters":[],"normalizers":[],"encryptionKey":null,"similarity":{"@odata.type":"#Microsoft.Azure.Search.BM25Similarity","k1":null,"b":null},"semantic":null,"@odata.etag":"\"0x8D9D237DC4DE0BE\""}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195eff71fa307f9737777fb77cd916edf5472303971a5c10d0dff7a39d77074f1f3eddbbf7e0e9e9d3bdfb07c70f7fdf8fa8d5325be4f4f5bc6af372bb2c2ef36d747b8fbe99e5e7d9ba6c5f4fabba585ebcacabf3a2a4a6cb75598e3e3a2ff272d67cf4e87bbfd8402866f44e7bbdc2efa7b3c5f8758bd7e833413b9be0e5f3ac6c72bc5db6791d7c54e7d43ebf94cfda7a4d1f3555ddcadfdae63c9bd268fc4fdee6d7a63513e0789995d73fc86b83a6f4ddfd34ebfcbdacea455616de27cdf5b25a5e2fbec85618e3f77fc9c80e33bbca9b6a912ff3a6799e5fe6250dd01bf4d36a0df40800771ce0ea0f5a50de3866f9db1bb27cc02356883fa421cff2665a17abb6a89634326fb4d1291634fdc12ab61b47ab6dbce1ea273f27e36db3a26c685cde584faac5aaccdfbdc12784678ffd49cabc374eaab2cca7a0d8165e1642dda1ef055b19a1d0e0ff7b94f269352f66b37cf9ddbcb898b7343c1d3ec67cb66cefedd147d26b80e94d43d6cffedf346637e2326bdaaf56a45af3d9971d79784a1fbe2916f997e7e74d0e7248ef01c6fed8656a83a1cb47ff6f1af9f7e9a3c004f0c7a38fe8b3e64b560af481bebabeb820e391d7f4099a98cef44fd7977ed0566ff365f7ef674c20fd848857071fe4cb697dcdbdfe5e2080f65b2c8a32ab61f61e597baaf3f2e35f14d3ba6aaaf3767cfc83759d8f5f335dc64fbed8bbffdabd4704dd35e026f2cb2f21c0f92223733ad50ffe1fc57715eeac070000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237DED258A9"', - 'Vary', - 'Accept-Encoding', - 'request-id', - '16872f9b-fb13-4b49-91e8-7f3353f45491', - 'elapsed-time', - '125', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:46:04 GMT', - 'Content-Length', - '707' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('hotel-live-test3')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195eff71fa307f9737777fb77cd916edf5472303971a5c10d0dff7a39d77074f1f3eddbbf7e0e9e9d3bdfb07c70f7fdf8fa8d5325be4f4f5bc6af372bb2c2ef36d747b8fbe99e5e7d9ba6c5f4fabba585ebcacabf3a2a4a6cb75598e3e3a2ff272d67cf4e87bbfd8402866f44e7bbdc2efa7b3c5f8758bd7e833413b9be0e5f3ac6c72bc5db6791d7c54e7d43ebf94cfda7a4d1f3555ddcadfdae63c9bd268fc4fdee6d7a63513e0789995d73fc86b83a6f4ddfd34ebfcbdacea455616de27cdf5b25a5e2fbec85618e3f77fc9c80e33bbca9b6a912ff3a6799e5fe6250dd01bf4d36a0df40800771ce0ea0f5a50de3866f9db1bb27cc02356883fa421cff2665a17abb6a89634326fb4d1291634fdc12ab61b47ab6dbce1ea273f27e36db3a26c685cde584faac5aaccdfbdc12784678ffd49cabc374eaab2cca7a0d8165e1642dda1ef055b19a1d0e0ff7b94f269352f66b37cf9ddbcb898b7343c1d3ec67cb66cefedd147d26b80e94d43d6cffedf346637e2326bdaaf56a45af3d9971d79784a1fbe2916f997e7e74d0e7248ef01c6fed8656a83a1cb47ff6f1af9f7e9a3c004f0c7a38fe8b3e64b560af481bebabeb820e391d7f4099a98cef44fd7977ed0566ff365f7ef674c20fd848857071fe4cb697dcdbdfe5e2080f65b2c8a32ab61f61e597baaf3f2e35f14d3ba6aaaf3767cfc83759d8f5f335dc64fbed8bbffdabd4704dd35e026f2cb2f21c0f92223733ad50ffe1fc57715eeac070000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237DED258A9"', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'db8c3882-5950-4d9e-924f-5c40910e0863', - 'elapsed-time', - '20', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:46:04 GMT', - 'Content-Length', - '707' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_modify_and_updates_the_index_object.json b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_modify_and_updates_the_index_object.json new file mode 100644 index 000000000000..45be9e9d3ea3 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_modify_and_updates_the_index_object.json @@ -0,0 +1,930 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "2dfc27b9-bf68-457a-8848-a3689aa9a76e" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:10 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "2dfc27b9-bf68-457a-8848-a3689aa9a76e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "1b3c8054-4aa2-4dff-9913-00d0544b1fd2" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:10 GMT", + "elapsed-time": "23", + "ETag": "W/\u00220x8D9E750582B3F56\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "1b3c8054-4aa2-4dff-9913-00d0544b1fd2", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750582B3F56\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "1e2c0e13-9d9c-424b-a816-58bc774468a0" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:11 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E750582FD298\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "1e2c0e13-9d9c-424b-a816-58bc774468a0", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750582FD298\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "cb2914a8-cfdf-4296-8799-cea138bbb150" + }, + "RequestBody": { + "name": "hotel-live-test-1090490", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:11 GMT", + "elapsed-time": "594", + "ETag": "W/\u00220x8D9E7505889F32E\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1090490\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "cb2914a8-cfdf-4296-8799-cea138bbb150", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7505889F32E\u0022", + "name": "hotel-live-test-1090490", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1090490\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "60369beb-19e5-4db3-a4f2-dd970392861f" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:15 GMT", + "elapsed-time": "40", + "ETag": "W/\u00220x8D9E7505889F32E\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "60369beb-19e5-4db3-a4f2-dd970392861f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7505889F32E\u0022", + "name": "hotel-live-test-1090490", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1090490\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "1758", + "Content-Type": "application/json", + "Prefer": "return=representation", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8bc3de63-d84e-40aa-8a10-5f0f89613f0d" + }, + "RequestBody": { + "name": "hotel-live-test-1090490", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "retrievable": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": null, + "searchAnalyzer": null, + "indexAnalyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "key": false, + "retrievable": true, + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true, + "analyzer": null, + "searchAnalyzer": null, + "indexAnalyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "key": false, + "retrievable": true, + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": null, + "searchAnalyzer": null, + "indexAnalyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "key": false, + "retrievable": true, + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": null, + "searchAnalyzer": null, + "indexAnalyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "key": false, + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false, + "analyzer": null, + "searchAnalyzer": null, + "indexAnalyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastUpdatedOn", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "sortable": false, + "facetable": false + } + ], + "scoringProfiles": [], + "defaultScoringProfile": null, + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "normalizers": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null, + "@odata.etag": "\u00220x8D9E7505889F32E\u0022" + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "1945", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:15 GMT", + "elapsed-time": "165", + "ETag": "W/\u00220x8D9E7505B0F0639\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "8bc3de63-d84e-40aa-8a10-5f0f89613f0d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7505B0F0639\u0022", + "name": "hotel-live-test-1090490", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastUpdatedOn", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1090490\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "cdf45800-ddb6-4a86-a1fa-083c7c7348a0" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "1945", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:04:15 GMT", + "elapsed-time": "18", + "ETag": "W/\u00220x8D9E7505B0F0639\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "cdf45800-ddb6-4a86-a1fa-083c7c7348a0", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7505B0F0639\u0022", + "name": "hotel-live-test-1090490", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "lastUpdatedOn", + "type": "Edm.DateTimeOffset", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1090490\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "5732bbb9-99b0-4d41-8fd3-be2a101b524e" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:16 GMT", + "elapsed-time": "164", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "5732bbb9-99b0-4d41-8fd3-be2a101b524e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "87346a44-085c-478c-8ab2-c579d5a0620c" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:20 GMT", + "elapsed-time": "13", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "87346a44-085c-478c-8ab2-c579d5a0620c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "52b8a8e1-4e9d-46eb-ba07-dda0f6c6576a" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:20 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "52b8a8e1-4e9d-46eb-ba07-dda0f6c6576a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1090490" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_throws_error_for_invalid_index_object.js b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_throws_error_for_invalid_index_object.js deleted file mode 100644 index 8d50f13950eb..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_throws_error_for_invalid_index_object.js +++ /dev/null @@ -1,35 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "8fbfba173bf28395c6b1a5ab8885277c"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/indexes('garbxyz')`) - .query(true) - .reply(404, {"error":{"code":"","message":"No index with the name 'garbxyz' was found in the service 'testsearchcases'."}}, [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Language', - 'en', - 'Expires', - '-1', - 'request-id', - '10fa4297-9f6e-4990-a79c-6f81bb9b2902', - 'elapsed-time', - '20', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:45 GMT', - 'Content-Length', - '110' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_throws_error_for_invalid_index_object.json b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_throws_error_for_invalid_index_object.json new file mode 100644 index 000000000000..aae9299aa2a6 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_indexes/recording_throws_error_for_invalid_index_object.json @@ -0,0 +1,419 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "04366740-b021-4ce4-b366-7b6b7b3916ec" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:52 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "04366740-b021-4ce4-b366-7b6b7b3916ec", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e55117bf-bf1d-4b6b-af1b-03bff2603ba8" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:52 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E7504D081C37\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e55117bf-bf1d-4b6b-af1b-03bff2603ba8", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7504D081C37\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6686de7c-622a-4eab-841e-f97809a172c3" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:52 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E7504D0BEC35\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6686de7c-622a-4eab-841e-f97809a172c3", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7504D0BEC35\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "2b6fb379-7912-4c5b-843d-cbd41ff749ed" + }, + "RequestBody": { + "name": "hotel-live-test-1012590", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:52 GMT", + "elapsed-time": "628", + "ETag": "W/\u00220x8D9E7504D6B3C2D\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1012590\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "2b6fb379-7912-4c5b-843d-cbd41ff749ed", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7504D6B3C2D\u0022", + "name": "hotel-live-test-1012590", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027garbxyz\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d45fefc9-ed59-4552-8b8d-61ab4692c083" + }, + "RequestBody": null, + "StatusCode": 404, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Language": "en", + "Content-Length": "109", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:57 GMT", + "elapsed-time": "18", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d45fefc9-ed59-4552-8b8d-61ab4692c083", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "error": { + "code": "", + "message": "No index with the name \u0027garbxyz\u0027 was found in the service \u0027harshan-search\u0027." + } + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1012590\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "16c1527c-e74f-4db2-a137-224988a2aa18" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:57 GMT", + "elapsed-time": "159", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "16c1527c-e74f-4db2-a137-224988a2aa18", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "54d940dc-2413-4d5d-918a-048181fb1c45" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:01 GMT", + "elapsed-time": "14", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "54d940dc-2413-4d5d-918a-048181fb1c45", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "bc5f90a3-2e0d-4c9f-aa4e-f06cec70bbf5" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:04:01 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "bc5f90a3-2e0d-4c9f-aa4e-f06cec70bbf5", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1012590" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_creates_the_synonymmap_object_using_createorupdatesynonymmap.js b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_creates_the_synonymmap_object_using_createorupdatesynonymmap.js deleted file mode 100644 index 74b01eb13a1c..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_creates_the_synonymmap_object_using_createorupdatesynonymmap.js +++ /dev/null @@ -1,91 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "6a8f4d752b331e0e30fd48d901a6ac23"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .put(`/synonymmaps('my-azure-synonymmap-3')`, {"name":"my-azure-synonymmap-3","format":"solr","synonyms":"United States, United States of America => USA\nWashington, Wash. => WA"}) - .query(true) - .reply(201, {"@odata.context":"https://endpoint/$metadata#synonymmaps/$entity","@odata.etag":"\"0x8D9D237B7965604\"","name":"my-azure-synonymmap-3","format":"solr","synonyms":"United States, United States of America => USA\nWashington, Wash. => WA","encryptionKey":null}, [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237B7965604"', - 'Location', - "https://endpoint/synonymmaps('my-azure-synonymmap-3')?api-version=2021-04-30-Preview", - 'request-id', - '06bd1fe4-ad3e-4f31-81fe-370878e1a7d2', - 'elapsed-time', - '29', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:59 GMT', - 'Content-Length', - '284' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/synonymmaps('my-azure-synonymmap-3')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195efff1e67a592daf178b6cd5dcfdddf2655bb4d71f8d0c6c6a7441807fdf8f76de1d3c7df874efde83270f1e7e7affd39dfddff7236ab5cc16397dbdb8dece7eb0aef36d076bfb1e7d7d5ed58b0c88355559d3dffa75439f7cb52cda7c96be6e33427694067fa6d5797abcc8eb629aa59f1da55fbd3efe7d97dfcd9a79b1bc68abe528c5ef637cf3dd63029a2fa7f5f5aa2daae5ef955f7ff468b92ecb5ff2ff0070ea15c01c010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237B7965604"', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'bcb09cc4-023f-47d8-b442-f3065b362a16', - 'elapsed-time', - '10', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:59 GMT', - 'Content-Length', - '335' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .delete(`/synonymmaps('my-azure-synonymmap-3')`) - .query(true) - .reply(204, "", [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Expires', - '-1', - 'request-id', - 'a4b03dd3-5f1a-4bd7-80ad-66b4a0c5b0a5', - 'elapsed-time', - '16', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:59 GMT' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_creates_the_synonymmap_object_using_createorupdatesynonymmap.json b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_creates_the_synonymmap_object_using_createorupdatesynonymmap.json new file mode 100644 index 000000000000..a704d09b7e10 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_creates_the_synonymmap_object_using_createorupdatesynonymmap.json @@ -0,0 +1,491 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "9e37ea65-1de9-43b2-9fb4-cc8940cadf65" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:07 GMT", + "elapsed-time": "19", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "9e37ea65-1de9-43b2-9fb4-cc8940cadf65", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "79406a5d-0ee7-493f-b28e-e193232b986a" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:07 GMT", + "elapsed-time": "21", + "ETag": "W/\u00220x8D9E75032080E2D\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "79406a5d-0ee7-493f-b28e-e193232b986a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75032080E2D\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4347caef-61b7-48a0-a7ee-4f1de7c73ba7" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:07 GMT", + "elapsed-time": "30", + "ETag": "W/\u00220x8D9E750320D6496\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "4347caef-61b7-48a0-a7ee-4f1de7c73ba7", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750320D6496\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "1f939a88-aa1c-4c2a-9d16-14896cdbdaf4" + }, + "RequestBody": { + "name": "hotel-live-test-1030695", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:07 GMT", + "elapsed-time": "670", + "ETag": "W/\u00220x8D9E75032734344\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1030695\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "1f939a88-aa1c-4c2a-9d16-14896cdbdaf4", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E75032734344\u0022", + "name": "hotel-live-test-1030695", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-3\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "Prefer": "return=representation", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3d3ff583-6c37-44cb-b3d3-e87cfabdb115" + }, + "RequestBody": { + "name": "my-azure-synonymmap-3", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:11 GMT", + "elapsed-time": "26", + "ETag": "W/\u00220x8D9E75034DC94FD\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-3\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "3d3ff583-6c37-44cb-b3d3-e87cfabdb115", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75034DC94FD\u0022", + "name": "my-azure-synonymmap-3", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-3\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "9cb17c07-d00f-405a-bfcd-620827e36aa5" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:11 GMT", + "elapsed-time": "7", + "ETag": "W/\u00220x8D9E75034DC94FD\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "9cb17c07-d00f-405a-bfcd-620827e36aa5", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75034DC94FD\u0022", + "name": "my-azure-synonymmap-3", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-3\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "aa13419c-e703-4ef5-9abf-138665901e5f" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:11 GMT", + "elapsed-time": "10", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "aa13419c-e703-4ef5-9abf-138665901e5f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1030695\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "74427863-14c0-4a4c-b556-0bccf234a2a7" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:11 GMT", + "elapsed-time": "188", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "74427863-14c0-4a4c-b556-0bccf234a2a7", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "a01c7a14-c786-4dcf-8ea8-ca09e4e9023a" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:16 GMT", + "elapsed-time": "13", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "a01c7a14-c786-4dcf-8ea8-ca09e4e9023a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "8c546989-9b4b-4b6c-ab00-1b32806847f1" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:16 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "8c546989-9b4b-4b6c-ab00-1b32806847f1", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1030695" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_correct_synonymmap_object.js b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_correct_synonymmap_object.js deleted file mode 100644 index b1abe88a58b9..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_correct_synonymmap_object.js +++ /dev/null @@ -1,39 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "85be222d7e7fb0850e3f0eef01fa3d9b"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/synonymmaps('my-azure-synonymmap-1')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195efff1e67a592daf178b6cd5dcfdddf2655bb4d71f8d0c6c6a7441807fdf8f76de1d3c7df874efde83e3870f9e3c7978bcfbfb7e44ad96d922a7af17d7dbd90fd675beed606defd2d7e755bdc88058539535fdad5f37f4c957cba2cd67e9eb3623644769f0675a9da7c78bbc2ea659fad951fad5ebe3df77f9ddac9917cb8bb65a8e52fc3ec637df3d26a0f9725a5fafdaa25afe5ef9f5478f96ebb2fc25ff0f0af03d131c010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237A97BB9A1"', - 'Vary', - 'Accept-Encoding', - 'request-id', - '459df00f-ff9c-4d49-94cf-3238a37e225a', - 'elapsed-time', - '9', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:40 GMT', - 'Content-Length', - '334' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_correct_synonymmap_object.json b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_correct_synonymmap_object.json new file mode 100644 index 000000000000..c23daa371c55 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_correct_synonymmap_object.json @@ -0,0 +1,423 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "09456adf-7481-4495-ac11-1a77da7063a0" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:49 GMT", + "elapsed-time": "7", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "09456adf-7481-4495-ac11-1a77da7063a0", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "6be6f5e0-1136-4e2b-a079-c5d98fe4fa9b" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:49 GMT", + "elapsed-time": "21", + "ETag": "W/\u00220x8D9E75027417C88\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "6be6f5e0-1136-4e2b-a079-c5d98fe4fa9b", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75027417C88\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d7697754-fed8-4123-90bd-92221354fa19" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:49 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E7502745738C\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d7697754-fed8-4123-90bd-92221354fa19", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7502745738C\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4ecf5d4b-ea87-44ed-b18f-91e202419084" + }, + "RequestBody": { + "name": "hotel-live-test-1023067", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:49 GMT", + "elapsed-time": "759", + "ETag": "W/\u00220x8D9E75027B90BD7\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1023067\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "4ecf5d4b-ea87-44ed-b18f-91e202419084", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E75027B90BD7\u0022", + "name": "hotel-live-test-1023067", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e3cd1372-3924-4689-9329-1e2aa155cb97" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:53 GMT", + "elapsed-time": "9", + "ETag": "W/\u00220x8D9E75027417C88\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e3cd1372-3924-4689-9329-1e2aa155cb97", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75027417C88\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1023067\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "adf35fb0-3f8f-4a58-962b-0b8d97ef3fbb" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:53 GMT", + "elapsed-time": "170", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "adf35fb0-3f8f-4a58-962b-0b8d97ef3fbb", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ee6e9770-e6e6-4082-85e1-e0fa1d9993c8" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:58 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "ee6e9770-e6e6-4082-85e1-e0fa1d9993c8", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "9e5ee9a8-a152-4733-ba2c-04e4eee915ca" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:58 GMT", + "elapsed-time": "11", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "9e5ee9a8-a152-4733-ba2c-04e4eee915ca", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1023067" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps.js b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps.js deleted file mode 100644 index 6551e6b9be39..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "66734a1da7e1c7e96a463d9764e21e9c"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get('/synonymmaps') - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195efff1e67a592daf178b6cd57c34fae8322bd7f9478fbe67a153b30b02fdfb7eb4f3eee0e9c3a77bf71e3c3c7df0e4fea74f1efebe1f51fb65b6a0e61f2daeb7b31faceb7cdb41dbdea5afcfab7a9101b5a62a6bfa5bbf6ee893af96459bcfd2d76d46e88ed2e0cfb43a4f8f17795d4cb3f4b3a3f4abd7c7bfeff2bb59332f96176db51ca5f87d8c6fbe7b4c40f3e5b4be5eb545b5fcbdf2eb8f1e2dd765f94b461b0770b0777cf0f0e4a601ecd1d73f6703f8fe2ff97f0082a380bae1010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'ce219624-d322-4753-97df-b16fc5a5b5d1', - 'elapsed-time', - '19', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:22 GMT', - 'Content-Length', - '358' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps.json b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps.json new file mode 100644 index 000000000000..50d36e459a85 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps.json @@ -0,0 +1,433 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "57becd75-1e0a-49a7-bd72-fa0f53cde82c" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:30 GMT", + "elapsed-time": "151", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "57becd75-1e0a-49a7-bd72-fa0f53cde82c", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d7afd2e1-f45c-45c9-bcff-df5447a990c9" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:30 GMT", + "elapsed-time": "137", + "ETag": "W/\u00220x8D9E7501C6EDEC6\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d7afd2e1-f45c-45c9-bcff-df5447a990c9", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7501C6EDEC6\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0931b1b4-3180-4fb9-903f-d3e141f68e4f" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:30 GMT", + "elapsed-time": "22", + "ETag": "W/\u00220x8D9E7501C754672\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "0931b1b4-3180-4fb9-903f-d3e141f68e4f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7501C754672\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "454a26fe-a995-4ae3-b643-d4636a362494" + }, + "RequestBody": { + "name": "hotel-live-test-1013921", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:31 GMT", + "elapsed-time": "846", + "ETag": "W/\u00220x8D9E7501CF62331\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1013921\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "454a26fe-a995-4ae3-b643-d4636a362494", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7501CF62331\u0022", + "name": "hotel-live-test-1013921", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "9fbca217-cae6-493e-931c-7ed536d293b9" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "455", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:35 GMT", + "elapsed-time": "30", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "9fbca217-cae6-493e-931c-7ed536d293b9", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps", + "value": [ + { + "@odata.etag": "\u00220x8D9E7501C6EDEC6\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + }, + { + "@odata.etag": "\u00220x8D9E7501C754672\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1013921\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "0f185f42-1228-481f-a8c3-a42d54296778" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:36 GMT", + "elapsed-time": "156", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "0f185f42-1228-481f-a8c3-a42d54296778", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "dd368193-44e2-44a5-aa90-9bfef439de6a" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:40 GMT", + "elapsed-time": "19", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "dd368193-44e2-44a5-aa90-9bfef439de6a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "83444303-c0d1-4994-8dea-5b93d0a7d71d" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:40 GMT", + "elapsed-time": "21", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "83444303-c0d1-4994-8dea-5b93d0a7d71d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1013921" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps_names.js b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps_names.js deleted file mode 100644 index 558ba1c39326..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps_names.js +++ /dev/null @@ -1,37 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "538b9f7c59af4955f47057eddbbadea8"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get('/synonymmaps') - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195efff1e67a592daf178b6cd56c2db3457ee7a3d1479759b9ce3f7af4bd5ffc113e21c88bebedec07eb3adf76adb7773ffa25a38d0df63efa25dfff25ff0fc3457414a7000000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'cdf0bf0b-4681-4876-b387-dd0295f001de', - 'elapsed-time', - '138', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:31 GMT', - 'Content-Length', - '236' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps_names.json b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps_names.json new file mode 100644 index 000000000000..b257ce2ab9cf --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_gets_the_list_of_synonymmaps_names.json @@ -0,0 +1,425 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "67f8fd4c-c1f9-44b3-b1a9-08c9f2ae5d31" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:40 GMT", + "elapsed-time": "7", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "67f8fd4c-c1f9-44b3-b1a9-08c9f2ae5d31", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "02d007a3-147f-4011-9de3-b9533681520b" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:40 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E75021EC27D9\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "02d007a3-147f-4011-9de3-b9533681520b", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75021EC27D9\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4e9be8fd-7245-454b-82a2-1ef38323d57d" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:40 GMT", + "elapsed-time": "27", + "ETag": "W/\u00220x8D9E75021F10921\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "4e9be8fd-7245-454b-82a2-1ef38323d57d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75021F10921\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4742e7b2-0c33-44cb-a697-86e6bb121438" + }, + "RequestBody": { + "name": "hotel-live-test-1021864", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:40 GMT", + "elapsed-time": "652", + "ETag": "W/\u00220x8D9E75022545025\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1021864\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "4742e7b2-0c33-44cb-a697-86e6bb121438", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E75022545025\u0022", + "name": "hotel-live-test-1021864", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "e32737be-d0ce-4149-8ada-307979cb3b05" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "141", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:44 GMT", + "elapsed-time": "8", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "e32737be-d0ce-4149-8ada-307979cb3b05", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [ + { + "name": "my-azure-synonymmap-1" + }, + { + "name": "my-azure-synonymmap-2" + } + ] + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1021864\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f3bae67b-3525-4e2f-862c-449951553927" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:44 GMT", + "elapsed-time": "133", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "f3bae67b-3525-4e2f-862c-449951553927", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "f3a5ccf2-9587-4cda-b724-5df843afe547" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:49 GMT", + "elapsed-time": "13", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "f3a5ccf2-9587-4cda-b724-5df843afe547", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "ba06b41f-9485-47ff-a09f-fbf71daa3789" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:02:49 GMT", + "elapsed-time": "11", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "ba06b41f-9485-47ff-a09f-fbf71daa3789", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1021864" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_modify_and_updates_the_synonymmap_object.js b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_modify_and_updates_the_synonymmap_object.js deleted file mode 100644 index 02102000cb7e..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_modify_and_updates_the_synonymmap_object.js +++ /dev/null @@ -1,107 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "b43f30f7265158cc6e09ca580972fef2"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/synonymmaps('my-azure-synonymmap-1')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195efff1e67a592daf178b6cd5dcfdddf2655bb4d71f8d0c6c6a7441807fdf8f76de1d3c7df874efde8327c7f79eeced1decffbe1f51ab65b6c8e9ebc5f576f683759d6f3b58dbbbf4f579552f3220d654654d7febd70d7df2d5b268f359fabacd08d9511afc9956e7e9f122af8b69967e76947ef5faf8f75d7e376be6c5f2a2ad96a314bf8ff1cd778f0968be9cd6d7abb6a896bf577efdd1a3e5ba2c7fc9ff03048039951c010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237BA3B2284"', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'db36be00-8dc0-4202-abe5-e698aa1202ac', - 'elapsed-time', - '8', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:08 GMT', - 'Content-Length', - '334' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .put(`/synonymmaps('my-azure-synonymmap-1')`, {"name":"my-azure-synonymmap-1","format":"solr","synonyms":"United States, United States of America => USA\nWashington, Wash. => WA\nCalifornia, Clif. => CA","encryptionKey":null,"@odata.etag":"\"0x8D9D237BA3B2284\""}) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195efff1e67a592daf178b6cd5dcfdddf2655bb4d71f8d0c6c6a7441807fdf8f76de1d3c7df874efde83274f778f9fdd7bb8f7fb7e44ad96d922a7af17d7dbd90fd675beed606defd2d7e755bdc88058539535fdad5f37f4c957cba2cd67e9eb3623644769f0675a9da7c78bbc2ea659fad951fad5ebe3df77f9ddac9917cb8bb65a8e52fc3ec637dfa52f4eb2b2a07e9645364a4fe857fee2e4987acb97d3fa7ad516d5f2f7caaf3f7ab45c97e52ff97f00db4e622835010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237BD1AF392"', - 'Vary', - 'Accept-Encoding', - 'request-id', - 'dad934c3-3d1e-4747-bb84-751f1bbdff9c', - 'elapsed-time', - '21', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:08 GMT', - 'Content-Length', - '351' -]); - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/synonymmaps('my-azure-synonymmap-1')`) - .query(true) - .reply(200, ["1f8b0800000000000400edbd07601c499625262f6dca7b7f4af54ad7e074a10880601324d8904010ecc188cde692ec1d69472329ab2a81ca6556655d661640cced9dbcf7de7befbdf7de7befbdf7ba3b9d4e27f7dfff3f5c6664016cf6ce4adac99e2180aac81f3f7e7c1f3f227ef147bf6735cbda6c3cad966dfeaefde8d147f3b65d358feede6df3a66df2ac9ecea759933763f97d7c552c67d555335ee6eddddf6d91b7195efff1e67a592daf178b6cd5dcfdddf2655bb4d71f8d0c6c6a7441807fdf8f76de1d3c7df874efde83274f778f9fdd7bb8f7fb7e44ad96d922a7af17d7dbd90fd675beed606defd2d7e755bdc88058539535fdad5f37f4c957cba2cd67e9eb3623644769f0675a9da7c78bbc2ea659fad951fad5ebe3df77f9ddac9917cb8bb65a8e52fc3ec637dfa52f4eb2b2a07e9645364a4fe857fee2e4987acb97d3fa7ad516d5f2f7caaf3f7ab45c97e52ff97f00db4e622835010000"], [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Encoding', - 'gzip', - 'Expires', - '-1', - 'ETag', - 'W/"0x8D9D237BD1AF392"', - 'Vary', - 'Accept-Encoding', - 'request-id', - '66247263-cdf9-40d8-987c-ca168a92328d', - 'elapsed-time', - '8', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:45:08 GMT', - 'Content-Length', - '351' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_modify_and_updates_the_synonymmap_object.json b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_modify_and_updates_the_synonymmap_object.json new file mode 100644 index 000000000000..6b1d1e566c52 --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_modify_and_updates_the_synonymmap_object.json @@ -0,0 +1,508 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "5a3e8e15-702f-47d1-82ba-d4d3d425e634" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:16 GMT", + "elapsed-time": "6", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "5a3e8e15-702f-47d1-82ba-d4d3d425e634", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3415ae4d-ba3c-41a6-b604-dbcbd6b9f020" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:16 GMT", + "elapsed-time": "22", + "ETag": "W/\u00220x8D9E750376E7759\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "3415ae4d-ba3c-41a6-b604-dbcbd6b9f020", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750376E7759\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "59013a6b-ad7c-4ff0-918f-3b9007f8b76e" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:16 GMT", + "elapsed-time": "19", + "ETag": "W/\u00220x8D9E75037724762\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "59013a6b-ad7c-4ff0-918f-3b9007f8b76e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E75037724762\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "083cb115-3e2c-4c5f-b710-9f06da26657e" + }, + "RequestBody": { + "name": "hotel-live-test-1083550", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:16 GMT", + "elapsed-time": "595", + "ETag": "W/\u00220x8D9E75037CCB60C\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1083550\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "083cb115-3e2c-4c5f-b710-9f06da26657e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E75037CCB60C\u0022", + "name": "hotel-live-test-1083550", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "047b3415-c00b-43f0-bc4c-9d9187b6e819" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:20 GMT", + "elapsed-time": "8", + "ETag": "W/\u00220x8D9E750376E7759\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "047b3415-c00b-43f0-bc4c-9d9187b6e819", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E750376E7759\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "217", + "Content-Type": "application/json", + "Prefer": "return=representation", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "823c66d1-02d4-4769-81e4-f42095794407" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA\nCalifornia, Clif. =\u003E CA", + "encryptionKey": null, + "@odata.etag": "\u00220x8D9E750376E7759\u0022" + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "283", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:20 GMT", + "elapsed-time": "23", + "ETag": "W/\u00220x8D9E7503A385162\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "823c66d1-02d4-4769-81e4-f42095794407", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7503A385162\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA\nCalifornia, Clif. =\u003E CA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "046b525a-94d5-49f6-9492-3f3cd43ac027" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "283", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:20 GMT", + "elapsed-time": "7", + "ETag": "W/\u00220x8D9E7503A385162\u0022", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "046b525a-94d5-49f6-9492-3f3cd43ac027", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7503A385162\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA\nCalifornia, Clif. =\u003E CA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1083550\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "3010e840-7da9-4d39-b7b1-13b32c96fcef" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:20 GMT", + "elapsed-time": "136", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "3010e840-7da9-4d39-b7b1-13b32c96fcef", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "4edcb6ef-0e8d-4be6-ba53-babce404442e" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:25 GMT", + "elapsed-time": "21", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "4edcb6ef-0e8d-4be6-ba53-babce404442e", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "aacd1bd9-2851-4fe9-9af2-78bd21e0d9eb" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:25 GMT", + "elapsed-time": "11", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "aacd1bd9-2851-4fe9-9af2-78bd21e0d9eb", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1083550" + } +} diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_throws_error_for_invalid_synonymmap_object.js b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_throws_error_for_invalid_synonymmap_object.js deleted file mode 100644 index 5559cb2f0f15..000000000000 --- a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_throws_error_for_invalid_synonymmap_object.js +++ /dev/null @@ -1,35 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "ccf19b9f89fdf08aa10e008ef5a026e7"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} - -nock('https://endpoint:443', {"encodedQueryParams":true}) - .get(`/synonymmaps('garbxyz')`) - .query(true) - .reply(404, {"error":{"code":"","message":"No synonym map with the name 'garbxyz' was found in service 'testsearchcases'."}}, [ - 'Cache-Control', - 'no-cache', - 'Pragma', - 'no-cache', - 'Content-Type', - 'application/json; odata.metadata=minimal', - 'Content-Language', - 'en', - 'Expires', - '-1', - 'request-id', - 'd50208b9-0b42-4858-8fa9-93becfc6e9d1', - 'elapsed-time', - '160', - 'OData-Version', - '4.0', - 'Preference-Applied', - 'odata.include-annotations="*"', - 'Strict-Transport-Security', - 'max-age=15724800; includeSubDomains', - 'Date', - 'Fri, 07 Jan 2022 23:44:49 GMT', - 'Content-Length', - '112' -]); diff --git a/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_throws_error_for_invalid_synonymmap_object.json b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_throws_error_for_invalid_synonymmap_object.json new file mode 100644 index 000000000000..1a4c1dbd6f0e --- /dev/null +++ b/sdk/search/search-documents/recordings/node/searchindexclient_synonymmaps/recording_throws_error_for_invalid_synonymmap_object.json @@ -0,0 +1,419 @@ +{ + "Entries": [ + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview\u0026$select=name", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "890e637d-d262-473b-b887-b52f9c20443d" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Length": "76", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:58 GMT", + "elapsed-time": "8", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "890e637d-d262-473b-b887-b52f9c20443d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains", + "Vary": "Accept-Encoding" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps(name)", + "value": [] + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "1571585e-4c12-46df-943b-2d15d1186c6d" + }, + "RequestBody": { + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:58 GMT", + "elapsed-time": "20", + "ETag": "W/\u00220x8D9E7502CAA5648\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "1571585e-4c12-46df-943b-2d15d1186c6d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7502CAA5648\u0022", + "name": "my-azure-synonymmap-1", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "133", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "60350627-7189-44b6-a940-85e77a2a075f" + }, + "RequestBody": { + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA" + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "258", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:58 GMT", + "elapsed-time": "19", + "ETag": "W/\u00220x8D9E7502CADFF41\u0022", + "Expires": "-1", + "Location": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "60350627-7189-44b6-a940-85e77a2a075f", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#synonymmaps/$entity", + "@odata.etag": "\u00220x8D9E7502CADFF41\u0022", + "name": "my-azure-synonymmap-2", + "format": "solr", + "synonyms": "United States, United States of America =\u003E USA\nWashington, Wash. =\u003E WA", + "encryptionKey": null + } + }, + { + "RequestUri": "https://endpoint/indexes?api-version=2021-04-30-Preview", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "Content-Length": "707", + "Content-Type": "application/json", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "94f0b052-7043-4a48-a70c-a91110c8306d" + }, + "RequestBody": { + "name": "hotel-live-test-1048176", + "fields": [ + { + "name": "id", + "type": "Edm.String", + "key": true, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "sortable": true, + "facetable": true + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "retrievable": false, + "searchable": false, + "filterable": false, + "sortable": false, + "facetable": false + } + ] + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1695", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:02:58 GMT", + "elapsed-time": "593", + "ETag": "W/\u00220x8D9E7502D081FDA\u0022", + "Expires": "-1", + "Location": "https://endpoint/indexes(\u0027hotel-live-test-1048176\u0027)?api-version=2021-04-30-Preview", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "94f0b052-7043-4a48-a70c-a91110c8306d", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "@odata.context": "https://endpoint/$metadata#indexes/$entity", + "@odata.etag": "\u00220x8D9E7502D081FDA\u0022", + "name": "hotel-live-test-1048176", + "defaultScoringProfile": null, + "fields": [ + { + "name": "id", + "type": "Edm.String", + "searchable": false, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": true, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "awesomenessLevel", + "type": "Edm.Double", + "searchable": false, + "filterable": true, + "retrievable": true, + "sortable": true, + "facetable": true, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "description", + "type": "Edm.String", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + }, + { + "name": "details", + "type": "Edm.ComplexType", + "fields": [ + { + "name": "tags", + "type": "Collection(Edm.String)", + "searchable": true, + "filterable": false, + "retrievable": true, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ] + }, + { + "name": "hiddenWeight", + "type": "Edm.Int32", + "searchable": false, + "filterable": false, + "retrievable": false, + "sortable": false, + "facetable": false, + "key": false, + "indexAnalyzer": null, + "searchAnalyzer": null, + "analyzer": null, + "normalizer": null, + "synonymMaps": [] + } + ], + "scoringProfiles": [], + "corsOptions": null, + "suggesters": [], + "analyzers": [], + "normalizers": [], + "tokenizers": [], + "tokenFilters": [], + "charFilters": [], + "encryptionKey": null, + "similarity": { + "@odata.type": "#Microsoft.Azure.Search.BM25Similarity", + "k1": null, + "b": null + }, + "semantic": null + } + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027garbxyz\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "d9155f33-7149-451f-891b-abe5194c654a" + }, + "RequestBody": null, + "StatusCode": 404, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Language": "en", + "Content-Length": "111", + "Content-Type": "application/json; odata.metadata=minimal", + "Date": "Thu, 03 Feb 2022 20:03:02 GMT", + "elapsed-time": "10", + "Expires": "-1", + "OData-Version": "4.0", + "Pragma": "no-cache", + "Preference-Applied": "odata.include-annotations=\u0022*\u0022", + "request-id": "d9155f33-7149-451f-891b-abe5194c654a", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": { + "error": { + "code": "", + "message": "No synonym map with the name \u0027garbxyz\u0027 was found in service \u0027harshan-search\u0027." + } + } + }, + { + "RequestUri": "https://endpoint/indexes(\u0027hotel-live-test-1048176\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "390d62e9-c1ba-4af3-aa72-50aa00372b72" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:02 GMT", + "elapsed-time": "195", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "390d62e9-c1ba-4af3-aa72-50aa00372b72", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-1\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "7e30331c-3b9b-422d-9065-f51e31af0898" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:07 GMT", + "elapsed-time": "12", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "7e30331c-3b9b-422d-9065-f51e31af0898", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://endpoint/synonymmaps(\u0027my-azure-synonymmap-2\u0027)?api-version=2021-04-30-Preview", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json;odata.metadata=minimal", + "Accept-Encoding": "gzip,deflate", + "api-key": "admin_key", + "Connection": "keep-alive", + "User-Agent": "azsdk-js-search-documents/11.3.0-beta.6 azsdk-js-search-documents/11.3.0-beta.6 core-rest-pipeline/1.5.0 Node/v14.17.6 OS/(x64-Linux-5.4.0-1067-azure)", + "x-ms-client-request-id": "98400c0d-0198-4334-a4d7-fb0a339804e4" + }, + "RequestBody": null, + "StatusCode": 204, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Date": "Thu, 03 Feb 2022 20:03:07 GMT", + "elapsed-time": "11", + "Expires": "-1", + "Pragma": "no-cache", + "request-id": "98400c0d-0198-4334-a4d7-fb0a339804e4", + "Strict-Transport-Security": "max-age=15724800; includeSubDomains" + }, + "ResponseBody": null + } + ], + "Variables": { + "TEST_INDEX_NAME": "hotel-live-test-1048176" + } +} diff --git a/sdk/search/search-documents/test/public/node/searchClient.spec.ts b/sdk/search/search-documents/test/public/node/searchClient.spec.ts index f3529f160498..06cff08e806f 100644 --- a/sdk/search/search-documents/test/public/node/searchClient.spec.ts +++ b/sdk/search/search-documents/test/public/node/searchClient.spec.ts @@ -4,9 +4,9 @@ import { assert } from "chai"; import { Context } from "mocha"; import { Suite } from "mocha"; -import { Recorder, record, isPlaybackMode, isLiveMode } from "@azure-tools/test-recorder"; +import { Recorder } from "@azure-tools/test-recorder"; -import { createClients, environmentSetup } from "../utils/recordedClient"; +import { createClients } from "../utils/recordedClient"; import { SearchClient, SearchIndexClient, @@ -17,40 +17,38 @@ import { AzureKeyCredential, } from "../../../src"; import { Hotel } from "../utils/interfaces"; -import { createIndex, populateIndex, WAIT_TIME, createRandomIndexName } from "../utils/setup"; +import { createIndex, createRandomIndexName, populateIndex, WAIT_TIME } from "../utils/setup"; import { delay, serviceVersions } from "../../../src/serviceUtils"; import { versionsToTest } from "@azure/test-utils"; -const TEST_INDEX_NAME = isLiveMode() ? createRandomIndexName() : "hotel-live-test1"; - versionsToTest(serviceVersions, {}, (serviceVersion, onVersions) => { onVersions({ minVer: "2020-06-30" }).describe("SearchClient tests", function (this: Suite) { let recorder: Recorder; let searchClient: SearchClient; let indexClient: SearchIndexClient; + let TEST_INDEX_NAME: string; this.timeout(99999); beforeEach(async function (this: Context) { - ({ searchClient, indexClient } = createClients(TEST_INDEX_NAME, serviceVersion)); - if (!isPlaybackMode()) { - await createIndex(indexClient, TEST_INDEX_NAME); - await delay(WAIT_TIME); - await populateIndex(searchClient); - } - recorder = record(this, environmentSetup); - // create the clients again, but hooked up to the recorder - ({ searchClient, indexClient } = createClients(TEST_INDEX_NAME, serviceVersion)); + recorder = new Recorder(this.currentTest); + TEST_INDEX_NAME = createRandomIndexName(); + ({ + searchClient, + indexClient, + indexName: TEST_INDEX_NAME, + } = await createClients(serviceVersion, recorder, TEST_INDEX_NAME)); + await createIndex(indexClient, TEST_INDEX_NAME); + await delay(WAIT_TIME); + await populateIndex(searchClient); }); afterEach(async function () { + await indexClient.deleteIndex(TEST_INDEX_NAME); + await delay(WAIT_TIME); if (recorder) { await recorder.stop(); } - if (!isPlaybackMode()) { - await indexClient.deleteIndex(TEST_INDEX_NAME); - await delay(WAIT_TIME); - } }); it("count returns the correct document count", async function () { diff --git a/sdk/search/search-documents/test/public/node/searchIndexClient.spec.ts b/sdk/search/search-documents/test/public/node/searchIndexClient.spec.ts index 505385a4baad..a6d404e581d0 100644 --- a/sdk/search/search-documents/test/public/node/searchIndexClient.spec.ts +++ b/sdk/search/search-documents/test/public/node/searchIndexClient.spec.ts @@ -1,13 +1,13 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT license. -import { isPlaybackMode, record, Recorder, isLiveMode } from "@azure-tools/test-recorder"; +import { Recorder, isLiveMode } from "@azure-tools/test-recorder"; import { Context } from "mocha"; import { Suite } from "mocha"; import { assert } from "chai"; import { SearchIndexClient, SynonymMap, SearchIndex } from "../../../src"; import { Hotel } from "../utils/interfaces"; -import { createClients, environmentSetup } from "../utils/recordedClient"; +import { createClients } from "../utils/recordedClient"; import { createSimpleIndex, createSynonymMaps, @@ -18,36 +18,35 @@ import { import { delay, serviceVersions } from "../../../src/serviceUtils"; import { versionsToTest } from "@azure/test-utils"; -const TEST_INDEX_NAME = isLiveMode() ? createRandomIndexName() : "hotel-live-test3"; - versionsToTest(serviceVersions, {}, (serviceVersion, onVersions) => { onVersions({ minVer: "2020-06-30" }).describe("SearchIndexClient", function (this: Suite) { let recorder: Recorder; let indexClient: SearchIndexClient; + let TEST_INDEX_NAME: string; this.timeout(99999); beforeEach(async function (this: Context) { - ({ indexClient } = createClients(TEST_INDEX_NAME, serviceVersion)); - if (!isPlaybackMode()) { - await createSynonymMaps(indexClient); - await createSimpleIndex(indexClient, TEST_INDEX_NAME); - await delay(WAIT_TIME); - } - recorder = record(this, environmentSetup); - // create the clients again, but hooked up to the recorder - ({ indexClient } = createClients(TEST_INDEX_NAME, serviceVersion)); + recorder = new Recorder(this.currentTest); + TEST_INDEX_NAME = createRandomIndexName(); + ({ indexClient, indexName: TEST_INDEX_NAME } = await createClients( + serviceVersion, + recorder, + TEST_INDEX_NAME + )); + + await createSynonymMaps(indexClient); + await createSimpleIndex(indexClient, TEST_INDEX_NAME); + await delay(WAIT_TIME); }); afterEach(async function () { + await indexClient.deleteIndex(TEST_INDEX_NAME); + await delay(WAIT_TIME); + await deleteSynonymMaps(indexClient); if (recorder) { await recorder.stop(); } - if (!isPlaybackMode()) { - await indexClient.deleteIndex(TEST_INDEX_NAME); - await delay(WAIT_TIME); - await deleteSynonymMaps(indexClient); - } }); describe("#synonymmaps", function () { diff --git a/sdk/search/search-documents/test/public/utils/recordedClient.ts b/sdk/search/search-documents/test/public/utils/recordedClient.ts index 3d6253396cc9..df5b6cf64314 100644 --- a/sdk/search/search-documents/test/public/utils/recordedClient.ts +++ b/sdk/search/search-documents/test/public/utils/recordedClient.ts @@ -3,7 +3,7 @@ import * as dotenv from "dotenv"; -import { env, RecorderEnvironmentSetup } from "@azure-tools/test-recorder"; +import { env, Recorder, RecorderStartOptions } from "@azure-tools/test-recorder"; import { AzureKeyCredential, @@ -26,41 +26,33 @@ export interface Clients { searchClient: SearchClient; indexClient: SearchIndexClient; indexerClient: SearchIndexerClient; + indexName: string; } -const replaceableVariables: { [k: string]: string } = { +const envSetupForPlayback: { [k: string]: string } = { SEARCH_API_ADMIN_KEY: "admin_key", SEARCH_API_ADMIN_KEY_ALT: "admin_key_alt", ENDPOINT: "https://endpoint", }; -export const testEnv = new Proxy(replaceableVariables, { +export const testEnv = new Proxy(envSetupForPlayback, { get: (target, key: string) => { return env[key] || target[key]; }, }); -export const environmentSetup: RecorderEnvironmentSetup = { - replaceableVariables, - customizationsOnRecordings: [ - (recording: string): string => - recording.replace(/"access_token"\s?:\s?"[^"]*"/g, `"access_token":"access_token"`), - // If we put ENDPOINT in replaceableVariables above, it will not capture - // the endpoint string used with nock, which will be expanded to - // https://:443/ and therefore will not match, so we have to do - // this instead. - (recording: string): string => { - const match = testEnv.ENDPOINT.replace(/^https:\/\//, "").replace(/\/$/, ""); - return recording.replace(match, "endpoint"); - }, - ], - queryParametersToSkip: [], +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback, }; -export function createClients( - indexName: string, - serviceVersion: string -): Clients { +export async function createClients( + serviceVersion: string, + recorder: Recorder, + indexName: string +): Promise> { + await recorder.start(recorderOptions); + + indexName = recorder.variable("TEST_INDEX_NAME", indexName); const endPoint: string = process.env.ENDPOINT ?? "https://endpoint"; const credential = new AzureKeyCredential(testEnv.SEARCH_API_ADMIN_KEY); const searchClient = new SearchClient(endPoint, indexName, credential, { @@ -73,9 +65,14 @@ export function createClients( serviceVersion, }); + recorder.configureClient(searchClient["client"]); + recorder.configureClient(indexClient["client"]); + recorder.configureClient(indexerClient["client"]); + return { searchClient, indexClient, indexerClient, + indexName, }; } diff --git a/sdk/search/search-documents/test/public/utils/setup.ts b/sdk/search/search-documents/test/public/utils/setup.ts index e0ae80674eff..26256d620434 100644 --- a/sdk/search/search-documents/test/public/utils/setup.ts +++ b/sdk/search/search-documents/test/public/utils/setup.ts @@ -12,8 +12,9 @@ import { import { Hotel } from "./interfaces"; import { delay } from "../../../src/serviceUtils"; import { assert } from "chai"; +import { isPlaybackMode } from "@azure-tools/test-recorder"; -export const WAIT_TIME = 4000; +export const WAIT_TIME = isPlaybackMode() ? 0 : 4000; // eslint-disable-next-line @azure/azure-sdk/ts-use-interface-parameters export async function createIndex(client: SearchIndexClient, name: string): Promise { @@ -624,5 +625,5 @@ export async function createSimpleIndex(client: SearchIndexClient, name: string) } export function createRandomIndexName(): string { - return `hotel-live-test${Math.floor(Math.random() * 1000) + 1}`; + return `hotel-live-test-${Math.floor(Math.random() * 100000) + 1000000}`; }