awsarnutils

package module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2020 License: MIT Imports: 3 Imported by: 0

README

CI PkgGoDev

go-aws-arn-utils

Utilities to extract more detailed components from AWS ARNs.

Install

go get github.com/aereal/go-aws-arn-utils

Usage

Timestream
import (
  "github.com/aereal/go-aws-arn-utils"
)

dbName, tableName, err := awsarnutils.ParseTimestreamTableARN("arn:aws:timestream:us-east-1:1234567890:database/db1/table/table1")
// dbName = "db1", tableName = "table1"

License

See LICENSE file.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrInvalidService indicates the ARN is not of Timestream
	ErrInvalidService = errors.New("invalid ARN: service is not timestream")

	// ErrIllFormedResource indicates resource part of the ARN is not a table
	ErrIllFormedResource = errors.New("invalid ARN: resource part is ill-formed")
)

Functions

func ParseTimestreamTableARN

func ParseTimestreamTableARN(tableArn string) (databaseName string, tableName string, err error)

ParseTimestreamTableARN extracts Timestream database name and table name from tableArn

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL