Skip to main content

aws_ext is a set of high level useful functions

Project description

AWS EXT

The aws_ext python package contains some useful functions (built on top of boto3) for managing some aws services. At the moment only some utilities for the Aws Glue Data catalog

Installation

pip install aws_ext

Usage (command line)

export LOGLEVEL=INFO

AWS_PROFILE=prd aws_ext get_tables_with_many_versions [] 10

aws_ext get_tables_with_many_versions "[db1,db2]" 20

aws_ext delete_old_tables_versions [] 10 False

Usage (python library)

import boto3
import aws_ext

session = boto3.session.Session()

GLUE

from aws_ext import glue_databases
glue_client = session.client("glue")

Extracting tables with (too) many versions

glue_databases.get_tables_with_many_versions(glue_client, database_name="mydb", threshold=1)

Deleting old tables versions

glue_databases.delete_old_tables_versions(glue_client, database_name="mydb", keep=1, dryrun=True)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aws_ext-0.1.0.tar.gz (5.6 kB view hashes)

Uploaded source

Built Distributions

aws_ext-0.1.0-py3.9.egg (11.5 kB view hashes)

Uploaded 0 1 0

aws_ext-0.1.0-py3-none-any.whl (6.7 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page