Re: Initial questions, thoughts & suggestions

From: Andrus (andru..bjectstyle.org)
Date: Mon Sep 02 2002 - 14:29:31 EDT

  • Next message: Magic Hat: "Re: Initial questions, thoughts & suggestions"

    Hi PA,

    thanks a lot for offering help ;-). Like I said we need it, especially from
    people who really understand the underlying concepts.

    At 07:38 PM 9/2/2002 +0200, Magic Hat wrote:
    >>>- am I right that there is currently no validation suport (as in
    >>>validateXForY) or did I just overlook something in the APIs?
    >>
    >>You are right. It is not there. We have no specific plans for it yet, so
    >>there is lots of room for discussion.
    >
    >I have to implement some validation for my own needs. I was thinking to
    >basically clone NSValidation. If you don't see any major flow with that
    >mechanism I can contribute it to Cayenne.

    I would suggest that invocation of validation methods should be external to
    DataObject. If we are talking about persistence for arbitrary classes in
    the future, we don't want to force yet another interface on the class
    implementors. Maybe the object being validated may implement
    "validateXProperty" methods (without implementing any particular
    interface), but the actual invocation code should be in a separate class.
    Same with EOValidation-like functionality for insert/delete/update.

    I wonder if something like Jakarta DynaBeans would be a good starting point
    for such implementation?

    >>I totally agree. Originally we did not implement any notifications,
    >>delegates and such, because the flow of events in the access layer was
    >>changing all the time. Now the overall flow seems to be rather stable,
    >>and it is the right time to start designing such things. I am not ready
    >>to suggest anything at the moment, but we need to start this work.
    >
    >I built a little NSNotificationCenter clone if you guys are interested. It
    >does distributed notification as well.

    I remember you posted it on wo-dev list. I haven't looked at it closely
    though.

    It looks like we need two things in this area:

      - delegates that are notified *before* something is about to happen, so
    that they can affect the flow
      - notifications that are sent to observers about various events after the
    fact. This is where your notification center might be needed. What do you
    use for distributed notifications? HTTP? Sockets? Multicast? We may also
    look into other ways for distributed notifications. I think TopLink uses
    JMS for that. Cause if we ever get into cache synchronization, message flow
    will be overwhelming.

    In any event, I guess we may start with defining the events needed.

    Andrus



    This archive was generated by hypermail 2.0.0 : Mon Sep 02 2002 - 14:29:49 EDT