NLB

package
v1.10.10 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AwsxNLBActiveConnectionsCmd = &cobra.Command{
	Use:   "nlb_active_connections_panel",
	Short: "Get NLB active connections metrics data",
	Long:  `Command to get NLB active connections metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBActiveConnectionsPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB active connections: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBConnectionErrorsCmd = &cobra.Command{
	Use:   "connection_errors_panel",
	Short: "Get NLB connection errors metrics data",
	Long:  `Command to get NLB connection errors metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBConnectionErrorsData(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB connection errors: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {
				fmt.Println(jsonResp)
			}
		}
	},
}
View Source
var AwsxNLBErrorLogCmd = &cobra.Command{

	Use:   "error_log_panel",
	Short: "Get error log logs data",
	Long:  `Command to get error log logs data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running error log panel command")

		var authFlag bool
		var clientAuth *model.Auth
		var err error
		authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)

		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			panel, err := GetNLBErrorLogData(cmd, clientAuth, nil)
			if err != nil {
				return
			}
			fmt.Println(panel)
		}
	},
}
View Source
var AwsxNLBHealthyHostCountCmd = &cobra.Command{
	Use:   "nlb_healthy_host_count_panel",
	Short: "Get NLB healthy host count metrics data",
	Long:  `Command to get NLB healthy host count metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBHealthyHostCountPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB healthy host count: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBNewConnectionsCmd = &cobra.Command{
	Use:   "nlb_new_connections_panel",
	Short: "Get NLB new connections metrics data",
	Long:  `Command to get NLB new connections metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBNewConnectionsPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB new connections: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBNewFlowCountTLSCmd = &cobra.Command{
	Use:   "new_flow_count_tls_panel",
	Short: "Get NLB new flow count TLS metrics data",
	Long:  `Command to get NLB new flow count TLS metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBNewFlowCountTLSPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB new flow count TLS: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBProcessedBytesCmd = &cobra.Command{
	Use:   "nlb_processed_bytes_panel",
	Short: "Get NLB processed bytes metrics data",
	Long:  `Command to get NLB processed bytes metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBProcessedBytesPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB processed bytes: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBProcessedPacketsCmd = &cobra.Command{
	Use:   "processed_packets_panel",
	Short: "Get NLB processed packets metrics data",
	Long:  `Command to get NLB processed packets metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBProcessedPacketsPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB processed packets: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBSSLTLSNegotiationCmd = &cobra.Command{
	Use:   "nlb_ssl_tls_negotiation_panel",
	Short: "Get NLB SSL/TLS negotiation time metrics data",
	Long:  `Command to get NLB SSL/TLS negotiation time metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			rawData, calculatedData, err := GetSSLTLSNegotiationDataData(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB SSL/TLS negotiation time metrics: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(calculatedData)
			} else {
				fmt.Println(rawData)
			}
		}

	},
}
View Source
var AwsxNLBTCPResetCountCmd = &cobra.Command{
	Use:   "tcp_target_reset_count_panel",
	Short: "Get NLB TCP target reset count metrics data",
	Long:  `Command to get NLB TCP target reset count metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBTCPResetCountPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB TCP target reset count: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBTargetHealthCheckCmd = &cobra.Command{

	Use:   "target_health_check_configuration_panel",
	Short: "Get target health check configuration logs data",
	Long:  `Command to get target health check configuration logs data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running target health check configuration panel command")

		var authFlag bool
		var clientAuth *model.Auth
		var err error
		authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)

		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			panel, err := GetNLBTargetHealthCheckData(cmd, clientAuth, nil)
			if err != nil {
				return
			}
			fmt.Println(panel)
		}
	},
}
View Source
var AwsxNLBTargetHealthChecksCmd = &cobra.Command{
	Use:   "nlb_target_health_checks_panel",
	Short: "Get NLB target health checks metrics data",
	Long:  `Command to get NLB target health checks metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBTargetHealthCheckPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB target health check data: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNLBTargetStatussCmd = &cobra.Command{
	Use:   "new_target_status_panel",
	Short: "Retrieve target status metrics data",
	Long:  `Command to retrieve target status metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		authFlag, clientAuth, err := handleAuths(cmd)
		if err != nil {
			log.Println("Error during authentication:", err)
			return
		}

		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			targetStatuses, printresp, err := GetTargetStatussPanel(clientAuth)
			if err != nil {
				log.Println("Error getting target status:", err)
				return
			}

			if responseType == "frame" {
				fmt.Println(targetStatuses)
			} else {
				fmt.Println(printresp)
			}
		}
	},
}
View Source
var AwsxNLBUnhealthyHostCountCmd = &cobra.Command{
	Use:   "nlb_unhealthy_host_count_panel",
	Short: "Get NLB unhealthy host count metrics data",
	Long:  `Command to get NLB unhealthy host count metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running from child command..")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetNLBUnhealthyHostCountPanel(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting NLB unhealthy host count: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {

				fmt.Println(jsonResp)
			}
		}

	},
}
View Source
var AwsxNlbPortAllocationErrorCountCmd = &cobra.Command{
	Use:   "port_allocation_error_count_panel",
	Short: "get port allocation error count metrics data",
	Long:  `command to get target tls count metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("running from child command")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetPortAllocationErrorCountData(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting nlb target tls response data: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {
				fmt.Println(jsonResp)
			}
		}
	},
}
View Source
var AwsxNlbTargetErrorCountCmd = &cobra.Command{
	Use:   "target_error_count_panel",
	Short: "get target error count metrics data",
	Long:  `command to get target count metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("running from child command")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetTargetErrorCountData(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting nlb target response data: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {
				fmt.Println(jsonResp)
			}
		}
	},
}
View Source
var AwsxNlbTargetTlsErrorCountCmd = &cobra.Command{
	Use:   "target_tls_negotiation_error_count_panel",
	Short: "get target tls error count metrics data",
	Long:  `command to get target tls count metrics data`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("running from child command")
		var authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)
		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			jsonResp, cloudwatchMetricResp, err := GetTargetTlsErrorCountData(cmd, clientAuth, nil)
			if err != nil {
				log.Println("Error getting nlb target tls response data: ", err)
				return
			}
			if responseType == "frame" {
				fmt.Println(cloudwatchMetricResp)
			} else {
				fmt.Println(jsonResp)
			}
		}
	},
}
View Source
var AwsxSecurityGroupCmd = &cobra.Command{
	Use:   "security_group_panel",
	Short: "Retrieve security group configurations",
	Long:  `Command to retrieve security group configurations`,

	Run: func(cmd *cobra.Command, args []string) {
		authFlag, clientAuth, err := handleAuth(cmd)
		if err != nil {
			log.Println("Error during authentication:", err)
			return
		}

		if authFlag {
			responseType, _ := cmd.PersistentFlags().GetString("responseType")
			securityGroups, printresp, err := GetSecurityGroupConfigurations(clientAuth)
			if err != nil {
				log.Println("Error getting security group configurations:", err)
				return
			}

			if responseType == "frame" {
				fmt.Println(securityGroups)
			} else {
				fmt.Println(printresp)
			}
		}
	},
}
View Source
var AwsxTargetDeregistrationsCmd = &cobra.Command{
	Use:   "target_deregistration_panel",
	Short: "Get target deregistration panel",
	Long:  `Command to retrieve target deregistration panel`,

	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println("Running target deregistration command")

		var authFlag bool
		var clientAuth *model.Auth
		var err error
		authFlag, clientAuth, err = authenticate.AuthenticateCommand(cmd)

		if err != nil {
			log.Printf("Error during authentication: %v\n", err)
			err := cmd.Help()
			if err != nil {
				return
			}
			return
		}
		if authFlag {
			panel, err := GetTargetDeregistrationspanel(cmd, clientAuth, nil)
			if err != nil {
				return
			}
			fmt.Println(panel)

		}
	},
}

