How Can I Start from Scratch with Exalate?

    Introduction

    You have been testing the heck out of the Exalate, and now it is time to start from scratch. But your Jira database has now all these exalate related tables.


    This document details how to drop all these tables.

    Warning: Be sure to make a backup before proceeding.

    Approach

    The following steps need to be followed:

    1. Uninstall Exalate
    2. Drop all Exalate Tables
    3. Drop the records related to Exalate Upgrade tasks
    4. Restart Jira
    5. Install Exalate

    Steps 2 and 3 require SQL commands

    MYSQL Specific Queries

    Drop All Exalate Tables

    DROP TABLE jira.AO_08F1AF_TRIGGER_CONFIG_DTO;
    DROP TABLE jira.AO_08F1AF_PROGRESS_TRACKER;
    DROP TABLE jira.AO_08F1AF_LIFECYCLE_DTO;
    DROP TABLE jira.AO_08F1AF_NODE;
    DROP TABLE jira.AO_08F1AF_ERROR;
    DROP TABLE jira.AO_08F1AF_ASSIGNED_LICENSE;
    DROP TABLE jira.AO_08F1AF_LICENSE;
    DROP TABLE jira.AO_08F1AF_TRIGGER;
    DROP TABLE jira.AO_08F1AF_TRACE;
    DROP TABLE jira.AO_08F1AF_TWIN_TRACE;
    DROP TABLE jira.AO_08F1AF_BLOB_EVENT;
    DROP TABLE jira.AO_08F1AF_BLOB_REQUEST;
    DROP TABLE jira.AO_08F1AF_BLOB_METADATA;
    DROP TABLE jira.AO_08F1AF_SYNC_REQUEST;
    DROP TABLE jira.AO_08F1AF_SYNC_EVENT;
    DROP TABLE jira.AO_08F1AF_CONNECT_CONTEXT;
    DROP TABLE jira.AO_08F1AF_REPLICA;
    DROP TABLE jira.AO_08F1AF_INSTANCE;
    DROP TABLE jira.AO_08F1AF_NODE_INFO;
    DROP TABLE jira.AO_08F1AF_RELATION;

    Drop the Records Related to Exalate Upgrade Tasks

    DELETE FROM jira.propertystring where id = (SELECT id FROM jira.propertyentry where property_key = 'AO_08F1AF_#');
    DELETE FROM jira.propertyentry where property_key = 'AO_08F1AF_#';

    Postgres Specific Queries

    Drop All Exalate Tables

    DROP TABLE "AO_08F1AF_TRIGGER_CONFIG_DTO";
    DROP TABLE "AO_08F1AF_PROGRESS_TRACKER";
    DROP TABLE "AO_08F1AF_LIFECYCLE_DTO";
    DROP TABLE "AO_08F1AF_NODE";
    DROP TABLE "AO_08F1AF_ERROR";
    DROP TABLE "AO_08F1AF_ASSIGNED_LICENSE";
    DROP TABLE "AO_08F1AF_LICENSE";
    DROP TABLE "AO_08F1AF_TRIGGER";
    DROP TABLE "AO_08F1AF_TRACE";
    DROP TABLE "AO_08F1AF_TWIN_TRACE";
    DROP TABLE "AO_08F1AF_BLOB_EVENT";
    DROP TABLE "AO_08F1AF_BLOB_REQUEST";
    DROP TABLE "AO_08F1AF_BLOB_METADATA";
    DROP TABLE "AO_08F1AF_SYNC_REQUEST";
    DROP TABLE "AO_08F1AF_SYNC_EVENT";
    DROP TABLE "AO_08F1AF_CONNECT_CONTEXT";
    DROP TABLE "AO_08F1AF_REPLICA";
    DROP TABLE "AO_08F1AF_INSTANCE";
    DROP TABLE "AO_08F1AF_NODE_INFO";
    DROP TABLE "AO_08F1AF_RELATION";

    Drop the Records Related to Exalate Upgrade Tasks

    DELETE FROM propertystring where id = (SELECT id FROM propertyentry where property_key = 'AO_08F1AF_#');
    DELETE FROM propertyentry where property_key = 'AO_08F1AF_#';

    Oracle Specific Queries

    Select Sequences Related to Exalate DB

    SELECT sequence_name
    FROM user_sequences
    WHERE sequence_name like '%AO_08F1AF%';

    Select Triggers Related to Exalate DB

    SELECT
        trigger_name,
        trigger_type,
        triggering_event,
        table_owner,
        table_name,
        base_object_type,
        status,
        trigger_body    
    FROM
        user_triggers
    WHERE trigger_name like '%AO_08F1AF%'
    ORDER BY
        trigger_name ASC,
        base_object_type ASC,
        table_name ASC;

    Drop All Exalate Tables

    DROP TABLE AO_08F1AF_TRIGGER_CONFIG_DTO;
    DROP TABLE AO_08F1AF_PROGRESS_TRACKER;
    DROP TABLE AO_08F1AF_LIFECYCLE_DTO;
    DROP TABLE AO_08F1AF_NODE;
    DROP TABLE AO_08F1AF_ERROR;
    DROP TABLE AO_08F1AF_ASSIGNED_LICENSE;
    DROP TABLE AO_08F1AF_LICENSE;
    DROP TABLE AO_08F1AF_TRIGGER;
    DROP TABLE AO_08F1AF_TRACE;
    DROP TABLE AO_08F1AF_TWIN_TRACE;
    DROP TABLE AO_08F1AF_BLOB_EVENT;
    DROP TABLE AO_08F1AF_BLOB_REQUEST;
    DROP TABLE AO_08F1AF_BLOB_METADATA;
    DROP TABLE AO_08F1AF_SYNC_REQUEST;
    DROP TABLE AO_08F1AF_SYNC_EVENT;
    DROP TABLE AO_08F1AF_CONNECT_CONTEXT;
    DROP TABLE AO_08F1AF_REPLICA;
    DROP TABLE AO_08F1AF_INSTANCE;
    DROP TABLE AO_08F1AF_NODE_INFO;
    DROP TABLE AO_08F1AF_RELATION;

    Drop the Records Related to Exalate Upgrade Tasks

    DELETE FROM propertystring where id = (SELECT id FROM propertyentry where property_key = 'AO_08F1AF_#');
    DELETE FROM propertyentry where property_key = 'AO_08F1AF_#';

    Delete Sequences Related to Exalate DB (found using SELECT Query)

    DROP SEQUENCE AO_08F1AF_INSTANCE_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_TRIGGER_C1385222053;
    DROP SEQUENCE AO_08F1AF_ASSIGNED_963171988;
    DROP SEQUENCE AO_08F1AF_BLOB_EVENT_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_BLOB_METADATA_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_BLOB_REQUEST_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_CONNECTIO1923667556;
    DROP SEQUENCE AO_08F1AF_CONNECT_C2013118358;
    DROP SEQUENCE AO_08F1AF_ERROR_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_ISSUE_TRA1842524094;
    DROP SEQUENCE AO_08F1AF_LICENSE_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_LIFECYCLE_DTO_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_MAPPINGS_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_MESSAGE_CHUNK_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_MESSAGE_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_NODE_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_NODE_INFO_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_OAUTH_CLI876533495;
    DROP SEQUENCE AO_08F1AF_OAUTH_DATA_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_PROGRESS_509391230;
    DROP SEQUENCE AO_08F1AF_RELATION_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_REPLICA_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_SCOPES_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_SYNC_EVENT_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_SYNC_REQUEST_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_TRACE_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_TRIGGER_C1385222053;
    DROP SEQUENCE AO_08F1AF_TRIGGER_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_TWIN_TRACE_ID_SEQ;
    DROP SEQUENCE AO_08F1AF_USER_PROP1904968727;

    Delete Triggers Related to Exalate DB (found using SELECT Query)

    DROP TRIGGER AO_08F1AF_MESSAGE_ID_autoinc;
    DROP TRIGGER AO_08F1AF_SCOPES_ID_autoinc;
    DROP TRIGGER AO_08F1AF_CONNECTIO462412940;
    DROP TRIGGER AO_08F1AF_OAUTH_DAT1936484318;
    DROP TRIGGER AO_08F1AF_ISSUE_TRA1464368722;
    DROP TRIGGER AO_08F1AF_MAPPINGS_ID_autoinc;
    DROP TRIGGER AO_08F1AF_OAUTH_CLI216161657;
    DROP TRIGGER AO_08F1AF_MESSAGE_C1497201301;
    DROP TRIGGER AO_08F1AF_USER_PROP1060339321;
    DROP TRIGGER AO_08F1AF_BLOB_REQU793174887;
    DROP TRIGGER AO_08F1AF_SYNC_REQU865768535;
    DROP TRIGGER AO_08F1AF_INSTANCE_ID_autoinc;