import { Dialect } from 'kysely';

interface KyselyReplicationDialectConfig {
    primaryDialect: Dialect;
    replicaDialects: readonly [Dialect, ...Dialect[]];
    replicaStrategy: ReplicaStrategy;
}
interface ReplicaStrategy {
    next(replicaCount: number): Promise<number>;
    onTransaction?: 'error' | 'warn' | 'allow' | undefined;
}

export type { KyselyReplicationDialectConfig as K, ReplicaStrategy as R };
