-
Notifications
You must be signed in to change notification settings - Fork 0
Configuring Local Datastore Environment
To run the sample on a local installation of Google Cloud Datastore, or to use it for working with the Datastore in your tests, please perform the following steps:
-
Download the GCD tool and unzip it.
You may also want to download sources from GCD GitHub Repository. -
Set the
GCD_HOMEOS environment variable to the path to the GCD tool root directory. -
Open the console, go to the GCD tool root directory. Then execute the following command
./gcd.sh create -d spine-local-dataset my-project
gcd create -d spine-local-dataset my-project
Where my-project is your local project directory.
You can also pass DatastoreOptions with a custom dataset name to LocalDatastoreStorageFactory.newInstance(DatastoreOptions) method and use this name instead of spine-local-dataset in this command.
To run tests, it is required to start the local Datastore Server manually, until this issue is fixed and this fix is added to the next GCD library release.
To start the local Datastore Server, please run the following command:
./gcd.sh start --testing my-project
gcd start --testing my-project
Where my-project is your local project directory.
It is also required to checkout Spine core-java project, build it via Gradle and install to the local Maven repository.
Please run the following command:
gradlew publishToMavenLocal