Configuring a Database

This is a mandatory operation for productive environments.

eSign requires a persistence layer to store documents until they are signed and submitted. By default the persistence layer is implemented over an in-memory H2 database. However, this setup should only be used by developers, and is neither compatible with high availability setups, nor is it supported in productive environments.

Hence, when preparing your productive environment one of the first steps is to configure eSign to use a database.

Even in development environments we strongly recommend using a database persistence setup.

Execute Database Scripts

eSign provides database scripts for the supported databases. See Supported Databases.

  1. Execute the database script matching your database.

All database scripts are idempotent and can be executed over previous version scripts.

Configure Database Persistence

  1. From esign-home directory, open config/esign.config and add a new entry in the properties section:

    {
    	...
    
    	"properties": {
    
    		...
    
    		"_comment" : "eSign standard database",
    
    		"database.driver" : "<driver>",
    		"database.url" : "<jdbc-url>",
    		"database.user" : "<user>",
    		"database.password" : "<password>",
    
    		"_comment" : "Dedicated database for analytics data",
    
    		"database.analytics.url": "<analytics-jdbc-url>",
    		"database.analytics.user": "<analytics-user>",
    		"database.analytics.password": "<analytics-password>",
    
    		"database.analytics-reader.url": "<analytics-jdbc-url>",
    		"database.analytics-reader.user": "<analytics-user>",
    		"database.analytics-reader.password": "<analytics-password>"
    	}
    }
    • Configuring Postgres Database:

      "database.driver": "org.postgresql.Driver",
      "database.url": "jdbc:postgresql://[HOST]:[PORT]/[DATABASENAME]",
    • Configuring Oracle Database:

      "database.driver": "oracle.jdbc.driver.OracleDriver",
      "database.url": "jdbc:oracle:thin:@[HOST]:[PORT]:[DATABASE]",
    • Configuring MSSQL Database:

      "database.driver": "com.microsoft.sqlserver.jdbc.SQLServerDriver",
      "database.url": "jdbc:sqlserver://[HOST]:[PORT];database=[DATABASE];",