Functions

func FilterCloudWatchLogs

func FilterCloudWatchLogs(clientAuth *model.Auth, startTime, endTime *time.Time, logGroupName string, cloudWatchLogs *cloudwatchlogs.CloudWatchLogs) ([]*cloudwatchlogs.GetQueryResultsOutput, error)

func FilterCloudWatchLogss

func FilterCloudWatchLogss(clientAuth *model.Auth, startTime, endTime *time.Time, logGroupName string, cloudWatchLogs *cloudwatchlogs.CloudWatchLogs) ([]*cloudwatchlogs.GetQueryResultsOutput, error)

func FilterTargetDeregistration added in v1.10.5

func FilterTargetDeregistration(clientAuth *model.Auth, startTime, endTime *time.Time, logGroupName string, cloudWatchLogs *cloudwatchlogs.CloudWatchLogs) ([]*cloudwatchlogs.GetQueryResultsOutput, error)

func GetNLBActiveConnectionsMetricData

func GetNLBActiveConnectionsMetricData(clientAuth *model.Auth, instanceId, elementType string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBActiveConnectionsPanel

func GetNLBActiveConnectionsPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBConnectionErrorsData added in v1.10.5

func GetNLBConnectionErrorsData(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBConnectionErrorsMetricData added in v1.10.5

func GetNLBConnectionErrorsMetricData(clientAuth *model.Auth, instanceId string, startTime, endTime *time.Time, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBErrorLogData

func GetNLBErrorLogData(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchLogs *cloudwatchlogs.CloudWatchLogs) ([]*cloudwatchlogs.GetQueryResultsOutput, error)

func GetNLBHealthyHostCountMetricData added in v1.10.6

func GetNLBHealthyHostCountMetricData(clientAuth *model.Auth, instanceId string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBHealthyHostCountPanel added in v1.10.6

func GetNLBHealthyHostCountPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBNewConnectionsMetricData

func GetNLBNewConnectionsMetricData(clientAuth *model.Auth, instanceId string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBNewConnectionsPanel

func GetNLBNewConnectionsPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBNewFlowCountTLSMetricData added in v1.10.6

func GetNLBNewFlowCountTLSMetricData(clientAuth *model.Auth, instanceId, elementType string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBNewFlowCountTLSPanel added in v1.10.6

func GetNLBNewFlowCountTLSPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBProcessedBytesMetricData added in v1.10.6

func GetNLBProcessedBytesMetricData(clientAuth *model.Auth, instanceId string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBProcessedBytesPanel added in v1.10.6

func GetNLBProcessedBytesPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBProcessedPacketsMetricData added in v1.10.6

func GetNLBProcessedPacketsMetricData(clientAuth *model.Auth, instanceId, elementType string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBProcessedPacketsPanel added in v1.10.6

func GetNLBProcessedPacketsPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBTCPResetCountMetricData added in v1.10.6

func GetNLBTCPResetCountMetricData(clientAuth *model.Auth, instanceId, elementType string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBTCPResetCountPanel added in v1.10.6

func GetNLBTCPResetCountPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBTargetHealthCheckData

func GetNLBTargetHealthCheckData(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchLogs *cloudwatchlogs.CloudWatchLogs) ([]*cloudwatchlogs.GetQueryResultsOutput, error)

func GetNLBTargetHealthCheckMetricData added in v1.10.6

func GetNLBTargetHealthCheckMetricData(clientAuth *model.Auth, instanceId string, startTime, endTime *time.Time, metricName, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBTargetHealthCheckPanel added in v1.10.6

func GetNLBTargetHealthCheckPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNLBUnhealthyHostCountMetricData added in v1.10.6

func GetNLBUnhealthyHostCountMetricData(clientAuth *model.Auth, instanceId string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNLBUnhealthyHostCountPanel added in v1.10.6

func GetNLBUnhealthyHostCountPanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetNlbPortAllocationErrorCountMetricValue added in v1.10.9

func GetNlbPortAllocationErrorCountMetricValue(clientAuth *model.Auth, instanceId string, elementType string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNlbTargetErrorCountMetricValue added in v1.10.6

func GetNlbTargetErrorCountMetricValue(clientAuth *model.Auth, instanceId string, elementType string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetNlbTargetTlsErrorCountMetricValue added in v1.10.9

func GetNlbTargetTlsErrorCountMetricValue(clientAuth *model.Auth, instanceId string, elementType string, startTime, endTime *time.Time, statistic string, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetPortAllocationErrorCountData added in v1.10.9

func GetPortAllocationErrorCountData(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetSSLTLSNegotiationDataData added in v1.10.6

func GetSSLTLSNegotiationDataData(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetSSLTLSNegotiationDataMetricData added in v1.10.6

func GetSSLTLSNegotiationDataMetricData(clientAuth *model.Auth, instanceId string, elementType string, startTime, endTime *time.Time, cloudWatchClient *cloudwatch.CloudWatch) (*cloudwatch.GetMetricDataOutput, error)

func GetTargetDeregistrationspanel added in v1.10.5

func GetTargetDeregistrationspanel(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchLogs *cloudwatchlogs.CloudWatchLogs) ([]*cloudwatchlogs.GetQueryResultsOutput, error)

func GetTargetErrorCountData added in v1.10.6

func GetTargetErrorCountData(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

func GetTargetTlsErrorCountData added in v1.10.9

func GetTargetTlsErrorCountData(cmd *cobra.Command, clientAuth *model.Auth, cloudWatchClient *cloudwatch.CloudWatch) (string, map[string]*cloudwatch.GetMetricDataOutput, error)

Types

type ActiveConnectionsData

type ActiveConnectionsData struct {
	ActiveConnections []struct {
		Timestamp time.Time
		Value     float64
	} `json:"ActiveConnections"`
}

type ConnectionErrorsResult added in v1.10.5

type ConnectionErrorsResult struct {
	ConnectionErrors []TimeSeriesData `json:"ConnectionErrors"`
}

type HealthyHostCountData added in v1.10.6

type HealthyHostCountData struct {
	HealthyHostCount []struct {
		Timestamp time.Time
		Value     float64
	} `json:"HealthyHostCount"`
}

type NewConnectionsData

type NewConnectionsData struct {
	NewConnections []struct {
		Timestamp time.Time
		Value     float64
	} `json:"NewConnections"`
}

type NewFlowCountTLSData added in v1.10.6

type NewFlowCountTLSData struct {
	NewFlowCountTLS []struct {
		Timestamp time.Time
		Value     float64
	} `json:"NewFlowCountTLS"`
}

type NlbPortErrorCountTime added in v1.10.9

type NlbPortErrorCountTime struct {
	RawData []struct {
		Timestamp time.Time
		Value     float64
	} `json:"port_allocation_error_count_panel"`
}

func ProcessPortAllocationResponseRawData added in v1.10.9

func ProcessPortAllocationResponseRawData(result *cloudwatch.GetMetricDataOutput) NlbPortErrorCountTime

type NlbTargetErrorCountTime added in v1.10.6

type NlbTargetErrorCountTime struct {
	RawData []struct {
		Timestamp time.Time
		Value     float64
	} `json:"target_error_count_panel"`
}

func ProcessTargetResponseRawData added in v1.10.6

func ProcessTargetResponseRawData(result *cloudwatch.GetMetricDataOutput) NlbTargetErrorCountTime

type NlbTargetTlsErrorCountTime added in v1.10.9

type NlbTargetTlsErrorCountTime struct {
	RawData []struct {
		Timestamp time.Time
		Value     float64
	} `json:"target_tls_negotiation_error_count_panel"`
}

func ProcessTargetTlsResponseRawData added in v1.10.9

func ProcessTargetTlsResponseRawData(result *cloudwatch.GetMetricDataOutput) NlbTargetTlsErrorCountTime

type ProcessedBytesData added in v1.10.6

type ProcessedBytesData struct {
	ProcessedBytes []struct {
		Timestamp time.Time
		Value     float64
	} `json:"ProcessedBytes"`
}

type ProcessedPacketsData added in v1.10.6

type ProcessedPacketsData struct {
	ProcessedPackets []struct {
		Timestamp time.Time
		Value     float64
	} `json:"ProcessedPackets"`
}

type SSLTLSNegotiationData added in v1.10.6

type SSLTLSNegotiationData struct {
	Timestamp             time.Time
	SSLTLSNegotiationData float64
}

type SSLTLSNegotiationDataa added in v1.10.6

type SSLTLSNegotiationDataa struct {
	SSLTLSNegotiationData []SSLTLSNegotiationData `json:"SSLTLSNegotiationData"`
}

type SecurityGroupInfo added in v1.10.5

type SecurityGroupInfo struct {
	GroupID       string
	InboundRules  string
	OutboundRules string
}

func DescribeSecurityGroups added in v1.10.5

func DescribeSecurityGroups(clientAuth *model.Auth) ([]SecurityGroupInfo, error)

func GetSecurityGroupConfigurations added in v1.10.5

func GetSecurityGroupConfigurations(clientAuth *model.Auth) ([]SecurityGroupInfo, string, error)

type TCPResetCountData added in v1.10.6

type TCPResetCountData struct {
	TCPResetCount []struct {
		Timestamp time.Time
		Value     float64
	} `json:"TCPResetCount"`
}

type TargetHealthCheckData added in v1.10.6

type TargetHealthCheckData struct {
	HostCount map[string][]struct {
		Timestamp time.Time
		Value     float64
	} `json:"HostCount"`
}

type TargetStatuss

type TargetStatuss struct {
	TargetID     string
	TargetHealth string
	Reason       string // Reason field added
	Region       string // Region field added
}

func GetNLBTargetStatus

func GetNLBTargetStatus(clientAuth *model.Auth) ([]TargetStatuss, error)

func GetTargetStatussPanel

func GetTargetStatussPanel(clientAuth *model.Auth) ([]TargetStatuss, string, error)

type TimeSeriesData added in v1.10.5

type TimeSeriesData struct {
	Timestamp time.Time
	Count     float64
}

type UnhealthyHostCountData added in v1.10.6

type UnhealthyHostCountData struct {
	UnhealthyHostCount []struct {
		Timestamp time.Time
		Value     float64
	} `json:"UnhealthyHostCount"`
}

Jump to

Keyboard shortcuts

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