A newer version of the Ed-Fi ODS / API is now available. See the Ed-Fi Technology Version Index for a link to the latest version.

District-Specific ODS Configuration

Some implementations find it useful to partition data based on school districts (i.e., to segment data associated with one district from data associated with another district). In the Ed-Fi ODS / API, this partitioning is configurable, and is off by default.

The ODS / API can be configured for district-specific configuration through the following steps:

  • Update apiStartup:type key in the Web.config of the EdFi.Ods.WebApi project to: <add key="apiStartup:type" value="DistrictSpecific" />
  • Initialize the development environment for district-specific configuration using the initdev command as outlined in the Getting Started Guide. 

  • As an example: from a PowerShell prompt, navigate to the Ed-Fi-ODS-Implementation folder and run the Initialize-PowershellForDevelopment.ps script, followed by the initdev command passing InstallType and OdsTokens parameters. OdsTokens is a list of semicolon-separated district IDs.

    initdev -InstallType DistrictSpecific -OdsTokens '255901;255902'
  • The same parameters noted above can be used with the deployment script packaged with EdFi.RestApi.Databases NuGet for non-development environments. 
  • Configure API Clients to be associated with one district. If you are using the ODS / API Admin App administrative application for setting up client keys and secrets, you can configure the client to be associated with a particular district in the "Add Application Vendor" screen. This will ensure that all transactions from the client will land in the ODS partition specific to the district associated with the API Client. 

See the Extensibility & Customization section for information on using district-specific configuration as a facet of a partitioning strategy.