@earth-app/collegedb
    Preparing search index...

    Interface CollegeDBConfig

    Configuration for the collegedb sharded database

    interface CollegeDBConfig {
        coordinator?: DurableObjectNamespace<undefined>;
        debug?: boolean;
        disableAutoMigration?: boolean;
        hashShardMappings?: boolean;
        kv: KVNamespace;
        maxDatabaseSize?: number;
        shardLocations?: Record<string, D1Region | ShardLocation>;
        shards: Record<string, D1Database>;
        strategy?: ShardingStrategy | MixedShardingStrategy;
        targetRegion?: D1Region;
    }
    Index

    Properties

    coordinator?: DurableObjectNamespace<undefined>

    Shard coordinator Durable Object

    debug?: boolean

    Enable debug logging for development and troubleshooting

    false
    

    1.0.6

    disableAutoMigration?: boolean

    Disable automatic migration detection and background migration (useful for testing)

    1.0.2

    hashShardMappings?: boolean

    Whether to hash shard mapping keys with SHA-256 for security and privacy. When enabled, primary keys are hashed before storing in KV, protecting sensitive data like emails from being visible in KV keys.

    true
    

    1.0.3

    kv: KVNamespace

    KV namespace for storing mappings

    maxDatabaseSize?: number

    Maximum database size in bytes. Shards that exceed this size will be excluded from new allocations (existing mappings remain intact).

    10683731148 // 9.95 GB, close to D1's 10 GB limit
    

    1.0.8

    shardLocations?: Record<string, D1Region | ShardLocation>

    Geographic locations of each shard (required for location strategy)

    shards: Record<string, D1Database>

    Available D1 database bindings

    Default shard allocation strategy (can be single strategy or mixed strategy object)

    targetRegion?: D1Region

    Target region for location-based sharding