Re: intermittent exception

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Fri Oct 28 2005 - 16:42:20 EDT

  • Next message: Andrus Adamchik: "Re: Reverse Engineer Database Comments?"

    Can't tell why this happens. You may override "writePropertyDirectly"
    on this object to do Thread.dumpStack() whenever this problem occurs.
    This way you'll see where this happens.

    Andrus

    On Oct 28, 2005, at 3:31 PM, Bryan Lewis wrote:

    > We're using Cayenne 1.2M4 in production. We're seeing a rare and
    > intermittent ClassCastException when reading a Boolean property.
    > We have an ExtendedType that converts Oracle 8i integers to
    > Booleans; it's been working fine for a long time and still works
    > fine 99.9% of the time. The exception occurs on a line in the auto-
    > generated super-class such as:
    >
    > public Boolean getIsPremiumClient() {
    > return (Boolean)readProperty("isPremiumClient");
    > }
    >
    > I added some logging messages a week ago and waited for the error
    > to happen again. The readProperty() is returning an Integer rather
    > than the expected Boolean. It's as if our ExtendedType isn't being
    > invoked, once in a blue moon.
    >
    > I'm going to try upgrading or downgrading the version of Cayenne,
    > but I thought I'd ask here too since it could be a while before the
    > error happens again. I didn't see any related items in the last
    > couple of ReleaseNotes.
    >
    >
    >



    This archive was generated by hypermail 2.0.0 : Fri Oct 28 2005 - 16:42:23 EDT