Skip to end of metadata
Go to start of metadata

You are viewing an old version of this content. View the current version.

Compare with Current View Version History

« Previous Version 2 Next »

This page describes "alpha" quality code and processes. It is intended to provide an early look into the Project Roadrunner: PostgreSQL Support for the Ed-Fi ODS / API development process and elicit feedback. As such, full release functionality could end up differing substantially from the code described herein.

What's New

EdFi.Db.Deploy

Summary of key enhancements with this release:

  1. Install as a dotnet tool
  2. Changed the execution syntax to use verbs (examples below)
  3. Now contains full Admin and Security databases
  4. Support for deploying Change Queries as a feature
  5. Support for deploying extensions
  6. Support for testing if any migration scripts need to be run, using whatif  verb.

Installing Alpha 2

See readme for more details.

Install the pre-compiled version from binaries on MyGet using dotnet tool  global installation with --version 1.0.0-*  for getting the latest pre-release version:

dotnet tool install -g EdFi.Db.Deploy --add-source https://www.myget.org/F/ed-fi/api/v3/index.json --version 1.0.0-*

Alternately, you can get the source code from https://github.com/Ed-Fi-Alliance/Ed-Fi-Databases and checkout tag 1.0.0-alpha-2 .

New Deploy Verb

For detailed examples, run the tool with no arguments provided and view the output, or see the readme.

The command syntax has shifted to use a verb format to indicate what action to take. This paves the way for some future verbs. The key verb for deployment is deploy , which will run the DbUp-based migrations. There is also a new argument flag ( -d  or --databaseType) to indicate which database you wish to install (Admin, ODS, or Security). For example, assuming dotnet tool install  was run as shown above, the following command will install the Admin database on Postgres:

EdFi.Db.Deploy deploy -d Admin -c "server=localhost;database=EdFi_Admin;username=…;password=…" -p PostgreSQL

Installing Change Queries

Change queries support is only for SQL Server at this time. Use argument -f Changes  to install.

EdFi.Db.Deploy deploy -d ODS -c "server=localhost;database=EdFi_ODS;integrated security=sspi" -p SqlServer -f Changes

Installing Extensions

While RoadRunner will not officially support extensions, this tool will be incorporated into initdev in the near future and must be able to install extensions for SQL Server-based ODS implementations. Use argument -x  to deploy extensions, providing a list of "supporting artifacts" directories.

$supportingArtifacts = @(
  "C:\Source\3.x\Ed-Fi-Ods-Implementation\Application\EdFi.Ods.Extensions.GrandBend\SupportingArtifacts\Database",
  "C:\Source\3.x\Ed-Fi-Ods-Implementation\Application\EdFi.Ods.Extensions.Sample\SupportingArtifacts\Database"
)

EdFi.Db.Deploy deploy -d ODS -c "server=localhost;database=EdFi_ODS;integrated security=sspi" -p SqlServer -x $supportingArtifacts

WhatIf Verb

The whatif  verb checks to see if any scripts need to be installed without performing the installation. This functionality was added to support scenarios where you want to run a task before deploying new migration scripts to the database (e.g. run a backup). Exits with status code 1 if there are migration scripts to execute and 0 otherwise.

EdFi.Db.Deploy whatif -d ODS -c "server=localhost;database=EdFi_ODS;integrated security=sspi" -p SqlServer

# Check $LASTEXITCODE for 1 or 0

Coming Soon

ODS/API changes to support authentication and authorization will be available in the next preview release, along with instructions on manually creating a Vendor key and secret in PostgreSQL.

Providing Feedback

Have feedback on this pre-release code? Three available channels:

  • Slack #roadrunner is a good place for general Q&A and discussion.
  • Drop a comment at the bottom of this page to share additional documentation notes.
  • Found a bug? Please create a Bug Report in the ODS project.
  • No labels