A very simple data checker that will have a set of files defining SQL statements to do level 2 validations on the ODS database
http://datacheck.toolwise.net/
There are 2 ways of running the Data Checker. In development or production mode. The main difference is that Development will run from your Visual Studio in IIS Express. While Production we will deploy to a local IIS.
For both environments you will need to complete the following common prerequisites:
- Basic knowledge of compiling .net Core applications.
- Basic to mid skills on hosting application on Windows IIS Server
- Visual Studio 2019 Community edition. (https://visualstudio.microsoft.com/downloads/)
- .Net Core 3.1
- .Net core 3.1 hosting bundle ( https://dotnet.microsoft.com/download/dotnet-core/3.1 , https://dotnet.microsoft.com/download/dotnet-core/thank-you/runtime-aspnetcore-3.1.3-windows-hosting-bundle-installer )
- NodeJs LTS (https://nodejs.org/en/)
- Angular CLI (https://cli.angular.io/) npm install -g @angular/cli
- Acquiring the codebase: https://github.com/Ed-Fi-Alliance/Ed-Fi-X-DataChecker/
NOTE VERY IMPORTANT: The user that you will use to configure the execution environment should be read only.
Clone or download the code located in the github repository: https://github.com/Ed-Fi-Alliance/Ed-Fi-X-DataChecker/
We recommend that you download the code in the following path: c:\Projects\edfi\DataChecker
To download click on this link and save to the folder where you wish to download. https://github.com/Ed-Fi-Alliance/Ed-Fi-X-DataChecker/archive/master.zip
To clone open your favorite shell, navigate to the path above or folder where you wish to download and then type in the following command:
c:\projects\edfi> git clone https://github.com/Ed-Fi-Alliance/Ed-Fi-X-DataChecker.git
- Open the solution file: Once you have the code on your local machine, open Visual Studio and the open the solution file located at c:\projects\edfi\DataChecker\MSDF.DataChecker.sln
- Ensure the solution builds: Right click the “MSDF.DataChecker.WebApp” project and click rebuild. If you get any errors it's probably because you are missing one of the dependencies or prerequisites listed above.
In a .net Core application there are 2 files called “appsettings.json” and "appsettings.Production.json". This is where you need to ensure to configure the application’s settings. In this case we only need to update your database connection string. Data Checker supports both MsSQL security and Windows Integrated security. Update the connection string to suit your use case. In the example below we are using a local SQL server instance with SQL credentials.
- Make sure you have create schema or admin access to a MsSQL server instance so that we can create the database that supports the solution.
- Ensure you update the connection string in the “appsettings.json”.
- In Visual Studio open the “Package Manager Console”. Usually located in the menu: Tools->Nuget Package Manager->Package Manager Console.
- Ensure you have set the MSDF.DataChecker.WebApp project as the startup project by right clicking the project and selecting “Set as Startup Project”.
- In the Package Manager Console ensure you have selected the WebApp project in the dropdown for “Default project:” and then run the command “Update-Database”. This will execute the Entity Framework Code First migrations and create the database for you.
- Once you have created the database then you can click on IIS Express to run the application.
For beta users we are not providing a quick install but they are coming soon.
We recommend you review the following article by microsoft for hosting .Net Core Applications: https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/?view=aspnetcore-3.1
- Publish to your IIS: Right click on the web project and select Publish option
Select folder type and the path to were the files will be published and click Create Profile
Select the configuration Publish and the option "Delete all existing files prior to publish" and click Save
After the Publish you will see this at the bottom of your output window
You will be able to see the application running on the url https://localhost/DataCheck/
If you want to change the name of the application "DataCheck" you need to update the following files with the name you want:
environment.prodlocal.ts
package.json
We provide a Console application that you can schedule with "Windows Task Scheduler".
- Build the project MSDF.DataChecker.cmd with the Release configuration, change the connection string of the file "appsettings.json" if need it.
- After the build, you will have in the folder Release all the necessary files to execute the program that you can use in the "Windows Task Scheduler".
- The required parameters are: "--environmentid" and "--environmentname". If you want to run an entire container you need to add the parameter "--containerid" or if you only want to run a rule then you need to add the parameter "--ruleid".
Example of Use: MSDF.DataChecker.cmd.exe --environmentid "1451E793-F100-4A91-845E-4E45130DCF31" --environmentname "V25 Douglas" --ruleid "8D7363E5-A98B-BB74-5179-1207FFC18A1F"
Licensed under the Ed-Fi License.