Preventing the use of unwanted type definitions

Technote (troubleshooting)


Problem(Abstract)

How do you suppress the use of an unwanted type definition in Rational Synergy?

Symptom

There may be one or more type definitions in your Rational Synergy database that for various reasons should no longer be used. Type definitions cannot be deleted if objects in the database are using them.


Resolving the problem

To suppress the use of unwanted type definitions, use the classic client to edit the type definition and remove all of the file patterns and extensions that map to it:

1. Set your role to type_developer, select Admin->Type Definition, and then specify the type.

2. Select Type > Modify Migrate Rules, and then click File Match Patterns in the two text fields.

3. Click the corresponding Remove button, and then click OK and Update Type.


    This action prevents the automatic selection of the type based on filename, but it does not prevent a user from manually selecting the type.

4. To prevent a user from manually selecting the type, create an engine trigger to prevent files using the type from getting created.

    a. As ccm_root on the UNIX server, edit <dbpath>/lib/notify/Unix/Trig_eng.def.

    b. If there is a pretransition block that is not commented, add the following trigger. For example:

        <unwanted type>

        {

        working failscript displayname cvtype;

        }

        If not, wrap it in a pretransition block:

        pretransition {

        <unwanted type>

        {

        working failscript displayname cvtype;

        }

        }

    c. Create the 'failscript' script in the same directory. It needs to contain only the script header, an error echo statement, and a non-zero return code:

      #!/bin/sh

      echo "MSG: Creation of object $1 using type '$1' prohibited in this database. Choose a different type instead."

      exit 1

5. Verify that the failscript is executable; for example, "chmod 755 failscript".

6. Restart any traditional mode sessions and refresh the database so that all web mode sessions have requests serviced by new backend sessions.

7. You must refresh the database because all newly started sessions execute the trigger:


    ccmdb refresh

Now, when an attempt is made to create an object using the type, the operation fails and the user sees this message: "Creation of object <name-version> using type <type> prohibited in this database. Choose a different type instead." This message is also written to the user's message view, so they can determine the source of their problem.

Rate this page:

(0 users)Average rating

Add comments

Document information


More support for:

Rational Synergy
General Information

Software version:

6.3, 6.4, 6.5a, 6.5, 6.6a, 7.0, 7.1a, 7.1, 7.1.0.1, 7.1.0.2, 7.1.0.3, 7.1.0.4

Operating system(s):

AIX, HP-UX, Linux, Solaris, Windows

Reference #:

1516159

Modified date:

2012-10-31

Translate my page

Machine Translation

Content navigation