Managing the Profiles event log
Use Profiles administrative commands to manage the Profiles event log.
Before you begin
To run administrative commands, you must use the wsadmin client. See Starting the wsadmin client for information about how to start the wsadmin command-line tool.
About this task
By default, records that are more than 30 days old are automatically purged from the event log. For information about how to modify the setting that controls this interval, see Configuring event log clean-up for Profiles.
Procedure
- Start the wsadmin client from the following
directory of the system on which you installed the Deployment Manager:
where app_server_root is the WebSphere® Application Server installation directory and dm_profile_root is the Deployment Manager profile directory, typically dmgr01.app_server_root\profiles\dm_profile_root\bin
You must start the client from this directory or subsequent commands that you enter do not execute correctly. For more information, see Starting the wsadmin client.
- Start the Profiles Jython script interpreter.
- Use the following commands as required.
- ProfilesService.purgeEventLogsByDates(string startDate, string endDate)
Deletes event log entries created between the specified start date and end date.
This command takes the following parameters:- startDate
- A string that specifies the start date for the period in MM/DD/YYYY format.
- endDate
- A string that specifies the end date for the period in MM/DD/YYYY format.
For example:
This command deletes all the event log entries that were created on or after June 21st, 2009 and before June 26th, 2009 from the EVENTLOG table.ProfilesService.purgeEventLogsByDates("06/21/2009", "06/26/2009")
- ProfilesService.purgeEventLogsByEventNameAndDates(eventName, string startDate, string endDate)
Deletes event log entries with the specified event name that were created between given start date and end date.
This command takes the following parameters:- eventName
- The type of event that you want to remove from the EVENTLOG table. The following names are some
examples of valid event names:
- profiles.created
- profiles.removed
- profiles.updated
- profiles.person.photo.updated
- profiles.person.audio.updated
- profiles.colleague.created
- profiles.colleague.added
- profiles.connection.rejected
- profiles.person.tagged
- profiles.person.selftagged
- profiles.tag.removed
- profiles.link.added
- profiles.link.removed
- profiles.status.updated
- profiles.wallpost.created
- profiles.wallpost.removed
- profiles.wall.comment.added
For a complete list of valid event names for Profiles, refer to the Events Reference article in the API Documentation wiki.
- startDate
- A string that specifies the start date for the period in MM/DD/YYYY format.
- endDate
- A string that specifies the end date for the period in MM/DD/YYYY format.
For example:
This command deletes all the profiles.colleague.created event log entries that were created on or after June 21st, 2009 and before June 26th, 2009 from the EVENTLOG table.ProfilesService.purgeEventLogsByEventNameAndDates("profiles.colleague.created", "06/21/2009", "06/26/2009")