I want to discuss how to handeled cross cutting concern like logging, authorisation and in some case persistence in an ABAP application.
In ABAP I see currenlty two approaches:
I. interface-based cross-cutting concerns resolution
Encapulate cross-cutting concerns via a interface and having a configuration manager which delivers a singleton on your cross cutting conerns aspect (-> authorisation)
II. event-based cross-cutting concerns resolution
Having an interace with an event and dynamically assign a event handler (-> logging)
In order to handeled cross-cutting I see two main factors which improve your code:
A. Business logic is free from cross-cutting concerns beside hocks to them
B. Depend on your deployment phase you adopt the application behaviour
Are the idea valid on handeling cross-custing concerns? Are there are other apporaches? Do you have concerns about cross-cutting conerns?
All the best,