Skip to content

Commit 0ebd3b5

Browse files
authored
Documentation fixes (#1236)
Standardizes the usage of the link tag in deprecation messages. Adds a note concerning the use of CALL {} IN TRANSACTIONS in explicit transactions
1 parent 291df7e commit 0ebd3b5

File tree

9 files changed

+33
-17
lines changed

9 files changed

+33
-17
lines changed

packages/core/src/client-certificate.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ export default class ClientCertificate {
7474
/**
7575
* Provides a client certificate to the driver for mutual TLS.
7676
*
77-
* The driver will call {@link ClientCertificateProvider#hasUpdate()} to check if the client wants to update the certificate.
78-
* If so, it will call {@link ClientCertificateProvider#getCertificate()} to get the new certificate.
77+
* The driver will call {@link ClientCertificateProvider#hasUpdate} to check if the client wants to update the certificate.
78+
* If so, it will call {@link ClientCertificateProvider#getClientCertificate} to get the new certificate.
7979
*
8080
* The certificate is only used as a second factor for authentication authenticating the client.
8181
* The DMBS user still needs to authenticate with an authentication token.
@@ -103,7 +103,7 @@ export class ClientCertificateProvider {
103103
/**
104104
* Returns the certificate to use for new connections.
105105
*
106-
* Will be called by the driver after {@link ClientCertificateProvider#hasUpdate()} returned true
106+
* Will be called by the driver after {@link ClientCertificateProvider#hasUpdate} returned true
107107
* or when the driver establishes the first connection.
108108
*
109109
* @returns {Promise<ClientCertificate>|ClientCertificate} the certificate to use for new connections

packages/core/src/session.ts

+11-3
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ class Session {
351351
/**
352352
* Return the bookmarks received following the last completed {@link Transaction}.
353353
*
354-
* @deprecated This method will be removed in version 6.0. Please, use Session#lastBookmarks instead.
354+
* @deprecated This method will be removed in version 6.0. Please, use {@link Session#lastBookmarks} instead.
355355
*
356356
* @return {string[]} A reference to a previous transaction.
357357
* @see {@link Session#lastBookmarks}
@@ -385,7 +385,7 @@ class Session {
385385
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
386386
* `maxTransactionRetryTime` property in milliseconds.
387387
*
388-
* @deprecated This method will be removed in version 6.0. Please, use Session#executeRead instead.
388+
* @deprecated This method will be removed in version 6.0. Please, use {@link Session#executeRead} instead.
389389
*
390390
* @param {function(tx: Transaction): Promise} transactionWork - Callback that executes operations against
391391
* a given {@link Transaction}.
@@ -410,7 +410,7 @@ class Session {
410410
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
411411
* `maxTransactionRetryTime` property in milliseconds.
412412
*
413-
* @deprecated This method will be removed in version 6.0. Please, use Session#executeWrite instead.
413+
* @deprecated This method will be removed in version 6.0. Please, use {@link Session#executeWrite} instead.
414414
*
415415
* @param {function(tx: Transaction): Promise} transactionWork - Callback that executes operations against
416416
* a given {@link Transaction}.
@@ -446,6 +446,10 @@ class Session {
446446
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
447447
* `maxTransactionRetryTime` property in milliseconds.
448448
*
449+
* NOTE: Because it is an explicit transaction from the server point of view, Cypher queries using
450+
* "CALL {} IN TRANSACTIONS" or the older "USING PERIODIC COMMIT" construct will not work (call
451+
* {@link Session#run} for these).
452+
*
449453
* @param {function(tx: ManagedTransaction): Promise} transactionWork - Callback that executes operations against
450454
* a given {@link Transaction}.
451455
* @param {TransactionConfig} [transactionConfig] - Configuration for all transactions started to execute the unit of work.
@@ -468,6 +472,10 @@ class Session {
468472
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
469473
* `maxTransactionRetryTime` property in milliseconds.
470474
*
475+
* NOTE: Because it is an explicit transaction from the server point of view, Cypher queries using
476+
* "CALL {} IN TRANSACTIONS" or the older "USING PERIODIC COMMIT" construct will not work (call
477+
* {@link Session#run} for these).
478+
*
471479
* @param {function(tx: ManagedTransaction): Promise} transactionWork - Callback that executes operations against
472480
* a given {@link Transaction}.
473481
* @param {TransactionConfig} [transactionConfig] - Configuration for all transactions started to execute the unit of work.

packages/core/src/transaction-promise.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import { TxConfig } from './internal/tx-config'
2727
import NotificationFilter from './notification-filter'
2828

2929
/**
30-
* Represents a {@link Promise<Transaction>} object and a {@link Transaction} object.
30+
* Represents a Promise<{@link Transaction}> object and a {@link Transaction} object.
3131
*
3232
* Resolving this object promise verifies the result of the transaction begin and returns the {@link Transaction} object in case of success.
3333
*

packages/core/src/types.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ export class Config {
298298
this.resolver = undefined
299299

300300
/**
301-
* Configure filter for Notification objects returned in {@Link ResultSummary#notifications}.
301+
* Configure filter for Notification objects returned in {@link ResultSummary#notifications}.
302302
*
303303
* See {@link SessionConfig#notificationFilter} for usage instructions.
304304
*

packages/neo4j-driver-deno/lib/core/client-certificate.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ export default class ClientCertificate {
7474
/**
7575
* Provides a client certificate to the driver for mutual TLS.
7676
*
77-
* The driver will call {@link ClientCertificateProvider#hasUpdate()} to check if the client wants to update the certificate.
78-
* If so, it will call {@link ClientCertificateProvider#getCertificate()} to get the new certificate.
77+
* The driver will call {@link ClientCertificateProvider#hasUpdate} to check if the client wants to update the certificate.
78+
* If so, it will call {@link ClientCertificateProvider#getClientCertificate} to get the new certificate.
7979
*
8080
* The certificate is only used as a second factor for authentication authenticating the client.
8181
* The DMBS user still needs to authenticate with an authentication token.
@@ -103,7 +103,7 @@ export class ClientCertificateProvider {
103103
/**
104104
* Returns the certificate to use for new connections.
105105
*
106-
* Will be called by the driver after {@link ClientCertificateProvider#hasUpdate()} returned true
106+
* Will be called by the driver after {@link ClientCertificateProvider#hasUpdate} returned true
107107
* or when the driver establishes the first connection.
108108
*
109109
* @returns {Promise<ClientCertificate>|ClientCertificate} the certificate to use for new connections

packages/neo4j-driver-deno/lib/core/session.ts

+11-3
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ class Session {
351351
/**
352352
* Return the bookmarks received following the last completed {@link Transaction}.
353353
*
354-
* @deprecated This method will be removed in version 6.0. Please, use Session#lastBookmarks instead.
354+
* @deprecated This method will be removed in version 6.0. Please, use {@link Session#lastBookmarks} instead.
355355
*
356356
* @return {string[]} A reference to a previous transaction.
357357
* @see {@link Session#lastBookmarks}
@@ -385,7 +385,7 @@ class Session {
385385
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
386386
* `maxTransactionRetryTime` property in milliseconds.
387387
*
388-
* @deprecated This method will be removed in version 6.0. Please, use Session#executeRead instead.
388+
* @deprecated This method will be removed in version 6.0. Please, use {@link Session#executeRead} instead.
389389
*
390390
* @param {function(tx: Transaction): Promise} transactionWork - Callback that executes operations against
391391
* a given {@link Transaction}.
@@ -410,7 +410,7 @@ class Session {
410410
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
411411
* `maxTransactionRetryTime` property in milliseconds.
412412
*
413-
* @deprecated This method will be removed in version 6.0. Please, use Session#executeWrite instead.
413+
* @deprecated This method will be removed in version 6.0. Please, use {@link Session#executeWrite} instead.
414414
*
415415
* @param {function(tx: Transaction): Promise} transactionWork - Callback that executes operations against
416416
* a given {@link Transaction}.
@@ -446,6 +446,10 @@ class Session {
446446
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
447447
* `maxTransactionRetryTime` property in milliseconds.
448448
*
449+
* NOTE: Because it is an explicit transaction from the server point of view, Cypher queries using
450+
* "CALL {} IN TRANSACTIONS" or the older "USING PERIODIC COMMIT" construct will not work (call
451+
* {@link Session#run} for these).
452+
*
449453
* @param {function(tx: ManagedTransaction): Promise} transactionWork - Callback that executes operations against
450454
* a given {@link Transaction}.
451455
* @param {TransactionConfig} [transactionConfig] - Configuration for all transactions started to execute the unit of work.
@@ -468,6 +472,10 @@ class Session {
468472
* delay of 1 second and maximum retry time of 30 seconds. Maximum retry time is configurable via driver config's
469473
* `maxTransactionRetryTime` property in milliseconds.
470474
*
475+
* NOTE: Because it is an explicit transaction from the server point of view, Cypher queries using
476+
* "CALL {} IN TRANSACTIONS" or the older "USING PERIODIC COMMIT" construct will not work (call
477+
* {@link Session#run} for these).
478+
*
471479
* @param {function(tx: ManagedTransaction): Promise} transactionWork - Callback that executes operations against
472480
* a given {@link Transaction}.
473481
* @param {TransactionConfig} [transactionConfig] - Configuration for all transactions started to execute the unit of work.

packages/neo4j-driver-deno/lib/core/transaction-promise.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import { TxConfig } from './internal/tx-config.ts'
2727
import NotificationFilter from './notification-filter.ts'
2828

2929
/**
30-
* Represents a {@link Promise<Transaction>} object and a {@link Transaction} object.
30+
* Represents a Promise<{@link Transaction}> object and a {@link Transaction} object.
3131
*
3232
* Resolving this object promise verifies the result of the transaction begin and returns the {@link Transaction} object in case of success.
3333
*

packages/neo4j-driver-deno/lib/core/types.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ export class Config {
298298
this.resolver = undefined
299299

300300
/**
301-
* Configure filter for Notification objects returned in {@Link ResultSummary#notifications}.
301+
* Configure filter for Notification objects returned in {@link ResultSummary#notifications}.
302302
*
303303
* See {@link SessionConfig#notificationFilter} for usage instructions.
304304
*

packages/neo4j-driver/src/result-rx.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ export default class RxResult {
121121
*
122122
* This method won't need to be called in normal stream operation. It only applies to the case when the stream is paused.
123123
*
124-
* This method is method won't start the consuming records if the ${@link records()} stream didn't get subscribed.
124+
* This method is method won't start the consuming records if the {@link records} stream didn't get subscribed.
125125
* @experimental
126126
* @returns {Promise<void>} - A promise that resolves when the stream is resumed.
127127
*/

0 commit comments

Comments
 (0)