steampipe-plugin-aws icon indicating copy to clipboard operation
steampipe-plugin-aws copied to clipboard

AWS S3 bucket size

Open moisei opened this issue 3 years ago • 7 comments

S3 storage is a common source of expenses, and in order to control the cost would be useful to query the size of the S3 bucket and the count of the objects. Also, as the price of S3 storage depends on objects' StorageClass, grouping by the StorageClass would provide even better observation.

moisei avatar Jun 16 '22 00:06 moisei

@moisei Appreciate using Steampipe!!

Just for reference, the discussion thread from the slack community channel

rajlearner17 avatar Jun 16 '22 08:06 rajlearner17

@moisei One potential way we could get this information is by creating tables to get the daily storage metrics for buckets, which includes the metrics BucketSizeBytes and NumberOfObjects. Would these metrics give you the type of data you're looking for?

We'd need to update how our CloudWatch metric tables can set dimensions (currently they can only pass in one dimension key/value pair, but all of the S3 bucket daily ones need to pass in 2, BucketName, and StorageType), and also need to determine how we can get each resource's identifier, e.g., bucket name, from the list of dimensions.

cbruno10 avatar Jun 16 '22 16:06 cbruno10

@cbruno10 up to me, it would be perfectly fine as I am not looking for real-time data.

moisei avatar Jun 17 '22 10:06 moisei

maybe it is also possible to add AWS Glacier data to this table, as it is another potential source of the expenses

moisei avatar Jun 17 '22 10:06 moisei

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days.

github-actions[bot] avatar Aug 16 '22 23:08 github-actions[bot]

'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 30 days.'

github-actions[bot] avatar Sep 16 '22 23:09 github-actions[bot]

'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 30 days.'

github-actions[bot] avatar Oct 19 '22 23:10 github-actions[bot]

'This issue was closed because it has been stalled for 90 days with no activity.'

github-actions[bot] avatar Nov 19 '22 23:11 github-actions[bot]