subclassing Spring's controllers

Discussion in 'Java' started by s o, Aug 12, 2006.

  1. s o

    s o Guest

    Hi all,

    we're starting a new project using Spring with a Oracle db. We have
    some housekeeping/infrastructure task that needs to be procssed for
    almost every web request (e.g. auditing the request.) what would be a
    good approach to this? Does Spring's different controllers already
    offer a hook for this? I was thinking putting a layer betwn my
    controllers and spring's controllers. For example: MySimpleFormBase
    extends SimpleFormController, MyMultiActionBase extends
    MultiActionController. This should work but not very elegant. Can
    anyone shed some lights on this? thanks.

    s o
     
    s o, Aug 12, 2006
    #1
    1. Advertisements

  2. s o

    goobledigook Guest

    Have you thought about using AOP for this type of stuff? Spring
    (especiall v.2 coming up soon) offers great facilities for wrapping any
    business object with aspects which you should use for
    logging/auditing/...

    s o wrote:
    > Hi all,
    >
    > we're starting a new project using Spring with a Oracle db. We have
    > some housekeeping/infrastructure task that needs to be procssed for
    > almost every web request (e.g. auditing the request.) what would be a
    > good approach to this? Does Spring's different controllers already
    > offer a hook for this? I was thinking putting a layer betwn my
    > controllers and spring's controllers. For example: MySimpleFormBase
    > extends SimpleFormController, MyMultiActionBase extends
    > MultiActionController. This should work but not very elegant. Can
    > anyone shed some lights on this? thanks.
    >
    > s o
     
    goobledigook, Aug 12, 2006
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    0
    Views:
    445
  2. Desperate
    Replies:
    0
    Views:
    1,195
    Desperate
    Aug 31, 2006
  3. Rob
    Replies:
    0
    Views:
    843
  4. Nick P. Jr.

    Using C30 and dsPIC Microchip controllers

    Nick P. Jr., Aug 7, 2005, in forum: C Programming
    Replies:
    0
    Views:
    565
    Nick P. Jr.
    Aug 7, 2005
  5. Nick P. Jr.
    Replies:
    0
    Views:
    486
    Nick P. Jr.
    Aug 7, 2005
  6. rmn190
    Replies:
    2
    Views:
    2,930
    Arne Vajhøj
    Jan 10, 2008
  7. Goldfish
    Replies:
    1
    Views:
    1,022
    Goldfish
    Nov 6, 2008
  8. Gerry
    Replies:
    2
    Views:
    254
    Gerry
    Jul 31, 2003
Loading...