Since for many if us Metrics are very important and should be always in-line and for some it's not very important as well. As in system there is an OOTB trigger Daily Metrics which updates the metrics of all active projects and libraries including documents underneath it.
Issue:- Since this trigger is based on beans which provides very fast performance but there is an issue in this trigger if let's say this trigger has to process 1000 documents and in 600th document some entries are wrong e.g. Assigned User is no more part of LDAP and this is very common issue everywhere. In this situation trigger will stop here and rest 400 documents are never processed. This is the reason metrics are not at all updated since long time in some of the documents. And manually need to turn on debug log and go through entire log to check which is corrupted document.
Solution:- I have written existing trigger in different way and following improvements i made:-
- Trigger goes till end no matter how many documents and projects are in-between with invalid or corrupted entries.
- At the end a notification to selected administrator how many documents successfully updated, how many failed, how many projects/libraries updated and how many not.
- Same email also contain table containing entries of documents and projects failed to update including error and action steps (how to solve?), project these documents belongs to etc.
- Also automatic email to project manager about there documents where metrics got failed to update including action steps.
- Same script can also be called from individual project and library so no need to wait for next day when trigger will run e.g. overnight. This is very helpful if any project metrics need to update on need basis may be for meeting, discussion or dashboard could be anything. But project manager can run for there own project.
- In above email to project manager about status. (Who is running the above action)
- Log file can also be attached in email if any need.
- Clear and Crisp log entries easy to understand and easy to locate error.
- And many more.
Benefits:- Everyday as an administrator i see one email giving me status of this and metrics are always updated. In case of any issue i or related project manager can react quickly.
Happy to see how you are handling this at your side.
Feel free to give your views and ideas.
Vielen Dank / Many Thanks,