In the past, provisioning Neo4j instances with the GrapheneDB Heroku add-on has been limited to one database per application.
Our customers often provided feedback that they wanted to spin up additional database instances to perform tests, do database sharding, or to have different databases for different purposes connected to the same app.
To provision additional databases, customers relied on workarounds such as creating dummy apps, adding environment variables manually to share the GrapheneDB connection URIs across apps. Needless to say this can be an error-prone hassle.
We have heard your feedback, and we are excited to announce that we’ve improved our Heroku add-on by adding support for multiple installs per app, and making them shareable across apps.
Below, you can find an example of how to provision a database by specifying the name of the database as well as the app.
1 2 3 4 5 6
Please note that to avoid collision of environment variable names, the following logic is applied if a name is not specified:
If there is no GrapheneDB database for the specified app, the database will be named graphenedb and the environment variable will be GRAPHENEDB_URL.
If there are already other GrapheneDB databases and the graphenedb name is taken, a random color will be appended to the graphenedb name. An example of the resulting environment variable would be GRAPHENEDB_COBALT_URL
An existing GrapheneDB add-on database can be attached to an app using the attach command:
If the GRAPHENEDB_URL environment variable is not taken, GRAPHENEDB_URL will point to the most recently attached database. Otherwise, a random name will be assigned (as in the example above GRAPHENEDB_COBALT_URL).
You can also specify the desired name when attaching an add-on with the –as parameter:
1 2 3
We look forward to hearing how you use the new and improved Heroku add-on! Feel free to tweet us about your experiences at @graphenedb on Twitter, or email us at
email@example.com if you have any questions.