diff --git a/db/attachment_test.go b/db/attachment_test.go index dbac0a520c..1bfcaa3589 100644 --- a/db/attachment_test.go +++ b/db/attachment_test.go @@ -875,7 +875,7 @@ func TestMigrateBodyAttachments(t *testing.T) { defer db.Close(ctx) collection, ctx := GetSingleDatabaseCollectionWithUser(ctx, t, db) - // Update the doc with a the same body as rev 3-a, and make sure attachments are migrated. + // Update the doc with the same body as rev 3-a, and make sure attachments are migrated. newBody := Body{ "test": true, BodyRev: "3-a", diff --git a/docs/api/components/schemas.yaml b/docs/api/components/schemas.yaml index 99ff876a04..f6492b3111 100644 --- a/docs/api/components/schemas.yaml +++ b/docs/api/components/schemas.yaml @@ -697,7 +697,7 @@ Retrieved-replication: - localWins - custom custom_conflict_resolver: - description: "This specifies the Javascript function to use to resolve conflicts between conflicting revisions.\n \nThis **must** be used when `conflict_resolution_type=custom`. This property will be ignored when `conflict_resolution_type` is not `custom`.\n\nThe Javascript function to provide this property should be in backticks (like the sync function). The function takes 1 parameter which is a struct that represents the conflict. This struct has 2 properties:\n* `LocalDocument` - The local document. This contains the document ID under the `_id` key.\n* `RemoteDocument` - The remote document\nThe function should return the new documents body. This can be the winning revision (for example, `return conflict.LocalDocument`), a new body, or `nil` to resolve as a delete.\n\nExample:\n```\n\"custom_conflict_resolver\":\\`\n\tfunction(conflict) {\n\t\tconsole.log(\"Doc ID: \"+conflict.LocalDocument._id);\n\t\tconsole.log(\"Full remote doc: \"+JSON.stringify(conflict.RemoteDocument));\n\t\treturn conflict.RemoteDocument;\n\t}\n\\`\n```\n\nUsing complex `custom_conflict_resolver` functions can noticeably degrade performance. Use a built-in resolver whenever possible.\n\nThis is an Enterprise Edition only feature.\n" + description: "This specifies the Javascript function to use to resolve conflicts between conflicting revisions.\n \nThis **must** be used when `conflict_resolution_type=custom`. This property will be ignored when `conflict_resolution_type` is not `custom`.\n\nThe Javascript function to provide this property should be in backticks (like the sync function). The function takes 1 parameter which is a struct that represents the conflict. This struct has 2 properties:\n* `LocalDocument` - The local document. This contains the document ID under the `_id` key.\n* `RemoteDocument` - The remote document\nThe function should return the new document's body. This can be the winning revision (for example, `return conflict.LocalDocument`), a new body, or `nil` to resolve as a delete.\n\nExample:\n```\n\"custom_conflict_resolver\":\\`\n\tfunction(conflict) {\n\t\tconsole.log(\"Doc ID: \"+conflict.LocalDocument._id);\n\t\tconsole.log(\"Full remote doc: \"+JSON.stringify(conflict.RemoteDocument));\n\t\treturn conflict.RemoteDocument;\n\t}\n\\`\n```\n\nUsing complex `custom_conflict_resolver` functions can noticeably degrade performance. Use a built-in resolver whenever possible.\n\nThis is an Enterprise Edition only feature.\n" type: string default: none purge_on_removal: @@ -925,7 +925,7 @@ Replication: - localWins - custom custom_conflict_resolver: - description: "This specifies the Javascript function to use to resolve conflicts between conflicting revisions.\n \nThis **must** be used when `conflict_resolution_type=custom`. This property will be ignored when `conflict_resolution_type` is not `custom`.\n\nThe Javascript function to provide this property should be in backticks (like the sync function). The function takes 1 parameter which is a struct that represents the conflict. This struct has 2 properties:\n* `LocalDocument` - The local document. This contains the document ID under the `_id` key.\n* `RemoteDocument` - The remote document\nThe function should return the new documents body. This can be the winning revision (for example, `return conflict.LocalDocument`), a new body, or `nil` to resolve as a delete.\n\nExample:\n```\n\"custom_conflict_resolver\":\\`\n\tfunction(conflict) {\n\t\tconsole.log(\"Doc ID: \"+conflict.LocalDocument._id);\n\t\tconsole.log(\"Full remote doc: \"+JSON.stringify(conflict.RemoteDocument));\n\t\treturn conflict.RemoteDocument;\n\t}\n\\`\n```\n\nUsing complex `custom_conflict_resolver` functions can noticeably degrade performance. Use a built-in resolver whenever possible.\n\nThis is an Enterprise Edition only feature.\n" + description: "This specifies the Javascript function to use to resolve conflicts between conflicting revisions.\n \nThis **must** be used when `conflict_resolution_type=custom`. This property will be ignored when `conflict_resolution_type` is not `custom`.\n\nThe Javascript function to provide this property should be in backticks (like the sync function). The function takes 1 parameter which is a struct that represents the conflict. This struct has 2 properties:\n* `LocalDocument` - The local document. This contains the document ID under the `_id` key.\n* `RemoteDocument` - The remote document\nThe function should return the new document's body. This can be the winning revision (for example, `return conflict.LocalDocument`), a new body, or `nil` to resolve as a delete.\n\nExample:\n```\n\"custom_conflict_resolver\":\\`\n\tfunction(conflict) {\n\t\tconsole.log(\"Doc ID: \"+conflict.LocalDocument._id);\n\t\tconsole.log(\"Full remote doc: \"+JSON.stringify(conflict.RemoteDocument));\n\t\treturn conflict.RemoteDocument;\n\t}\n\\`\n```\n\nUsing complex `custom_conflict_resolver` functions can noticeably degrade performance. Use a built-in resolver whenever possible.\n\nThis is an Enterprise Edition only feature.\n" type: string default: none purge_on_removal: diff --git a/docs/api/paths/admin/db-_compact.yaml b/docs/api/paths/admin/db-_compact.yaml index 49c2b54543..6342e53241 100644 --- a/docs/api/paths/admin/db-_compact.yaml +++ b/docs/api/paths/admin/db-_compact.yaml @@ -25,7 +25,7 @@ post: - $ref: ../../components/parameters.yaml#/compact-type - name: action in: query - description: Defines whether the a compact operation is being started or stopped. + description: Defines whether the compact operation is being started or stopped. schema: type: string default: start diff --git a/docs/api/paths/admin/keyspace-_raw-docid.yaml b/docs/api/paths/admin/keyspace-_raw-docid.yaml index b7b9638aea..11c48b078c 100644 --- a/docs/api/paths/admin/keyspace-_raw-docid.yaml +++ b/docs/api/paths/admin/keyspace-_raw-docid.yaml @@ -11,7 +11,7 @@ parameters: get: summary: Get a document with the corresponding metadata description: |- - Returns the a documents latest revision with its metadata. + Returns a document's latest revision with its metadata. Note: The direct use of this endpoint is unsupported. The sync metadata is maintained internally by Sync Gateway and its structure can change. It should not be used to drive business logic of applications since the response to the `/{db}/_raw/{id}` endpoint can change at any time. @@ -23,7 +23,7 @@ get: - $ref: ../../components/parameters.yaml#/include_doc - name: redact in: query - description: This redacts sensitive parts of the response. Cannot be used when `include_docs=true` + description: This redacts sensitive parts of the response. Cannot be used when `include_doc=true` schema: type: boolean responses: @@ -72,7 +72,7 @@ get: description: The document CAS (Concurrent Document Mutations) number used for document locking. type: string value_crc32c: - description: The documents CRC32 number. + description: The document's CRC32 number. type: string channel_set: description: The channels the document has been in.