export type ExternalServiceType = 'message-queue' | 'cache' | 'object-storage' | 'auth' | 'observability' | 'third-party-api';
export type ServiceRisk = 'stateless' | 'stateful-replayable' | 'stateful-critical';
export interface ExternalService {
    id: string;
    name: string;
    type: ExternalServiceType;
    provider: string;
    critical: boolean;
    stateless: boolean;
    riskLevel: ServiceRisk;
    detectedIn: string[];
}
export interface ServiceAnalysisResult {
    services: ExternalService[];
    totalDetected: number;
    criticalCount: number;
    analyzedAt: string;
}
export interface ServiceBehaviorDifference {
    aspect: string;
    sourceDescription: string;
    targetDescription: string;
    migrationImpact: 'breaking' | 'notable' | 'minor';
}
export interface ServiceAdapterSpec {
    interfaceName: string;
    methods: string[];
    sourceImplementation: string;
    targetImplementation: string;
    portPattern: 'ports-and-adapters';
}
export interface ServiceEquivalence {
    sourceService: string;
    targetService: string;
    serviceType: ExternalServiceType;
    behaviorDifferences: ServiceBehaviorDifference[];
    adapterSpec: ServiceAdapterSpec;
    migrationComplexity: 'low' | 'medium' | 'high';
}
export interface ServiceEquivalenceMap {
    sourceStack: string;
    targetStack: string;
    equivalences: ServiceEquivalence[];
    unmappedServices: string[];
    generatedAt: string;
}
export interface ServiceMigrationOrder {
    serviceId: string;
    serviceName: string;
    serviceType: ExternalServiceType;
    migrationOrder: number;
    rationale: string;
}
export interface ServiceMigrationPlan {
    orderedServices: ServiceMigrationOrder[];
    phases: {
        phase: number;
        services: string[];
        description: string;
    }[];
    totalServices: number;
    estimatedWeeks: number;
    generatedAt: string;
}
export interface ServiceBehaviorCheck {
    aspect: string;
    expectedValue: string;
    unit: string;
    checkType: 'throughput' | 'latency' | 'durability' | 'delivery-guarantee' | 'failure-mode';
}
export interface ServiceValidationChecklist {
    serviceId: string;
    serviceName: string;
    checks: ServiceBehaviorCheck[];
    generatedAt: string;
}
export interface ProviderEntry {
    provider: string;
    type: ExternalServiceType;
    keywords: string[];
    stateless: boolean;
    riskLevel: ServiceRisk;
}
export interface ServiceEquivalenceEntry {
    source: string;
    target: string;
    type: ExternalServiceType;
    differences: ServiceBehaviorDifference[];
    adapterInterfaceName: string;
    methods: string[];
    sourceImpl: string;
    targetImpl: string;
    complexity: 'low' | 'medium' | 'high';
}
export interface ValidationCheckTemplate {
    serviceType: ExternalServiceType;
    checks: Omit<ServiceBehaviorCheck, 'expectedValue'>[];
}
export type RollbackReversibility = 'reversible' | 'partially-reversible' | 'irreversible';
export interface RollbackStep {
    stepId: string;
    description: string;
    reversibility: RollbackReversibility;
    irreversibilityReason?: string;
    rollbackAction: string;
    estimatedMinutes: number;
    requiresConfirmation: boolean;
}
export interface RollbackCheckpoint {
    checkpointId: string;
    phase: string;
    description: string;
    automatedBefore: boolean;
    conditions: string[];
}
export interface InverseDbMigration {
    originalMigration: string;
    inverseScript: string;
    dataRestoreStrategy: string;
    practicalityNote?: string;
}
export interface ComponentRollback {
    component: string;
    dependents: string[];
    rollbackOrder: number;
    rollbackSteps: string[];
}
export interface RollbackPlan {
    components: ComponentRollback[];
    checkpoints: RollbackCheckpoint[];
    steps: RollbackStep[];
    inverseDbMigrations: InverseDbMigration[];
    pointOfNoReturn: string;
    totalEstimatedMinutes: number;
    generatedAt: string;
}
export interface MigrationCheckpoint {
    checkpointId: string;
    label: string;
    completedComponents: string[];
    dbSchemaSnapshot: string;
    serviceConfiguration: Record<string, string>;
    createdAt: string;
    projectId: string;
}
export interface RollbackExecutionPlan {
    targetCheckpointId: string;
    orderedActions: RollbackAction[];
    totalSteps: number;
    requiresManualConfirmation: boolean;
    generatedAt: string;
}
export interface RollbackAction {
    order: number;
    description: string;
    type: 'automatic' | 'manual-confirmation-required';
    reversibility: RollbackReversibility;
    command?: string;
}
export type FeatureFlagProvider = 'launchdarkly' | 'unleash' | 'flagsmith' | 'custom-json';
export interface TrafficShiftingStage {
    percentage: number;
    observationPeriodMinutes: number;
    advanceCondition: string;
}
export interface AutoRollbackCriteria {
    errorRateMultiplier: number;
    windowMinutes: number;
    description: string;
}
export interface FeatureFlagAdapter {
    provider: FeatureFlagProvider;
    implementation: string;
    configExample: string;
}
export interface FeatureFlagRouter {
    description: string;
    pseudocode: string;
    modules: string[];
}
export interface FlagExpirationPolicy {
    suggestedDaysAfterMigration: number;
    techDebtWarningDays: number;
    rationale: string;
}
export interface FeatureFlagTest {
    scenario: string;
    flagState: 'on' | 'off' | 'partial';
    expectedBehavior: string;
}
export interface FeatureFlagSpec {
    flagName: string;
    description: string;
    trafficStages: TrafficShiftingStage[];
    autoRollback: AutoRollbackCriteria;
    adapters: FeatureFlagAdapter[];
    router?: FeatureFlagRouter;
    expirationPolicy: FlagExpirationPolicy;
    tests: FeatureFlagTest[];
    generatedAt: string;
}
export type MigrationComponentStatus = 'pending' | 'in-progress' | 'completed' | 'blocked';
export interface TrackedMigrationComponent {
    id: string;
    name: string;
    status: MigrationComponentStatus;
    specId?: string;
    completedAt?: string;
}
export interface ActiveRisk {
    id: string;
    description: string;
    severity: 'low' | 'medium' | 'high' | 'critical';
    mitigationStatus: 'open' | 'mitigated';
}
export interface ActiveFeatureFlag {
    flagName: string;
    currentPercentage: number;
    activeSinceDays: number;
    isTechDebt: boolean;
}
export interface MigrationStatusReport {
    projectId: string;
    percentComplete: number;
    totalComponents: number;
    completedComponents: number;
    inProgressComponents: number;
    pendingComponents: number;
    components: TrackedMigrationComponent[];
    activeRisks: ActiveRisk[];
    activeFlags: ActiveFeatureFlag[];
    estimatedCompletionDate: string;
    generatedAt: string;
}
//# sourceMappingURL=migration-advanced.d.ts.map