This sub-project provides a shared library used within datomic transactions and peer-queries.
All commands below assume the ids directory as the starting-point working directory.
make clean
make target/wbids.jar
Ensure to run all tests and check they pass before deploying a new release, submitting new pull requests and preferable before committing to the IDs library code.
cd ../
make run-tests
cd -
The IDs library deployment process consists of three main steps:
- Build and deploy the library to clojars
- Update the appropriate Datomic transactors to use this new library
- Update the main name-service to use the new version of the
wormbase/ids
dependency and release and deploy a new version of the application (if needed).
- Prepare pom.xml file defining the release version and dependencies
# Generate/update the pom.xml file (not version-controlled)
rm -f pom.xml
clj -Spom
#Check the current clojars version
curl -s -H 'accept: application/json' https://clojars.org/api/artifacts/wormbase/ids | jq .latest_version
# Update the pom.xml to
# * have a new unique version as <version> tag value (bump x, y or z release nr from current version)
# * have "wormbase" (unquoted) as <groupId> tag value
# * have "ids" (unquoted) as <artifactId> tag value
# * Review the dependencies and compare them to deps.edn
# (to ensure no extra dependencies slipped in through your ~/.clojure/deps.edn file)
$EDITOR pom.xml
-
Build the library jar as instructed above.
-
Deploy the library jar to clojars.
This will require the file~/.m2/settings.xml
to be defined as described here (settings.xml
part). Clojars username can be obtained by registering at clojars.org and a deploy-token can be generated after that by visiting this page. Ensure you have been added to the wormbase group to allow uploading a new version (ask a colleague).
# Release to clojars
make release
To update the datomic transactors so they would use a new release of the IDs library, follow the instructions in the wormbase-architecture/transactor README and update the appropriate CF parameter to match the new IDs package release number.
Update the main name-service to use the new version of the wormbase/ids
dependency by: