profcomff / profcomff/dwh-pipelines

Собрать статистику по использованию EasyCode

Open
#90 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

good first issue :baby: new feature :new:
Dominant language
Python
Stars
16
Forks
0
PR merge metrics
No merged PRs in 30d

Description

Issue open by Roman Dyakov via telegram message.

  • Позволит понять, когда команда кодит, а когда можно проводить технические работы

  • Позволит выдавать ачивки за время, проведенное в изикод

  • Позволит автоматизированно отнимать доступы у неактивных аккаунтов во избежании проблем с безопасностью

  • Собрать информацию о пользователях и о запущенных окружениях из API

    • Забрать информацию о пользователях в таблицу STG_EASYCODE.users. Информацию о пользователях можно получить с https://easycode.profcomff.com/api/v2/users/ . Документация: https://coder.com/docs/api/users
      • Сделать таблицу dwh_definitions
      • Собрать пайплайн dwh_pipelines
      • Запускать пайплайн в проде раз в 10 минут
    • Забрать информацию об окружениях в таблицу STG_EASYCODE.workspaces. Информацию о пользователях можно получить с https://easycode.profcomff.com/api/v2/workspaces/ . Документация: https://coder.com/docs/api/workspaces
      • Сделать таблицу dwh_definitions
      • Собрать пайплайн dwh_pipelines
      • Запускать пайплайн в проде раз в 10 минут
  • Совместить информацию о пользователях Твой ФФ и их активности в EasyCode.

    • Построить таблицу ODS_ACTIVITY.easycode. В ключах должны быть user_id (из Auth API), имя пользователя easycode (есть в auth api и данных coder, ключ для джойна данных), время (округленное до ровной сетки в 10 минут, т.е. 2024-01-01T10:00, 2024-01-01T10:10 и тд), тип окружения (название воркспейса). Запись должна быть для каждого момента, когда пользователь был в активен и не должно быть, если пользователь активен не был
      • Сделать таблицу dwh_definitions
      • Собрать пайплайн dwh_pipelines
      • Запускать пайплайн в проде раз в час

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing dwh_definitions and dwh_pipelines conventions, then inspect the EasyCode users and workspaces API endpoints and their Coder documentation. The work is complete when STG_EASYCODE.users and STG_EASYCODE.workspaces are refreshed in production every 10 minutes, and ODS_ACTIVITY.easycode joins users to active 10-minute intervals and runs hourly.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data-engineering
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.