Develop a small UI in react, which will upload the file using the above API and let the user download the JSON file received from the API response.It can be a simple UI with a button to upload a file and the button can have a loader while the API is being called. After successful response, download the JSON file without user intervention. If there is an error, show an alert.
Develop an API in node.js, which takes a file and returns a parsed output as JSON.
- Clone this repository
git clone https://github.com/dollpriyanka/Log_Parser_App.git
- Go to the cloned directory
- Initialize the directory
npm init -y
- Install dependencies
npm install
<ISO Date> - <Log Level> - {"transactionId: "<UUID>", "details": "<message event/action description>", "err": "<Optional, error description>", ...<additional log information>}
[{"timestamp": <Epoch Unix Timestamp>, "loglevel": "<loglevel>", "transactionId: "<UUID>", "err": "<Error message>" }]
* /upload - upload the log file