There are couple places in the OSGI API that expect different behavior than the MC. One
example is the Bundle getEntry and getEntryPaths methods. These methods should return
'null' in if the entry can not be found within the Bundle. The call to the
DeploymentUnit to get the file will result in a RuntimeException wrapped
FileNotFoundException, which makes sense, as the file does not exist. In this case I
think the Bundle methods should catch the Exception and return 'null'. Should we
catch it here, or propagate to client?
The main question I have if the Exception is caught, is how to log it. I would guess we
would want the information available if the client makes the call, but we don't want
to log it as an error and flood the log, for a call that is valid. Should the
Exception/message be logged at the DEBUG or INFO level so the client could get it if they
think the call should have resulted in something?
I would also like to know if there are any ground rules on logging and Exception handling
to follow.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4133252#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...