Eclipse/OSGI provides a log framework that can be accessed from the bundle activator class. Maybe it should be returned as feedback to the user (logging with Eclipse is equivalent of of flying into a back hole and should be restricted for debugging/support)
Jeff On Thu, Dec 4, 2014 at 9:12 AM, Emmanuel Lécharny <[email protected]> wrote: > Hi guys, > > while working on the new configuration pli-ugin, I see that we generate > tons of exceptions (mainly NumberFormatException when validating things > like the Port, etc) when we fill wrong values. In some case, we do > validate the input char by char, or we validate the full input as a > whole, etc. > > Not a pb. > > Now, the thing is that those exceptions - and the associated stack trace > - are pollution. I can catch most of them, and generate a decent error > message instead, but the question is : > - where should I log the info ? > - should I declare a Logger ? > - Is this something we can ask the eclipse platform to log ? > > What is the best practice? > > Thanks ! > > -- Jeff MAURY "Legacy code" often differs from its suggested alternative by actually working and scaling. - Bjarne Stroustrup http://www.jeffmaury.com http://riadiscuss.jeffmaury.com http://www.twitter.com/jeffmaury
