[rt-users] RTx::Shredder to delete old tickets

Ruslan U. Zakirov cubic at acronis.ru
Wed Jul 14 11:23:37 EDT 2004


Vivek Khera wrote:
> 
> On Jul 14, 2004, at 7:40 AM, Ruslan U. Zakirov wrote:
> 
>> No script (rtx-shredder) is not full featured.
>> You can easy comment out Limit(FIELD => 'Status', VALUE => 'deleted') 
>> or add another Limit condition.
>>
>> If you want delete more then 1k tickets at once you need much memory. 
>> I had big memory footprint with 20k tickets, because of it I did step 
>> by step wiping out. I'll fix this problem next release.
> 
> 
> We need to all join my occasional pestering of Jesse to fully support 
> foreign key references in the database. :-)
You can start from converting constrints.mysql file to other back-ends. :)

I sent updated contraints(FULL) to devel list with comments where FK 
have to be but is imposible to create because of RT design, for example 
global queue is '0', but there is no record with id '0' in 'Queues' table.

I don't know why Jesse doesn't move to full FK coverage.

There is also places where it's imposible to create FK: Attributes, 
Principals.
> 
> The shredder script will then consist of something like "delete from 
> tickets where status='deleted'" and the FK references will take care of 
> chasing down all the references and purging them as well. You could then 
> just alter that delete query with whatever where clause you wanted to 
> suit your needs.
This is not just script, it's distro. Big todo entry is "write export 
tool", this mean: you do delete and get copy in file with all deps, then 
you can return object back or insert it into another RT instance(for 
example into 'archive RT instance').


Wishes, Feedback are wellcom as usual ;)
				Ruslan.
> 
> _______________________________________________
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
> 
> Be sure to check out the RT wiki at http://wiki.bestpractical.com




More information about the rt-users mailing list