public inbox for frysk@sourceware.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mark@klomp.org>
To: Phil Muldoon <pmuldoon@redhat.com>
Cc: frysk@sourceware.org
Subject: Re: fhpd vs RuntimeExceptions
Date: Fri, 16 Nov 2007 11:21:00 -0000	[thread overview]
Message-ID: <1195212076.3001.45.camel@dijkstra.wildebeest.org> (raw)
In-Reply-To: <473C8D99.4060107@redhat.com>

Hi Phil,

On Thu, 2007-11-15 at 18:19 +0000, Phil Muldoon wrote:
> Mark Wielaard wrote:
> > On Thu, 2007-11-15 at 17:01 +0000, Phil Muldoon wrote:
> >   
> >> As talked about on IRC over the corefile 
> >> message design, exceptions can and are used to carry warnings, messages 
> >> and so on. How do you differentiate between a warning and an error in 
> >> this case?
> >
> > By using different exception types, so a higher level can distinquish
> > between a "recoverable" warning and a "unrecoverable" error.

> Like I mentioned in reply to Sami's email yesterday, having a napi throw 
> several different unchecked exception types places a huge and unfair 
> burden on the user to know the code beyond the api. The places "must be 
> an expert on Frysk to call Frysk apis" charge at our feet.

Yes, if we stick with unchecked exceptions then they cannot really be
part of the api (or they need to be very clearly documented). Unless we
define a very small specific set (that doesn't overlap with the core
RuntimeExceptions) that are used consistently in all the code.

> > Yes, I think that is the way forward. Something terribly failed. And
> > just passing the "address 6992f8 cannot be found in metadata table."
> > message to the user is clearly not very helpful if the user just wanted
> > to run a specific command. 
> 
> What would be helpful here? It's a message, not an error? Basically it 
> just means cannot read the address here as we don't know how to read it. 
> I can format the  message however I want, but it is still not an error 
> message. However it sure looks like one now ;)

It is neither a user message, nor an error. I do see your point. You
have only partial information and would let the user know somehow that
you will be unable to perform all requests. I like Kris suggestion to
have a more specific result or exception here that says "Missing Map
Data", then a higher level can decide to act on that and suggest how the
user can help, or suggest what normal causes for such missing/corrupt
information is.

Cheers,

Mark

  parent reply	other threads:[~2007-11-16 11:21 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-14 14:27 Mark Wielaard
2007-11-14 14:45 ` Andrew Cagney
2007-11-14 15:27   ` Kris Van Hees
2007-11-14 15:36   ` Mark Wielaard
2007-11-14 17:33     ` Andrew Cagney
2007-11-14 19:11       ` Mark Wielaard
2007-11-15 17:01 ` Phil Muldoon
2007-11-15 17:42   ` Mark Wielaard
2007-11-15 18:19     ` Phil Muldoon
2007-11-15 18:25       ` Sami Wagiaalla
2007-11-16 11:21       ` Mark Wielaard [this message]
2007-11-15 18:21     ` Sami Wagiaalla
2007-11-15 20:33       ` Kris Van Hees
2007-11-16 10:12       ` Mark Wielaard
2007-11-15 18:46     ` Andrew Cagney
2007-11-16 10:15       ` Mark Wielaard
2007-11-15 20:41     ` Kris Van Hees
2007-11-15 22:11       ` Phil Muldoon
2007-11-15 23:09         ` Kris Van Hees
2007-11-16 10:42       ` Mark Wielaard
2007-11-15 18:04   ` Mark Wielaard
2007-11-15 18:22     ` Phil Muldoon
2007-11-15 19:06     ` Andrew Cagney
2007-11-16 10:28       ` Mark Wielaard
2007-11-16 14:32         ` Andrew Cagney
2007-11-26 10:18           ` Mark Wielaard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1195212076.3001.45.camel@dijkstra.wildebeest.org \
    --to=mark@klomp.org \
    --cc=frysk@sourceware.org \
    --cc=pmuldoon@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).