Skip to content

ezpaarse-project/readholdings

Repository files navigation

readholdings

Readholdings is a service providing a global view of several accounts used by EbscoHost's HLM tool. The data is saved in an elasticsearch index and can be viewed on kibana dashboards.

Table of content

Description

A web interface is used to communicate with an API. It is possible to insert data, track insertions, manage ElasticSearch indexes and manage the application's health status.

Data updates are automated using an application cron job. This launches a job that generates, downloads, reads and transforms the data, then inserts it into the snapshot generated by the Ebsco API in version 2.

meta.access_type is based on : https://doaj.org/apply/guide/#basic-criteria-for-inclusion

Network-flow

readHoldings is made up of several services which are distributed in several docker containers. Network-flow

Installation

Development

Prerequisites

The tools you need to let readholdings run are :

  • docker
  • npm

Ebsco docs: https://developer.ebsco.com/knowledge-services/reference/getcustidexports

Commands

# install dependencies
npm i

# Execute this one time
docker-compose -f docker-compose.debug.yml run --rm elastic chown -R elasticsearch /usr/share/elasticsearch/ 

# Start ReadHoldings as daemon
docker-compose -f docker-compose.debug.yml up -d

# Stop ReadHoldings
docker-compose -f docker-compose.debug.yml stop

# Get the status of ReadHoldings services
docker-compose -f docker-compose.debug.yml ps

Tests

No test are available (coming soon).

Deployment

Prerequisites

  • docker
  • Total extracted data does not exceed 500 000 rows

Environment variables

You can create an environment file named readholdings.local.env.sh and export the following environment variables. You can then source readholdings.env.sh, which contains a set of predefined variables and is overridden by readholdings.local.env.sh.

Adjust system configuration for Elasticsearch

Elasticsearch has some system requirements that you should check.

To avoid memory exceptions, you may have to increase mmaps count. Edit /etc/sysctl.conf and add the following line :

# configuration needed for elastic search
vm.max_map_count=262144

Then apply the changes :

sysctl -p

Start/Stop/Status

Before you start readholdings, make sure all necessary environment variables are set.

# Start readholdings as daemon
docker-compose up -d

# Stop readholdings
docker-compose stop

# Get the status of readholdings services
docker-compose ps

About

No description, website, or topics provided.

Resources

License

CECILL-2.1, Unknown licenses found

Licenses found

CECILL-2.1
LICENCE.txt
Unknown
LICENSE.txt

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published