Skip to content

Instantly share code, notes, and snippets.

@tanmaiaccion
tanmaiaccion / create_glue_partition.py
Created July 7, 2021 12:32 — forked from bvsubhash/create_glue_partition.py
Code Snippet of Lambda Function to add partitions into Glue Metadata Catalog using Boto3
import boto3
import urllib.parse
import os
import copy
def create_glue_partition_handler(event, context):
for record in event['Records']:
try:
source_bucket = record['s3']['bucket']['name']