https://github.com/dvsa/mes-logs-service
DVSA Mobile Examiner Services - Logs Microservice
https://github.com/dvsa/mes-logs-service
Last synced: 4 months ago
JSON representation
DVSA Mobile Examiner Services - Logs Microservice
- Host: GitHub
- URL: https://github.com/dvsa/mes-logs-service
- Owner: dvsa
- License: mit
- Created: 2019-02-06T10:22:07.000Z (over 7 years ago)
- Default Branch: develop
- Last Pushed: 2025-02-28T14:52:51.000Z (over 1 year ago)
- Last Synced: 2025-02-28T20:21:16.938Z (over 1 year ago)
- Language: TypeScript
- Size: 1.24 MB
- Stars: 0
- Watchers: 10
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# mes-logs-service
A serverless microservice responsible reporting error logs from the mes-mobile-app
## Dependencies
DVSA dependencies have been moved from npm to github so in order to install/update any private @DVSA packages
you are required to have an entry in your global `~/.npmrc` file as follows:
```shell
//npm.pkg.github.com/:_authToken=
```
## Structure
All serverless functions live in dedicated directories in `src/functions`.
Code that is common between multiple functions should reside in `src/common`.
As per the principles of Hexagonal Architecture, each function has the following directories to help us separate concerns:
* `framework` - contains all Inbound and Outbound Adapters, and all use of external/proprietary APIs - depends upon...
* `application` - contains all Inbound and Outbound Ports, doesn't use any external/proprietary APIs - depends upon...
* `domain` - contains all domain objects (Aggregates, Objects, Value classes etc) with all "business logic" (not just anaemic data holders), doesn't use any external/proprietary APIs.
## Build
To build a zip file for every function to `build/artifacts`, run:
```shell
npm run package
```
To build a subset of the functions, pass a comma separated list of function names, like so:
```shell
npm run package -- get,set
```
N.b. The build requires [jq](https://github.com/stedolan/jq).
## Test
To run the unit tests, run:
```shell
npm run test
```
## Integration tests
To run the integration tests, run:
```shell
npm run test:integration
```