Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 37 additions & 1 deletion modules/manage/pages/manage-settings/query-ui-settings.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ If a query uses a sequential scan and a data node becomes unavailable, the query

== Query Optimization

Configure rules for cost optimizer behavior and replica usage.
Configure rules for cost optimizer behavior.

[cols="1,2,1",options="header"]
|===
Expand All @@ -190,6 +190,42 @@ a| Determines whether to use the xref:n1ql:n1ql-language-reference/cost-based-op
| Selected (Enabled)
|===

== Plan Stability
[.status]#Couchbase Server 8.5#

Configure the mode and error policy for xref:n1ql:n1ql-manage/query-plan-stability.adoc[Query Plan Stability].

[cols="1,2,1",options="header"]
|===
| Setting | Description | Default Value

| *Plan Stability*

a| Controls whether the Query Service saves execution plans to disk, and for which statement types.

Select 1 of the following:

* `Off`: Does not save execution plans to disk.
* `On Prepared Statements`: Saves execution plans to disk for all prepared statements.
* `On All Statements`: Saves execution plans to disk for all queries, including prepared statements and ad-hoc queries.

| `Off`

| *Plan Stability Error Policy*

a| Controls how the Query Service handles a query when a saved plan is unavailable.

Select 1 of the following:

* `Strict`: Stops execution and returns the error to the application.
* `Moderate`: Generates a new plan to execute the statement, but keeps the original saved plan.
* `Flexible`: Generates a new plan to execute the statement and overwrites the saved plan with the new one.

For more information, see xref:n1ql:n1ql-manage/query-plan-stability.adoc#error-policies[Error Policies].

| `Moderate` (Greyed out if *Plan Stability* is `Off`)
|===

== Query Settings via CLI

You can set all of the cluster-level query settings, except for the CURL access control settings, using the xref:cli:cbcli/couchbase-cli-setting-query.adoc[setting-query] command.
Expand Down
27 changes: 27 additions & 0 deletions preview/DOC-14217-add-plan-stability-settings.yml

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Delete before merging!

Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
sources:
docs-devex:
branches: DOC-14217-query-plan-stability

# docs-analytics:
# branches: release/8.0

couchbase-cli:
url: https://github.com/couchbaselabs/couchbase-cli-doc
branches: master
startPaths: docs/

# backup:
# branches: master
# startPaths: docs/

cb-swagger:
url: https://github.com/couchbaselabs/cb-swagger
branches: release/8.5
start_path: docs

# Minimal SDK build
# docs-sdk-common:
# branches: [release/8.0]
# docs-sdk-java:
# branches: [3.11]