jackrabbit-oak-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Felix Meschberger <fmesc...@adobe.com>
Subject Re: oak api : initial draft
Date Thu, 29 Mar 2012 16:24:15 GMT

Am 29.03.2012 um 11:55 schrieb Jukka Zitting:

>> (6) CommitFailedException is a checked exception. Do we really want this?
> I do, but others disagree. To be discussed.
>> In addition, we said, there should be a root exception, right ?
> Why? This is a specific, strongly typed part of the commit() signature
> as drafted. I don't (yet) see a need for it to be related to any other
> exception in the API.
> Most notably I don't see much need for a generic "Oak-" or
> "RepositoryException" that a client can't do anything reasonable with.
> Let's just use RuntimeException for such cases.

Well, if I cannot do anything about the exception, this is a sure sign for a RuntimeException.
But I might still want to catch them regardless of the actual detail and do something about
it. Having a common root exception here helps tremendously. Otherwise I would have to catch
all sorts of exceptions and replicate the same actions.

Having a common root exception does not hurt the implementation but helps the user.

View raw message