mirror of
https://github.com/corda/corda.git
synced 2024-12-20 05:28:21 +00:00
Extended docs on h2settings (#3669)
* Extended docs on h2settings * Documents h2port being deprecated in favour of h2settings. * Fixes link. * Capitalisation
This commit is contained in:
parent
a0183fbdfd
commit
a7b1175833
@ -85,7 +85,9 @@ absolute path to the node's base directory.
|
||||
Currently the defaults in ``/node/src/main/resources/reference.conf`` are as shown in the first example. This is currently
|
||||
the only configuration that has been tested, although in the future full support for other storage layers will be validated.
|
||||
|
||||
:h2port: A number that's used to pick the H2 JDBC server port. If not set a randomly chosen port will be used.
|
||||
:h2Port: Deprecated. Use ``h2Settings`` instead.
|
||||
|
||||
:h2Settings: Sets the H2 JDBC server port. See :doc:`node-database-access-h2`.
|
||||
|
||||
:messagingServerAddress: The address of the ArtemisMQ broker instance. If not provided the node will run one locally.
|
||||
|
||||
|
@ -13,9 +13,10 @@ Any database browsing tool that supports JDBC can be used, but if you have Intel
|
||||
a tool integrated with your IDE. Just open the database window and add an H2 data source with the above details.
|
||||
You will now be able to browse the tables and row data within them.
|
||||
|
||||
By default the node will expose its database on the localhost network interface. This behaviour can be
|
||||
overridden by specifying the full network address (interface and port), using the new h2Settings
|
||||
syntax in the node configuration:
|
||||
By default, the node's H2 database is not exposed. This behaviour can be overridden by specifying the full network
|
||||
address (interface and port), using the new ``h2Settings`` syntax in the node configuration.
|
||||
|
||||
The configuration below will restrict the H2 service to run on ``localhost``:
|
||||
|
||||
.. sourcecode:: groovy
|
||||
|
||||
@ -23,9 +24,21 @@ syntax in the node configuration:
|
||||
address: "localhost:12345"
|
||||
}
|
||||
|
||||
The configuration above will restrict the H2 service to run on localhost. If remote access is required, the address
|
||||
can be changed to 0.0.0.0. However it is recommended to change the default username and password
|
||||
before doing so.
|
||||
If you want H2 to auto-select a port (mimicking the old ``h2Port`` behaviour), you can use:
|
||||
|
||||
.. sourcecode:: groovy
|
||||
|
||||
h2Settings {
|
||||
address: "localhost:0"
|
||||
}
|
||||
|
||||
If remote access is required, the address can be changed to ``0.0.0.0``. However it is recommended to change the default username and password before doing so.
|
||||
|
||||
.. sourcecode:: groovy
|
||||
|
||||
h2Settings {
|
||||
address: "0.0.0.0:12345"
|
||||
}
|
||||
|
||||
The previous ``h2Port`` syntax is now deprecated. ``h2Port`` will continue to work but the database
|
||||
will only be accessible on localhost.
|
Loading…
Reference in New Issue
Block a user