db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jørgen Løland <Jorgen.Lol...@Sun.COM>
Subject Re: [jira] Commented: (DERBY-3021) Replication: Add a ReplicationSlave controller that will manage replication on the slave side
Date Thu, 06 Sep 2007 06:48:16 GMT
Dag H. Wanvik wrote:
> "Jørgen Løland (JIRA)" <jira@apache.org> writes:
>> Any thoughts on whether the most appropriate error code for this would be:
>> * XRE02.C since it is a replication error message with session severity, or
>> * 0800x (e.g., 08006 - connection failure) since this is a connection error? 
> 08006 seems to be a network client error, wouldn't a new 08004 (the
> server is there but rejects the connection for some reason...) be more
> in the spirit of existing allocations? But I am OK with XRE02.C, too.
> I looked at some other non-"08xxx" which have session severity level
> in Derby, but am not sure they give much guidance. Maybe we should
> prefer 08004 when reasonble, since this has standard SQL semantics
> (not implementation defined). In JDBC 4 this SQLSTATE class has a
> defined mapping to SQL(Non)TransientConnectionExceptions, too.
> I must admit I feel a bit out on a limb, here, so it someone has any
> general guidelines for how to allocate new error codes in Derby, I,
> for one, would appreciate it.

I agree; it makes sense to use existing SQL codes whenever possible and 
new, custom error codes when the message does not fit anywhere else.

Hence, in this case, 08004 seems to be the better choice.

Jørgen Løland

View raw message