Formalize getLogPrefix across all resolverPlugins (and wider?)

Description

About half way through the development of V3 I introduced a method called getlogPrefix().  The idea is that is makes is super easy to log

The LogPrefix is usually derived from the plugin Id plus its type

I was just in the position of wanting to add a log message to the ValueMap logging and discovered that there wasn't a getlogprefix.

 

It would be nice to be able to rely on this across all the objects that the attribute resolvers and filters use.  I propose that we add this, possibly via an interface which everything gets to implement.

 

It might also be cute to add a setter to this interface so we can automatically populate the line number and file in our custom spring parsers this could then drive the default setting.

Having now had a dangerous level of exposure to the SP I really want to reach for multiple inheritance to do this, but I suspect that we can manage most of the work with helper classes.

If we made this wider, is there some wunder-SAL which we could inject to populate this stuff from native Spring? 

I'll leave that to to consider as oart of the winder V4 story

 

Environment

None

Activity

Rod Widdowson May 27, 2019 at 3:55 PM

Not going to happen

Rod Widdowson April 12, 2019 at 12:25 PM

I'm inclined to think that this would have been nice to add when we started this, but is it worth the effort to retrofit. Probably not and I'm not aware of people reporting problems working out what log messages refer to what.

Unless anyone pushed back I'll close this in a week.

Rod Widdowson January 12, 2019 at 2:04 PM

The next stage of course will be to use the logprefix in the logging.

Won't Do

Details

Assignee

Reporter

Components

Created January 12, 2019 at 2:01 PM
Updated July 1, 2019 at 11:47 PM
Resolved May 27, 2019 at 3:55 PM