PeHeX (Perl Hook eXtractor) is a utility that solves to the hook problematics.
PeHeX extracts the code of all Perl hooks of a ClearQuest schema, then replaces each of them by a single call to an external procedure, then stores the extracted code in external files, finally adds to the schema a global hook named GlobalUse that calls all the generated external Perl modules.
The procedure and file names, the structure of external files follow simple naming rules, explained through the examples below:
As an example, here is the file Defect_hooks.pl, from the Enterprise schema. Some code redundancies are now immediately visible, and can be easily factorised. It was not obvious to detect them through the Designer editor.
PeHex is not a product, but rather a service: the customer sends a dump file of her schema, it is sent back with updated hooks and the associated set of Perl files.