minimonolith 0.21.0 → 0.21.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -116,18 +116,18 @@ export default ({ MODELS }) => ({
116
116
 
117
117
  ## App Environments
118
118
 
119
- There are 4 possible environments: DEV=TRUE & PROD=FALSE, DEV=TRUE & PROD=TRUE, DEV=FALSE & PROD=TRUE, DEV=FALSE & PROD=TRUE
120
- 1. DEV=TRUE & PROD=FALSE: This is the standard DEV environment
121
- 2. DEV=FALSE & PROD=FALSE: This is the standard QA environment
122
- 3. DEV=FALSE & PROD=TRUE: This is the stnadard PROD environment
123
- 4. DEV=TRUE & PROD=TRUE: This allows to test the behavior of PROD within the "new concept" of DEV environment
119
+ There are 4 possible environments:
120
+ 1. DEV=TRUE + PROD=FALSE: This is the standard DEV environment
121
+ 2. DEV=FALSE + PROD=FALSE: This is the standard QA environment
122
+ 3. DEV=FALSE + PROD=TRUE: This is the stnadard PROD environment
123
+ 4. DEV=TRUE + PROD=TRUE: This allows to test the behavior of PROD within the "new concept" of DEV environment
124
124
 
125
125
  To better understand their relevance:
126
126
  1. The "new concept" DEV environments (DEV=TRUE) aim to make the api crash if an "important" error happens
127
127
  - Its current only difference is it makes it crash on error at service registration phase
128
128
  - Some may think QA should also fail on "important" errors They can use DEV=TRUE there But some do training activities on QA that must be minimally disrupted
129
129
  2. The "new concept" QA environments (PROD=FALSE) aim at logging data about the system which on production environments would be forbiden personal information
130
- 1. This is relevant because replication of QA activities (even security QA activities) depend heavily on this
130
+ - This is relevant because replication of QA activities (even security QA activities) depend heavily on this
131
131
 
132
132
  The current App environment is determined on the values of MM_API_DEV ENV [TRUE/FALSE] and MM_API_PROD_ENV [TRUE/FALSE]:
133
133
 
@@ -138,7 +138,7 @@ MM_API_PROD_ENV=FALSE
138
138
  [...]
139
139
  ```
140
140
 
141
- *NOTICE*: If this variables are not added to .env/Lambda environment it is assumed standard PROD environment (DEV=FLASE & PROD=TRUE)
141
+ *NOTICE*: If this variables are not added to .env/Lambda environment it is assumed standard PROD environment (DEV=FLASE + PROD=TRUE)
142
142
  - This means that sequelize will not alter automatically tables having mismatches with defined model.js files
143
143
  - Database dialect/credentials detected will not be printed
144
144
  - Critical errors will not make the app crash
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "minimonolith",
3
3
  "type": "module",
4
- "version": "0.21.0",
4
+ "version": "0.21.1",
5
5
  "main": "index.js",
6
6
  "license": "MIT",
7
7
  "scripts": {
@@ -1,10 +1,10 @@
1
- import runLambdaServer from './runLambdaServer.js';
1
+ import lambdaServer from './lambdaServer.js';
2
2
 
3
3
  const createDevEnvironment = async (ENV_FILE='.env', MODULE_FOLDER='node_modules/') => {
4
4
  const { loadEnvFile } = await import('./loadEnvFile.js');
5
5
  loadEnvFile(ENV_FILE, MODULE_FOLDER);
6
6
 
7
- return runLambdaServer;
7
+ return lambdaServer;
8
8
  }
9
9
 
10
10
  export default createDevEnvironment;
@@ -2,10 +2,10 @@ import http from 'http';
2
2
 
3
3
  import { getServerHandler } from './serverHandler.js';
4
4
 
5
- const runLambdaServer = (lambdaHandler, port) => {
5
+ const lambdaServer = (lambdaHandler, port) => {
6
6
  const serverHandler = getServerHandler(lambdaHandler);
7
7
  const server = http.createServer(serverHandler);
8
8
  server.listen(port);
9
9
  }
10
10
 
11
- export { runLambdaServer };
11
+ export default lambdaServer;