URL Logger code errors inside Console

More
1 year 10 months ago #24256 by prashant
This is something we discussed once , but I have forgotten how to implement this. 

What changes in code are to be done that all errors if any are showcase in the console (when running  URLLogger.exe) 

Let's take a sample code below
Code:
const fs = require("fs"); const { spawn } = require("child_process"); try {   const WORKING_DIRECTORY = "C:\\Program Files\\DB Software Laboratory\\Advanced ETL Processor Enterprise\\";   const fileToExecute = "C:\\Program Files\\DB Software Laboratory\\Advanced ETL Processor Enterprise\\aetlcl.exe";   const objectId = 7323   const parameters = [objectId,logId];   logger.info(parameters);   spawn(fileToExecute, parameters, { cwd: WORKING_DIRECTORY, detached: true });   return 200; } catch (err) {   logger.error(`Caught an error: ${err.message ? err.message : err}`);   return 500; // Any error caught here results in a 500 status }

Please Log in or Create an account to join the conversation.

More
1 year 10 months ago - 1 year 10 months ago #24257 by Peter.Jonson
There are two kinds of possible errors here

1 Errors from URL logger.
2 Errors from AETL

N 1 is already taken care of by  

logger.error(`Caught an error: ${err.message ? err.message : err}`);

N 2 you would need to check AETL log, UL will not be able to print it for you

Peter Jonson
ETL Developer
Last edit: 1 year 10 months ago by Peter.Jonson.
The following user(s) said Thank You: prashant

Please Log in or Create an account to join the conversation.

Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Read more
Marketing
Set of techniques which have for object the commercial strategy and in particular the market study.
Google
Accept
Decline
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Google Analytics
Accept
Decline
Functional
Tools used to give you more features when navigating on the website, this can include social sharing.
Advertisement
If you accept, the ads on the page will be adapted to your preferences.
Google Ad
Accept
Decline
Save