Releases: Njs2/njs2-base
v2.5.0-2
- BUGFIX: responseTemplate parsing issue f3a8da0
What's Changed
- BugFix: for 2.4.0-0 by @ganeshsacharya in #52
Full Changelog: v2.4.0...v2.5.0-2
v2.5.0-1
v2.4.0
What's Changed
- Feature Enhancements & Minor Fixes to Framework files by @ganeshsacharya in #48
- Default to Njs2 Custom Response Template in case of No project Template! by @ganeshsacharya in #51
Full Changelog: v2.3.1...v2.4.0
v2.4.0-0
- UPDATE: Default to Njs2 Custom Response Template in case of No project Template(s) 7f4ebc4
- Custom Response Structure Implementation 745bab6
- FEATURE: Added metadata append to actionInstance based on configs cffc721
- Added Serverless Wrapper for Express 7e438ec
What's Changed
- Feature Enhancements & Minor Fixes to Framework files by @ganeshsacharya in #48
- Default to Njs2 Custom Response Template in case of No project Template! by @ganeshsacharya in #51
Full Changelog: v2.3.1...v2.4.0-0
Patch - Fixes to call AWS Gateway API under managed environment
- cleaned the cross account credential method while calling API Gateway Management APIs
- removed the BASE config section from config.json of the template
Configuration Fix
- AWS API Gateway API requires region key 0638d93
Feature Updates
- Remove try catch from mongo.lib.js 54388c4
- Processing object in parameterProcessing
Scheduler Updates
Updates to execute cron jobs in your Njs2 Projects
A new condition has been added to the default handler function which can now read the cron tasks and execute them based on the cron pattern mentioned in config.json
Documentation can be found in the below link:
cron
e.g.: say you want to execute a piece of code every 'n' minutes,
- Make a new entry with the required cron pattern in the config.json file
- Ask the DevOps team to make a AWS EventBridge Rule to have an EVERY MINUTE call to your Lambda function with just requestType = "cron" as the param
- Njs2 Framework should now check each cron entry in your Lambda Code > config.json file and if the cron pattern matches the current minute it shall execute the respective task
What if i want to upgrade my existing project to use this @njs2/base version?
- copy the cron.js, mCron.js files from HERE to the root of your project
- update your config.json as per this documentation
- install the latest @njs2/base version using: npm i @njs2/base@latest or npm i @njs2/base@2.2.0
- run the project locally and configure your crontab as per this documentation (unix based systems only!)
AWS API trigger should be using default lambda role
FIX: AWS API trigger does not need any cross account credentials anymore eb3c813
config.json > BASE is no longer needed
Scheduler Updates
Updates to execute cron jobs in your Njs2 Projects
A new condition has been added to the default handler function which can now read the cron tasks and execute them based on the cron pattern mentioned in config.json
Documentation can be found in the below link:
cron
e.g.: say you want to execute a piece of code every 'n' minutes,
- Make a new entry with the required cron pattern in the config.json file
- Ask the DevOps team to make a AWS EventBridge Rule to have an EVERY MINUTE call to your Lambda function with just requestType = "cron" as the param
- Njs2 Framework should now check each cron entry in your Lambda Code > config.json file and if the cron pattern matches the current minute it shall execute the respective task
What if i want to upgrade my existing project to use this @njs2/base version?
- copy the cron.js, mCron.js files from HERE to the root of your project
- update your config.json as per this documentation
- install the latest @njs2/base version using: npm i @njs2/base@latest or npm i @njs2/base@2.2.0
- run the project locally and configure your crontab as per this documentation (unix based systems only!)