-
Notifications
You must be signed in to change notification settings - Fork 2
Additional Information
rubocop should always return a clean status with no warnings.
Once the API is started you can invoke the tests with the simple command below:
rake testPlease add issues to the shared issues list
The detailed deployment mapping is described in deployment.yml. At the time
of writing, using the new infrastructure, the deployment process is as follows:
- commits to the
dev-infrastructurebranch will deploy the dev server - commits to the
preprodbranch will deploy the pre-production server - any commit on the
prodbranch will deploy the production server as a new release
If the commit is a "new" release, the deployment should be tagged with the same
semantic version number matching the BREAKING.FEATURE.PATCH format, e.g.
v1.2.3, the same as should be set in the /app/lib/version.rb; also, a short
annotation summarising the updates should be included in the tag as well.
Once the production deployment has been completed and verified, please create a
release on the repository using the same semantic version number. Utilise the
Generate release notes from commit log option to create specific notes on the
contained changes as well as the ability to diff agains the previous version.
- Workaround to removing the PID lock of the Rails process in the event of the application crashing and not releasing the process.
- Guards to ensure the required environment variables are set accordingly and trigger the build to fail noisily and log to the system.
- Rails secret creation for
SECRET_KEY_BASEassignment; see Runtime Configuration environment variables.
Some development tasks are handled by automated Rails task scripts. All tasks
code is in ./lib/tasks/*.rake. You can list all of the tasks with rails -T.
The mostly commonly useful ones are:
-
test
Run the test suite -
ukhpi:aspects
Generate a JavaScript description of the DSD aspects, as described by theDataModelclass, which directly translates from theUKHPI-dsd.ttlfile -
boundaries tasks
A number of tasks releated to generating simplified GeoJSON files from the Shapefiles downloaded from ONS. These tasks will need to be re-run when the boundaries change, e.g. when local authorities are merged or split to form new unitary authorities. See below for more details.-
ukhpi:describe[uri]
A convenient way to perform a SPARQL describe for the given URI -
ukhpi:locations
This task uses a SPARQL query to list all of the geographical regions in the UKHPI data, and their containment hierarchy, and generate cached versions of that data as code. In particular, it regeneratesapp/javascript/data/locations-data.jsandapp/models/locations_table.rb. This task should be re-run if and when the regions data from LR is changed in the triple store.
-
Note that, by default, SPARQL queries will be run against the dev triple store.
To direct the query against a different SPARQL endpoint, change the SERVER
environment variable:
SERVER="https://lr-dev.epimorphics.net/landregistry/query" rails ukhpi:locations