Created
June 3, 2019 06:29
-
-
Save erez-rabih/0d7e4f79e2f1fd677b0129dbdd665d22 to your computer and use it in GitHub Desktop.
s3 get file metadata
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns example | |
(:require [amazonica.aws.s3 :as s3])) | |
(defn get-file-metadata [bucket filename] | |
(try | |
(s3/get-object :bucket-name bucket :key filename) | |
(catch com.amazonaws.services.s3.model.AmazonS3Exception e nil))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment