MySQL
MySQL also provides the option to use an externally located database that also supports high availability.
The following steps are required to use MySQL:
-
Download the MySQL JDBC driver and place it somewhere accessible to NiFi Registry
/path/to/drivers/mysql-connector-java-8.0.16.jar -
Create a database inside MySQL (enter mysql shell using
mysql -u root -pCREATE DATABASE nifi_registry; -
Create a database user and grant privileges (for remote users, use
nifireg'@'<IP-ADDRESS>, ornifireg'@'%for any remote host)GRANT ALL PRIVILEGES ON nifi_registry.* TO 'nifireg'@'localhost' IDENTIFIED BY 'changeme'; -
Configure the database properties in nifi-registry.properties
nifi.registry.db.url=jdbc:mysql://<MYSQL-HOSTNAME>/nifi_registry nifi.registry.db.driver.class=com.mysql.cj.jdbc.Driver nifi.registry.db.driver.directory=/path/to/drivers nifi.registry.db.username=nifireg nifi.registry.db.password=changeme
