service

package
v0.0.0-...-e1d419d Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindParameter

FindParameter retrieves an AWS Systems Manager string parameter Inputs:

c is the context of the method call, which includes the AWS Region
api is the interface that defines the method call
input defines the input arguments to the service call.

Output:

If success, a GetParameterOutput object containing the result of the service call and nil
Otherwise, nil and an error from the call to GetParameter

func GetAppClientVars

func GetAppClientVars(ctx context.Context) (*models.HandlerVars, error)

GetAppClientVars returns a SSMVars struct with values from AWS SSM or ENV

Types

type DatasetsService

type DatasetsService interface {
	GetDataset(ctx context.Context, datasetNodeId string) (*pgdb.Dataset, error)
	GetTrashcanPage(ctx context.Context, datasetNodeId string, rootNodeId string, limit int, offset int) (*models.TrashcanPage, error)
	GetManifest(ctx context.Context, datasetNodeId string) (*models.ManifestResult, error)
}

func NewDatasetsService

func NewDatasetsService(db *sql.DB, s3Client *s3.Client, snsClient models.SnsAPI, options *models.HandlerVars, orgId int) DatasetsService

func NewDatasetsServiceWithFactory

func NewDatasetsServiceWithFactory(factory store.DatasetsStoreFactory, s3factory store.S3StoreFactory, snsFactory store.SnsStoreFactory, options *models.HandlerVars, orgId int) DatasetsService

type SSMGetParameterAPI

type SSMGetParameterAPI interface {
	GetParameter(ctx context.Context,
		params *ssm.GetParameterInput,
		optFns ...func(*ssm.Options)) (*ssm.GetParameterOutput, error)
}

SSMGetParameterAPI defines the interface for the GetParameter function. We use this interface to test the function using a mocked service.

Jump to

Keyboard shortcuts

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