Giter Club home page Giter Club logo

looker_admin_scripts's Introduction

Useful Scripts for the Looker Admin

I've used poetry for package management, to create your .venv with the same dependencies, install poetry and type poetry install to install the dependencies.

Delinquent Content and Users

  • Finding users who haven't logged in via saml for x days and taking some action on them, delete_users_90_days.py
  • Finding content that hasn't been accessed for x days delinquent_content.py (this also backs up your content assuming gzr installation and deletes that content)

UAT Looker Parameter Finder

  • Finding content on your instance that has applications of a specific lookml parameter, e.g. all the content with an 'html' parameter applied on your instance. Output is a table that has the content, the id and the element id where the parameter is applied.
  • Built as a command line tool with the flags:
  1. ini identify your ini credentials for api access (see looker sdk for details, assumes a github api token
  2. repo iterate through a remote repo of lookml or a local folder of your lookml
  3. lookml_param the parameter you're trying to find

Validate Content

  • The idea here is to find all broken content with a content validator call and then send out an email using lookers send_schedule_once api endpoint.

  • Caveats with this one are to have your custom message show up create a dummy dimension called broken_content and give a sql value of 1, then create a look of that. It will always return true and allow you to put in any custom message you like into the message of the schedule.

Access System Activity

  • Assuming you want to etl data out of the new system__activity model, the one way is to use this sys_activity_table.py to generate the initial data, then do some kind of incremental load every x days to a stage table, then merge those data with the real table. n.b. it's recommended that you be very careful accessing your backend db as excessive use can cause looker system slowness.

looker_admin_scripts's People

Contributors

hugoselbie avatar hselbie avatar

Watchers

James Cloos 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.