Highlighted

Is there a standard approch to logging per app?

Explorer ,
Jun 09, 2020

Copy link to clipboard

Copied

My company is looking at ways to log and trace our apps which range from Coldfusion, react, and node js applications. We want to log when pages are spent up to actions the end-user performed to errors.

My question what are some of the solutions that are a standard way across the board to handle application logging?

TOPICS
Advanced techniques, Asynchronous, Monitoring, Reporting

Views

307

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Is there a standard approch to logging per app?

Explorer ,
Jun 09, 2020

Copy link to clipboard

Copied

My company is looking at ways to log and trace our apps which range from Coldfusion, react, and node js applications. We want to log when pages are spent up to actions the end-user performed to errors.

My question what are some of the solutions that are a standard way across the board to handle application logging?

TOPICS
Advanced techniques, Asynchronous, Monitoring, Reporting

Views

308

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jun 09, 2020 0
Adobe Community Professional ,
Jun 09, 2020

Copy link to clipboard

Copied

There are different expectations that different people will have about logging, and what is "standard", so you may want to add some clarification.

 

Of course, your web server will log every request made to CF (or for another server-side file).  CF does not itself log every request (though that can be enabled via the underlying Tomcat "valve", as discussed here and elsewhere).

 

Some may interpret your question in such a way as to propose how CF does have a cflog tag (and writelog function), and these can be used within your app to write anything to a log (stored in the CF "logs" folder). But it's not clear to me if that's what you seek. (Someone may want to point out also that you could do such logging at the start and end of your request, via the methods in application.cfc or via the pairing of application.cfm and onrequestend.cfm).

 

Finally, it may be worth noting that various apm's (app perf monitoring) tools often offer their own API that you can call to have THEM log things, and that may be more compelling when folks want to "trace across apps", if all such apps are being monitored by such an APM. (And FWIW, FusionReactor, the monitor for CF, has an API of its own, FRAPI, that can offer additional logging, tracing, and custom metrics.)

 

So while my instinct is to say there is no "standard way" to handle "application logging", beyond the above, let's see what others may add, or what you may well respond with, to see if we need to go still further.

/Charlie (server troubleshooter, carehart.org)

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 09, 2020 0
Adobe Community Professional ,
Jun 10, 2020

Copy link to clipboard

Copied

I would suggest you design your system as follows:

 

  1. ColdFusion --- logs by default to {COLDFUSION_INSTALLATION_DIRECTORY}/cfusion/logs
  2. React --- write your own code to log to file or install a logging plugin or library (search the web for suitable ones)
  3. Node --- write your own code to log to file or install a logging plugin or library (search the web for suitable ones)

 

Install a central log analysis tool that uses as input the log files from 1., 2. and 3. Some log analysis tools are Open Source.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 10, 2020 0
Explorer ,
Jun 11, 2020

Copy link to clipboard

Copied

Thanks for that info charlie and bkbk.

After having a few meetings with my team and seeing what they are looking for, I proposed that we have an independent app that just writes logs. The way it works is we can include an HTTP async(send and forget it) post to an API logging app that way we can catch whatever the apps sends, may it be from cold fusion, node, etc. but didn't know if there was an out of box solution for this type of approach.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 11, 2020 0
Adobe Community Professional ,
Jun 12, 2020

Copy link to clipboard

Copied

BeRadB, From the sound of it, your proposal is as good as any. From a design point of view. It has the simplicity and context-awareness that an out of the box solution won't be able to match. 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 12, 2020 0
LEGEND ,
Jun 12, 2020

Copy link to clipboard

Copied

And, hey, who knows.. if it's good enough, you might even be able to market it as a customizable turnkey solution for anyone else looking to do the same.

 

V/r,

 

^ _ ^

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 12, 2020 1