Skip to content

Instantly share code, notes, and snippets.

View davidlu1001's full-sized avatar

David Lu davidlu1001

View GitHub Profile
# Enterprise Immuta Column Tag Removal Tool
## 📋 Overview
The **Enterprise Immuta Column Tag Removal Tool** (`column_tag_del.py`) is a high-performance, production-ready Python script designed to remove tags from Immuta columns based on CSV input. This tool is the reverse operation of `column_tag_add.py` and features enterprise-grade reliability, comprehensive error handling, and advanced monitoring capabilities.
### 🎯 Key Features
- **🏢 Enterprise-Grade**: Circuit breaker, retry logic, adaptive rate limiting
- **📊 Progress Tracking**: SQLite-based persistence with resume functionality
@davidlu1001
davidlu1001 / column-tag-add.py
Last active May 26, 2025 11:33
column-tag-add.py
#!/usr/bin/env python3
import csv
import json
import logging
import sys
import os
from pathlib import Path
import requests
import argparse
@davidlu1001
davidlu1001 / Combined_Files_Archive.txt
Last active May 25, 2025 10:40
Combined Files Archive for repo file-combiner
# Enhanced Combined Files Archive
# Generated by file-combiner v2.0.1
# Date: 2025-05-25 10:39:59 UTC
# Source: /tmp/file_combiner_github_83t4ttow
# Total files: 15
# Total size: 128.0KB
#
# Format:
# === FILE_SEPARATOR ===
# FILE_METADATA: <json_metadata>
@davidlu1001
davidlu1001 / SOP_Immuta_Operations.md
Created May 21, 2025 04:49
SOP - Immuta Operations

Immuta Operations SOP - BAU / Change Management / Incident Learnings (with Snowflake Integration)


Quick Reference Table

Task API Endpoint Script Example Section
User Staging /api/v2/user/status stage_users.py 3.1
Tag Migration /api/v2/tag migrate_tags.py 2.4
@davidlu1001
davidlu1001 / immuta-create-groups.js
Last active May 14, 2025 22:56
immuta-create-groups.js
// This script automates the creation of Immuta Groups from CSV or Excel files
// To use:
// 1. Navigate to the Immuta Groups page (People > Groups)
// 2. Open browser's developer console (F12 or right-click > Inspect > Console)
// 3. Paste this entire script and press Enter
// 4. Follow the on-screen prompts to select your CSV or Excel file
// Global variables
let isOfflineMode = false;
@davidlu1001
davidlu1001 / convert_immuta_tags.py
Last active May 14, 2025 07:32
convert_immuta_tags.py
#!/usr/bin/env python3
"""
Immuta Tag Converter - Converts Immuta Tag API GET response to POST /tag API format.
This script processes tag data from Immuta's GET /tag API response and converts it into
the format required for POST /tag API requests, handling tag hierarchies and structure
according to Immuta API requirements.
Features:
- Support for tag hierarchies with custom separators
@davidlu1001
davidlu1001 / compare_tags.sh
Created May 13, 2025 10:38
compare_tags.sh
#!/bin/bash
# compare_tags.sh - Compare leaf node tags between two Immuta CSV files
# Usage: ./compare_tags.sh file1.csv file2.csv
if [ $# -ne 2 ]; then
echo "Usage: $0 <file1.csv> <file2.csv>"
exit 1
fi
@davidlu1001
davidlu1001 / Immuta_Tag_Hierarchy_Extractor.md
Created May 13, 2025 10:04
HowTo - Immuta Tag Hierarchy Extractor

Immuta Tag Hierarchy Extractor

This tool helps you extract all tag hierarchies from an Immuta Governance interface. It identifies and organizes tags into their hierarchical structure and exports them to a CSV file for easy analysis.

Scripts

This toolkit contains two main JavaScript files:

  1. expand-all-sections.js: Expands all collapsible sections in the Immuta interface
  2. immuta-tag-hierarchy-extractor.js: Extracts all tags with their complete hierarchies
@davidlu1001
davidlu1001 / expand-all-sections.js
Last active May 13, 2025 09:41
expand-all-sections.js
// Function to expand all collapsed sections
function expandAllSections() {
// Find all chevron-down icons
const chevronDownIcons = document.querySelectorAll('i.pxl-icon-chevron-down');
console.log(`Found ${chevronDownIcons.length} collapsed sections to expand`);
// Track how many were successfully expanded
let expandedCount = 0;
// Click each icon to expand its section
@davidlu1001
davidlu1001 / immuta-tag-hierarchy-extractor.js
Last active May 14, 2025 02:05
immuta-tag-hierarchy-extractor.js
// immuta-tag-hierarchy-extractor.js
// Version 8.0 - Multi-format tag hierarchy extractor with CSV and JSON outputs
// For use with Immuta Governance interface
(function extractImmutaTagHierarchy() {
console.log("Starting Immuta Tag Hierarchy extraction...");
// Find the governance section
const governanceSection = document.querySelector('[class*="governance"], .governance, div.governance');
if (!governanceSection) {