Skip to content

Commit

Permalink
Add new unquarantine procedure + deprecate quarantine
Browse files Browse the repository at this point in the history
  • Loading branch information
Frannie-Ludmilla committed Nov 25, 2024
1 parent 5a69402 commit b61d288
Showing 1 changed file with 40 additions and 1 deletion.
41 changes: 40 additions & 1 deletion modules/ROOT/pages/procedures.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -1105,7 +1105,7 @@ For more information, see the link:{neo4j-docs-base-uri}/cypher-manual/{page-ver
| *Mode* 3+| WRITE
|===

[role=label--enterprise-edition label--admin-only]
[role=label--enterprise-edition label--admin-only label--deprecated-2025.01]
[[procedure_dbms_quarantineDatabase]]
=== dbms.quarantineDatabase()

Expand All @@ -1125,6 +1125,38 @@ For more information, see the link:{neo4j-docs-base-uri}/cypher-manual/{page-ver
| *Mode* 3+| DBMS
|===


[role=label--enterprise-edition label--admin-only]
[[procedure_dbms_unquarantineDatabase]]
=== dbms.unquarantineDatabase()


.Details
|===
| *Syntax* 3+m| dbms.unquarantineDatabase(server, databaseName, operation) :: ()
| *Description* 3+a| Remove the quarantine status from a database in a server performing a cleanup `operation`.
The possible values for the cleanup operation are:

* `keepStateKeepStore` -- do nothing, leave store and cluster state as it is,
* `replaceStateKeepStore` -- join as a new member clearing the current cluster state but keeping the store
* `replaceStateReplaceStore` -- join as a new member clearing both the current cluster state and the store
.4+| *Input arguments* | *Name* | *Type* | *Description*
| `server` | `STRING` | The name or the id of the server where there is the quarantined database.
| `databaseName` | `STRING` | The name of the database whose quarantine status must be removed.
| `operation` | `STRING` | Select a cleanup operation to perform while removing the quarantine.
| *Mode* 3+| DBMS
|===

[NOTE]
====
If you choose to clear the current cluster state, the server will try to join as a new member,
but this joining can succeed if and only if there is a majority of old members "letting" the
new members in. Let's assume our cluster has a topology with three primaries. If there is only one server
in `QUARANTINED` mode, then it is safe to choose `replaceStateKeepStore` or `replaceStateReplaceStore`.
If there are two servers in `QUARANTINED` mode, then you should not use concurrently `replaceStateKeepStore` or
`replaceStateReplaceStore` for both servers because there would be no majority to let them in.
====

[role=label--admin-only label--deprecated-5.9]
[[procedure_dbms_upgrade]]
=== dbms.upgrade()
Expand Down Expand Up @@ -1974,6 +2006,13 @@ Replaced by: xref:procedures.adoc#procedure_dbms_routing_getroutingtable[`dbms.r
Before Neo4j 5.23, the procedure can be run only with the `Admin` privileges. +
Replaced by xref:clustering/server-syntax.adoc#server-management-syntax[`ENABLE SERVER`].
// New in v6
| xref:procedures.adoc#procedure_dbms_quarantineDatabase[`dbms.quarantineDatabase()`]
| label:no[]
| label:yes[]
| label:admin-only[] label:deprecated[Deprecated in 2025.01] +
Replaced by procedures.adoc#procedure_dbms_unquarantineDatabase[`dbms.unquarantineDatabase()`]
| xref:procedures.adoc#procedure_dbms_setDatabaseAllocator[`dbms.setDatabaseAllocator()`]
| label:no[]
| label:yes[]
Expand Down

0 comments on commit b61d288

Please sign in to comment.