|
| 1 | +# Oracle-to-PostgreSQL Database Migration Plugin |
| 2 | + |
| 3 | +Oracle-to-PostgreSQL migration orchestrator for multi-project .NET solutions with comprehensive migration planning, code transformation, integration testing, and reporting capabilities. |
| 4 | + |
| 5 | +## Installation |
| 6 | + |
| 7 | +```bash |
| 8 | +# Using Copilot CLI |
| 9 | +copilot plugin install o2p-dbmigration@awesome-copilot |
| 10 | +``` |
| 11 | + |
| 12 | +## What's Included |
| 13 | + |
| 14 | +### Agents |
| 15 | + |
| 16 | +| Agent | Description | |
| 17 | +|-------|-------------| |
| 18 | +| `o2p-dbmigration-expert` | Oracle-to-PostgreSQL migration orchestrator for multi-project .NET solutions. Discovers migration-eligible projects, produces a persistent master plan for cross-session tracking, migrates application codebases and stored procedures, runs closed-loop integration testing, and generates migration reports. | |
| 19 | + |
| 20 | +### Skills |
| 21 | + |
| 22 | +| Skill | Description | |
| 23 | +|-------|-------------| |
| 24 | +| `o2p-dbmigration` | Validates PostgreSQL migration artifacts and integration tests, making sure every reference insight is surfaced before agent workflows sign off. Use when proving migration or integration testing work and confirming the repository references/insights are obeyed. | |
| 25 | + |
| 26 | +## Features |
| 27 | + |
| 28 | +### Multi-Project Application Migration |
| 29 | + |
| 30 | +The agent handles multiple application projects sequentially, tracking progress across sessions using a persistent Master Migration Plan: |
| 31 | + |
| 32 | +1. Discovers all migration-eligible projects in the solution |
| 33 | +2. For each project, performs: |
| 34 | + - Application codebase migration |
| 35 | + - Closed-loop integration testing workflow |
| 36 | + - Status tracking and progress updates |
| 37 | +3. Generates comprehensive migration reports |
| 38 | + |
| 39 | +### Closed-Loop Integration Testing |
| 40 | + |
| 41 | +Automated integration testing workflow for each migrated project: |
| 42 | + |
| 43 | +``` |
| 44 | +plan → scaffold → create tests → run → validate → [EXIT or LOOP] |
| 45 | + ↑ │ |
| 46 | + └──── fix ←── bugs ←──┘ |
| 47 | +``` |
| 48 | + |
| 49 | +### Migration Components |
| 50 | + |
| 51 | +- **Application Codebase Migration**: Migrates .NET code from Oracle to PostgreSQL |
| 52 | +- **Stored Procedure Migration**: Converts Oracle stored procedures, functions, and packages to PostgreSQL |
| 53 | +- **Integration Testing**: Creates and runs comprehensive integration tests |
| 54 | +- **Bug Tracking**: Generates bug reports for failed tests and tracks remediation |
| 55 | +- **Migration Reports**: Produces detailed migration outcome documentation |
| 56 | + |
| 57 | +## Prerequisites |
| 58 | + |
| 59 | +- Visual Studio Code with GitHub Copilot |
| 60 | +- PostgreSQL Extension (`ms-ossdata.vscode-pgsql`) |
| 61 | +- .NET solution with Oracle dependencies to migrate |
| 62 | + |
| 63 | +## Directory Structure |
| 64 | + |
| 65 | +The agent expects and creates the following structure in your solution: |
| 66 | + |
| 67 | +``` |
| 68 | +{SOLUTION_ROOT}/ |
| 69 | +└── .github/ |
| 70 | + └── o2p-dbmigration/ |
| 71 | + ├── Reports/ |
| 72 | + │ ├── Master Migration Plan.md |
| 73 | + │ ├── Bug Reports/ |
| 74 | + │ └── Migration Reports/ |
| 75 | + ├── DDL/ |
| 76 | + │ ├── Oracle/ # Oracle DDL scripts (pre-migration) |
| 77 | + │ └── Postgres/ # PostgreSQL DDL scripts (post-migration) |
| 78 | +``` |
| 79 | + |
| 80 | +## Usage |
| 81 | + |
| 82 | +1. **Start Migration**: Invoke the agent with your goal (e.g., "Migrate my solution from Oracle to PostgreSQL") |
| 83 | +2. **Master Plan**: The agent creates a master migration plan tracking all projects |
| 84 | +3. **Per-Project Migration**: Each project is migrated and tested sequentially |
| 85 | +4. **Review Reports**: Check the generated reports for migration status and any issues |
| 86 | + |
| 87 | +## Key Capabilities |
| 88 | + |
| 89 | +- **Cross-Session Tracking**: Resume interrupted migrations from where you left off |
| 90 | +- **Automated Testing**: Comprehensive integration tests generated and executed automatically |
| 91 | +- **Error Handling**: Detailed bug reports with remediation tracking |
| 92 | +- **DDL Management**: Preserves both Oracle and PostgreSQL DDL for reference |
| 93 | +- **Minimal Changes**: Keeps changes minimal, preserving application logic where possible |
| 94 | + |
| 95 | +## Reference Materials |
| 96 | + |
| 97 | +The included skill provides reference guides for common Oracle→PostgreSQL migration patterns: |
| 98 | + |
| 99 | +- Empty strings handling ('' vs NULL) |
| 100 | +- NO_DATA_FOUND exceptions |
| 101 | +- Oracle parentheses in FROM clauses |
| 102 | +- Sorting and collation differences |
| 103 | +- TO_CHAR numeric conversions |
| 104 | +- Type coercion rules |
| 105 | +- REFCURSOR handling |
| 106 | +- Concurrent transactions |
| 107 | + |
| 108 | +## Source |
| 109 | + |
| 110 | +This plugin is part of [Awesome Copilot](https://github.com/github/awesome-copilot), a community-driven collection of GitHub Copilot extensions. |
| 111 | + |
| 112 | +## License |
| 113 | + |
| 114 | +MIT |
0 commit comments