Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

TableChangeJustification
Preprocessors

New Table:

  • Id (PK, int)
  • Name (nvarchar(255) not null)
  • PreprocessorType (nvarchar(20), not null)
  • ScriptContent (nvarchar(max) null)
  • RequiresOdsApi (bit, not null)

Supports storage of PowerShell scripts.

EF Core note: Implement PreprocessorType as an enum.

DataMaps

New column:

  • FileProcessorId (FK, int, null)
Optionally associate a data map with a Custom File Processor.
Agents

Removed columns:

  • RowProcessor (nvarchar(max), null)
  • FileGenerator (nvarchar(max), null)

New columns:

  • RowProcessorId (FK, int, null)
  • FileGeneratorId (FK, int, null)

Replace Custom Row Processor and Custom File Generator filenames with database references.

This will require a specialized migration:

  • Create a preprocessor record with Name of the current value.
  • Reference it from the new column, and drop the old column.
  • On web application startup, for any Preprocessor records with a null ScriptContent value, get the file from the file system (by Name and known path per PreprocessorType) and populate contents into Script Content.

Questions:

NEED INPUT; Should we name the new table "Scripts" instead of "Preprocessors"? Role-specific foreign key column names could then more naturally be called "FileProcessorScriptId" versus "FileProcessorPreprocessorId" (notice that I opted to drop "Preprocessor" entirely in the changes described above).