Community Tip - Your Friends List is a way to easily have access to the community members that you interact with the most! X

Translate the entire conversation x

Audit Log Purge Scheduler

MaiteFarreny
10-Marble

Audit Log Purge Scheduler

I am using Windchill PDMLink Release 13.0.2.1

Is it possible to create a monthly Audit Log Purge task, to maintain only the entries of the last 12 month? For example, if the date of the schedelud job is 01/02/2025, it should delete all the entries before 01/02/2024, and keep only the entries between 01/02/2024 and 01/02/2025.

Thanks in advance.
Maite

7 REPLIES 7
avillanueva
22-Sapphire III
(To:MaiteFarreny)

I do not have 13 yet. Can you screen shot interface? Help docs do not image details but other places allow for relative options for date like days back.

I asked the same question to Tech Supt when audit log purge was introduced. As far as I know, what you want to do is not possible with the OOTB functionality.

https://support.ptc.com/help/windchill/r13.0.2.0/en/#page/Windchill_Help_Center/auditadmin/AuditAdminAuditLogPurgeScheduler.html

  • Duration assumes you want to purge everything from today going back.  We have "Last Year" and "Last Month" which sound like they may skip the more recent entries.  However, I think "Last Year" will purge out all of 2024 on January 1 2025 and "Last Month" will do the same on a monthly basis.
  • Start and end dates are static, not relative.

Short of customization, I am not aware of any way to do what you want.

@MaiteFarreny 

Mr Meadows is correct.  No can do OOTB.

However, you can certainly write a class and schedule it to run once a month (or whatever) and have it delete all entries before the current date - 1 year.

This is no problem to do.

 

Rest assure to do what you are asking is quite doable.

Any good Windchill consulting firm should be able to write and implement this for you.

Hello all,

Thank you very much for your feedback. This confirm what we suspected!

Start and end date of purge criteria are static, this is the main problem. And if you try to select criteria by duration, it doesn't have the option of "keep last year" or something like this.

Of course, you could do it manually, but the end customer does not want to have to take care about that.

Let me share some screenshot to make it more clear to @avillanueva 

MaiteFarreny_0-1737455647169.png

MaiteFarreny_1-1737455656575.png

Best regards,

Maite

 

 

 

@MaiteFarreny 

Is this what you are looking for?

 

d_graham_0-1737458519885.png

 

avillanueva
22-Sapphire III
(To:d_graham)

If you are needed the API to create a scheduled queue:

ScheduleQueueEntry entry = AttributeServerAccess.addQueueEntry(queue, principal, method, classIdentity, argTypes, arguments, timestamp);

There is an example. I am sure you can create one via the API, see how its defined in the database and replicate. @mmeadows-3 makes a good point that this appears to be a shortcoming in the spec. Should have been a relative sliding windows otherwise, why would you run this ever on a schedule? So, in summary. Not possible currently. Customization is possible and plenty of folks out there who can write this. Personally, easy enough to set a reminder 4 times a year to run a one time job with specific time periods.

yes, exactly this 😅

Announcements



Top Tags