Open Closed

Audit Logging with Existing/Legacy Tables #3729


User avatar
0
cfd000 created
  • ABP Framework version: v6.0.0
  • UI type: MVC / Blazor
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes

We are slowly replacing the UI for a very large existing application with ABP, and are happy to have the Auditing capabilities. Some entities may be completely controlled (created, updated, and deleted) by the legacy application for quite a while as we work on building out different areas using ABP. We would like to enable Audit Logging for changes to certain tables that are NOT being modified through ABP (although they will be in the same database as the ABP tables). Do you have any suggestions on how to write the appropriate audit log entries for changes made outside of ABP? The legacy application will be doing direct SQL edits, so we are thinking of tracking those changes using triggers.


5 Answer(s)
  • User Avatar
    0
    malik.masis created

    Hi,

    Firstly we are happy to hear your kind words. To enable and disable, there are many different ways on the official documention. Could you have a look it, please? Hopefully, it helps you. I'm not sure but IAuditingManager may be useful for your case.

    Regards.

  • User Avatar
    0
    cfd000 created

    We have no problems using Auditing within ABP. We are looking to populate the audit log tables for changes made OUTSIDE of ABP in our legacy application (which does direct SQL queries, and cannot be modified to use the ABP APIs). Is there a documented approach? If not, is there a specific class we can look at to determine how best to emulate the logic? We have a subscription that includes full source code.

  • User Avatar
    0
    malik.masis created

    Hi,

    We don't have documentation related to this topic but we can suggest using ABP AuditLogging package and implementing IAuditingManager as mentioned above. If it's not possible you should do it manually. ABP already supports all .net features.

    Regards.

  • User Avatar
    0
    cfd000 created

    You keep avoiding answering my direct question.

    We cannot implement any .NET classes because the legacy application is not written by us, it is a 3rd party C++ application which is writing directly to the database.

  • User Avatar
    0
    malik.masis created

    Hi,

    No, just trying to understand your question properly. We don't have documentation regarding this topic, even so, I can share the logic of Auditing to have a look at it. It may guide you.

    Regards.

Made with ❤️ on ABP v8.2.0-preview Updated on March 25, 2024, 15:11