How to build scalable microservices using LoopBack.next.
What's the difference between LoopBack.next and the current version of Loopback? See LoopBack 3 vs LoopBack 4.
Make sure you have the following installed:
- Node.js >= 7.0.0
- TypeScript >= 2.0.0
npm i -g typescript
- TypeScript Node >= 3.0.0
npm i -g ts-node
# install and link loopback-next
git clone https://github.com/strongloop/loopback-next
cd loopback-next
npm install
npm run bootstrap
npm link
# install loopback-next-example
cd ..
git clone https://github.com/strongloop/loopback-next-example
cd loopback-next-example
npm run build
# start all microservices
npm start
# perform GET request to retrieve account summary data
curl localhost:3000/account/summary?accountNumber=CHK52321122 # or npm test
# perform GET request to retrieve account data
curl localhost:3001/accounts?accountNumber=CHK52321122
# stop all microservices
npm stop
Helper scripts for the above commands are in
/bin
directory.
Ritchie Martori | Simon Ho | Siddhi Pai | Mahesh Patsute | Deepak Rajamohan |
---|---|---|---|---|
MIT