nxt.dbConnect: Make a connection to the NXT H2 database containing the...

Description Usage Arguments Value Author(s) See Also

Description

Recent versions of the NRS NXT client store the blockchain in a H2 database. This function facilitates connecting to this database using the RH2 package. This requires RH2 >= 0.2 and NRS client >= 0.8. If you want to connect to the NXT H2 database while running the NRS client, then one must instruct the NRS client to open the database with the AUTO_SERVER=TRUE option using the 'nxt.dbUrl' config property.

Usage

1
2
3
nxt.dbConnect(file = "nxt/nxt_db/nxt.h2.db",
  H2.opts = ";DB_CLOSE_ON_EXIT=FALSE;AUTO_SERVER=TRUE",
  H2.prefix = "jdbc:h2:", username = "sa", password = "sa", ...)

Arguments

file

Full path to the file containing the NXT H2 database.

H2.opts

Configuration options for the H2 connection. Defaults to ";DB_CLOSE_ON_EXIT=FALSE;AUTO_SERVER=TRUE".

H2.prefix

In general, don't touch. Defaults to "jdbc:h2:".

username

In general, don't touch. Defaults to "sa".

password

In general, don't touch. Defaults to "sa".

...

Further arguments to the H2 driver function (e.g., jars).

Value

An H2 DB connection object

Author(s)

David M. Kaplan dmkaplan2000@gmail.com

See Also

nxt.dbDisconnect, H2


dmkaplan2000/Rxt documentation built on May 15, 2019, 9:35 a.m.