tag:blogger.com,1999:blog-18772002.post1405719893830431968..comments2023-12-06T19:00:46.094+00:00Comments on OSGi Blog: Error MessagesJürgen Alberthttp://www.blogger.com/profile/02725834158183495837noreply@blogger.comBlogger9125tag:blogger.com,1999:blog-18772002.post-3614885098357567232011-01-17T16:02:46.141+00:002011-01-17T16:02:46.141+00:00The important thing to remember here is that we ar...The important thing to remember here is that we are discussing the exact content of an exception message, so I question how useful the formatting will be.<br /><br />Regarding LDAP filters, they are definitely not ideal, but they aren't terrible either. And given that they are the Felix resolver's internal model then that's all there is (there is no manifest format in memory). In Unknownhttps://www.blogger.com/profile/05901039297072423888noreply@blogger.comtag:blogger.com,1999:blog-18772002.post-39649406884771234032011-01-17T09:21:24.104+00:002011-01-17T09:21:24.104+00:00You may like to compare a similar uses constraint ...You may like to compare a similar uses constraint error message produced by Eclipse Virgo as we put quite a bit of effort into readability:<br /><br />org.eclipse.virgo.kernel.osgi.framework.UnableToSatisfyBundleDependenciesException: Unable to satisfy dependencies of bundle 'a' at version '0.0.0': Cannot resolve: a<br /> Resolver report:<br /> Uses violation: <Glynhttps://www.blogger.com/profile/08741529390385812080noreply@blogger.comtag:blogger.com,1999:blog-18772002.post-73909363040123555542011-01-14T18:44:37.223+00:002011-01-14T18:44:37.223+00:00Displaying the information in LDAP filter syntax i...Displaying the information in LDAP filter syntax is hard for humans.<br /><br />Why not:<br /><br />import: foo; version=[1.0.0,2.0.0)<br /><br />instead of:<br /><br />import: (&(package=foo)(version>=1.0.0)(!(version>=2.0.0)))<br /><br />package= is redundant information and breaking the version range into the LDAP filter syntax is confusing.<br /><br />This seems to be leaking BJ Hargravehttps://www.blogger.com/profile/02289107040084648957noreply@blogger.comtag:blogger.com,1999:blog-18772002.post-19737345441380830292011-01-14T16:57:49.264+00:002011-01-14T16:57:49.264+00:00IMHO, a textual representation is a bad choice whe...IMHO, a textual representation is a bad choice when explaining (dependency) graphs. Have you ever seen a teacher or professor explaining graph problems (exclusively) by writing text on a blackboard?<br /><br />Another idea: <br />* reduce the textual output intended for direct human consumption to a minimum (error code plus one short sentence).<br />* generate a machine-readable description of VerboseOutputhttps://www.blogger.com/profile/12592669857171450761noreply@blogger.comtag:blogger.com,1999:blog-18772002.post-77261887976179790972011-01-14T16:29:59.412+00:002011-01-14T16:29:59.412+00:00We can improve it further by getting rid of the ld...We can improve it further by getting rid of the ldap qualifiers, at least for disjunctive normal form. <br /><br />Consider these two fragments:<br /><br />(&(package=bar)(version>=1.0.0)(!(version>=2.0.0)))<br /><br />package=bar && version >= 1.0.0 && version < 2.0.0<br /><br />Which would an average Java developer understand more quickly?AlBluehttps://www.blogger.com/profile/06362201865553416948noreply@blogger.comtag:blogger.com,1999:blog-18772002.post-14568547889119942492011-01-14T15:44:24.825+00:002011-01-14T15:44:24.825+00:00I like it, too. However I also believe the specifi...I like it, too. However I also believe the specific error code should be something that makes it easy to Google for. On my blog some posts get huge amounts of hits, because people are searching for a rare but very specific exception text, making my solution the top hit in Google. So I second Maarten's idea.<br /><br />But additionally I would rephrase the first line like this:<br /><br />[Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-18772002.post-89808465434503221642011-01-14T15:14:58.089+00:002011-01-14T15:14:58.089+00:00I think you are working in the right direction, bu...I think you are working in the right direction, but you fail to lever the power of the Google search on a short but unique error message. I think this is what all developers do when seeing an error message.<br /> <br />Maybe setup and include a unique URL for each problem, where the uninitiated can find background info and possible resolutions. Maybe something for ?lanetOSGI.Maarten Meijerhttps://www.blogger.com/profile/05900699818398561644noreply@blogger.comtag:blogger.com,1999:blog-18772002.post-72884976283124108382011-01-14T13:25:13.701+00:002011-01-14T13:25:13.701+00:00Peter,
I like the code for the error. I don't...Peter,<br /><br />I like the code for the error. I don't like the background info. And I like the import/export graph.<br /><br />The "code for error" makes it easier to search for it over the Internet. This is (still) used by databases to report errors, and it's very useful so you can find possible causes and fixes. <br /><br />I don't like the background info, because thatLeohttps://www.blogger.com/profile/13072499088370397789noreply@blogger.comtag:blogger.com,1999:blog-18772002.post-43476988039009585622011-01-14T11:51:19.650+00:002011-01-14T11:51:19.650+00:00Peter,
I think you are spot on. I really like the...Peter,<br /><br />I think you are spot on. I really like the layout of the last error message, where you provide some background information and also visually match up imports and exports.Rémon Sinnemahttps://www.blogger.com/profile/15281943692102330531noreply@blogger.com