Giter Club home page Giter Club logo

bestpracticeanalyzerautomation's Introduction

Best Practice Analyzer Automation (BPAA)

Just a fancy automation/script to run the Best Practice Analyzer of Tabular Editor over all datasets in the Power BI Service. Read below for instructions on how to use it, or check out this blog post on it:
https://www.moderndata.ai/2020/09/check-the-quality-of-all-power-bi-data-models-at-once-with-best-practice-analyzer-automation-bpaa/

The power of this script is of course in the Best Practice Analyzer that is part of Tabular Editor! Please visit https://tabulareditor.com/ and reach out Daniel Otykier and thank him!

If you want to modify the best-practices rules, or add your own, contribute to the rules on GitHub: https://github.com/TabularEditor/BestPracticeRules#contributing.

how it works

  • The script loopts the workspaces that the given service principal has the member or admin role membership in (the script installs the PowerShell Power BI management module MicrosoftPowerBIMgmt)
  • The script then runs the Best Practice Analyzer on each data model in the workspace (the script downloads the portable version of Tabular Editor to do this).
  • The script will output the results of each analysis in the given directory as .trx files, a standard VSTEST result (JSON).
  • The script will download and open the Power BI template report of the solution, that will load the .trx files and provides a start to analyze the results.

prerequisites

  1. You need a Service Principal (e.g. App Registration) in Azure Active Directory. Nothing special, just add a secret to it and write down the ClientId, Secret, TenantId.
  2. Download the latest version of the BPAA solution from the repo in GitHub. Unzip the BPAA solution to a directory of choice. (or only the BPAA.ps1 file).
  3. Add the Service Principal of step 1 to all Power BI workspaces, and make sure it has the ‘member’ or ‘admin’ role. If you have more than a dozen workspaces you would want to script this! No worries, I’ve added a script for that in the BPAA repo. You can find it in the directory of step 2. Note: you need the correct ObjectId of the Service Principal! You can find it in the “Enterprise applications” screen in Azure Active Directory (not the App Registrations screen!).
  4. The solution only works on v2 workspaces. So, this might be an appropriate time to upgrade those workspaces?
  5. The solution only works on workspaces in Premium capacity (it needs the XMLA endpoint). You could spin up an Azure Power BI Embedded (A sku) for the duration of this exercise, and connect the workspaces to that capacity. When you’re done you connect them back to shared capacity and suspend the premium capacity.

credits

The power of this script is of course in the Best Practice Analyzer that is part of Tabular Editor! Please visit https://tabulareditor.com/ and reach out Daniel Otykier and thank him!
Also credits and thanks to https://mnaoumov.wordpress.com/ for the functions to help call the .exe.

bestpracticeanalyzerautomation's People

Contributors

daveruijter avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.