lamdbameta

package module
v0.0.0-...-a41f701 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2022 License: MIT Imports: 3 Imported by: 0

README

LambdaMeta | Geoff Ford

Collates metadata associated with an AWS Lambda function Invoke, within a JSON encodeable struct Meta.

Create the Meta instance by calling GetMeta().

Installing and building the library

This project requires Go 1.17.2

To use this package in your own code, use go get:

go get github.com/gford1000-go/lambdameta

Then, you can include it in your project:

import "github.com/gford1000-go/lambdameta"

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LambdaFunction

type LambdaFunction struct {
	Name    string `json:"function_name"`
	Version string `json:"function_version"`
}

type LogInfo

type LogInfo struct {
	GroupName  string `json:"group_name"`
	StreamName string `json:"stream_name"`
}

type Meta

type Meta struct {
	Function  LambdaFunction `json:"lambda"`
	Logging   LogInfo        `json:"logging"`
	Runtime   Runtime        `json:"runtime"`
	RequestID string         `json:"aws_request_id"`
	Timeout   string         `json:"request_timeout"`
}

func GetMeta

func GetMeta(ctx context.Context) *Meta

GetMeta returns metadata information from the supplied context

type Runtime

type Runtime struct {
	MemoryLimit int `json:"memory_limit"`
}

Jump to

Keyboard shortcuts

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