Skip to content
LoopBack KeyValue connector examples.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github
extreme-scale.lb2x
extreme-scale.lb3x
kv-memory.lb2x chore: update copyrights years May 10, 2019
kv-memory.lb3x chore: update copyrights years May 10, 2019
redis.lb2x
redis.lb3x chore: update copyrights years May 10, 2019
CODEOWNERS
README.md

README.md

loopback-example-kv-connectors

KeyValue connector examples.

Examples list

Usage

Examples are written in the form of tests. Ensure everything is working correctly by running the tests before using the code as reference.

For example, to try out the KeyValue-memory connector:

git clone https://github.com/strongloop/loopback-example-kv-connectors.git
cd loopback-example-kv-connectors/kv-memory-lb2x/
npm install
npm test

Then review the tests to understand how to use the connector.

Third party connectors

You will need to start the corresponding servers on your local machine using default application ports before running tests.

For example, to try out the Redis KeyValue connector:

git clone https://github.com/strongloop/loopback-example-kv-connectors.git
cd loopback-example-kv-connectors/redis-lb2x/
npm install
redis-server --daemonize yes # starts redis in the background
npm start

Then review the tests accordingly. To stop the Redis background process, find its process id and kill it:

ps aux | grep redis-server
# ...find the process id (ie. 12345)
kill 12345

We intentionally skip over configuration details like setting up data sources and models as these topics are already covered in our tutorials.


More LoopBack examples

You can’t perform that action at this time.