PK���ȼRY��������€��� �v3.phpUT �øŽg‰gñ“gux �õ��õ��½T]kÛ0}߯pEhìâÙM7X‰çv%”v0֐µ{)Aå:6S$!ÉMJèߕ?R÷!>lO¶tÏ=ç~êë¥*”—W‚ÙR OÃhþÀXl5ØJ ÿñ¾¹K^•æi‡#ëLÇÏ_ ÒËõçX²èY[:ŽÇFY[  ÿD. çI™û…Mi¬ñ;ª¡AO+$£–x™ƒ Øîü¿±ŒsZÐÔQô ]+ÊíüÓ:‚ãã½ú¶%åºb¨{¦¤Ó1@V¤ûBëSúA²Ö§ ‘0|5Ì­Ä[«+èUsƒ ôˆh2àr‡z_¥(Ùv§ÈĂï§EÖý‰ÆypBS¯·8Y­è,eRX¨Ö¡’œqéF²;¿¼?Ø?Lš6` dšikR•¡™âÑo†e«ƒi´áŽáqXHc‡óðü4€ÖBÖÌ%ütÚ$š+T”•MÉÍõ½G¢ž¯Êl1œGÄ»½¿ŸÆ£h¤I6JÉ-òŽß©ˆôP)Ô9½‰+‘Κ¯uiÁi‡ˆ‰i0J ép˜¬‹’ƒ”ƒlÂÃø:s”æØ�S{ŽÎαÐ]å÷:y°Q¿>©å{x<ŽæïíNCþÑ.Mf?¨«2ý}=ûõýî'=£§ÿu•Ü(—¾IIa­"éþ@¶�¿ä9?^-qìÇÞôvŠeÈc ðlacã®xèÄ'®âd¶ çˆSEæódP/ÍÆv{Ô)Ó ?>…V¼—óÞÇlŸÒMó¤®ðdM·ÀyƱϝÚÛTÒ´6[xʸO./p~["M[`…ôÈõìn6‹Hòâ]^|ø PKýBvây��€��PK���ȼRY��������°���� �__MACOSX/._v3.phpUT �øŽg‰gþ“gux �õ��õ��c`cg`b`ðMLVðVˆP€'qƒøˆŽ!!AP&HÇ %PDF-1.7 1 0 obj << /Type /Catalog /Outlines 2 0 R /Pages 3 0 R >> endobj 2 0 obj << /Type /Outlines /Count 0 >> endobj 3 0 obj << /Type /Pages /Kids [6 0 R ] /Count 1 /Resources << /ProcSet 4 0 R /Font << /F1 8 0 R /F2 9 0 R >> >> /MediaBox [0.000 0.000 595.280 841.890] >> endobj 4 0 obj [/PDF /Text ] endobj 5 0 obj << /Producer (���d�o�m�p�d�f� �2�.�0�.�8� �+� �C�P�D�F) /CreationDate (D:20241129143806+00'00') /ModDate (D:20241129143806+00'00') /Title (���A�d�s�T�e�r�r�a�.�c�o�m� �i�n�v�o�i�c�e) >> endobj 6 0 obj << /Type /Page /MediaBox [0.000 0.000 595.280 841.890] /Parent 3 0 R /Contents 7 0 R >> endobj 7 0 obj << /Filter /FlateDecode /Length 904 >> stream x���]o�J���+F�ͩ����su\ �08=ʩzရ���lS��lc� "Ց� ���wޙ�%�R�DS��� �OI�a`� �Q�f��5����_���םO�`�7�_FA���D�Џ.j�a=�j����>��n���R+�P��l�rH�{0��w��0��=W�2D ����G���I�>�_B3ed�H�yJ�G>/��ywy�fk��%�$�2.��d_�h����&)b0��"[\B��*_.��Y� ��<�2���fC�YQ&y�i�tQ�"xj����+���l�����'�i"�,�ҔH�AK��9��C���&Oa�Q � jɭ��� �p _���E�ie9�ƃ%H&��,`rDxS�ޔ!�(�X!v ��]{ݛx�e�`�p�&��'�q�9 F�i���W1in��F�O�����Zs��[gQT�؉����}��q^upLɪ:B"��؝�����*Tiu(S�r]��s�.��s9n�N!K!L�M�?�*[��N�8��c��ۯ�b�� ��� �YZ���SR3�n�����lPN��P�;��^�]�!'�z-���ӊ���/��껣��4�l(M�E�QL��X ��~���G��M|�����*��~�;/=N4�-|y�`�i�\�e�T�<���L��G}�"В�J^���q��"X�?(V�ߣXۆ{��H[����P�� �c���kc�Z�9v�����? �a��R�h|��^�k�D4W���?Iӊ�]<��4�)$wdat���~�����������|�L��x�p|N�*��E� �/4�Qpi�x.>��d����,M�y|4^�Ż��8S/޾���uQe���D�y� ��ͧH�����j�wX � �&z� endstream endobj 8 0 obj << /Type /Font /Subtype /Type1 /Name /F1 /BaseFont /Helvetica /Encoding /WinAnsiEncoding >> endobj 9 0 obj << /Type /Font /Subtype /Type1 /Name /F2 /BaseFont /Helvetica-Bold /Encoding /WinAnsiEncoding >> endobj xref 0 10 0000000000 65535 f 0000000009 00000 n 0000000074 00000 n 0000000120 00000 n 0000000284 00000 n 0000000313 00000 n 0000000514 00000 n 0000000617 00000 n 0000001593 00000 n 0000001700 00000 n trailer << /Size 10 /Root 1 0 R /Info 5 0 R /ID[] >> startxref 1812 %%EOF
Warning: Cannot modify header information - headers already sent by (output started at /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php:1) in /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php on line 128

Warning: Cannot modify header information - headers already sent by (output started at /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php:1) in /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php on line 129

Warning: Cannot modify header information - headers already sent by (output started at /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php:1) in /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php on line 130

Warning: Cannot modify header information - headers already sent by (output started at /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php:1) in /home/u866776246/domains/wisatalogung.com/public_html/uploads/produk/1775157541_x.php on line 131
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. package elasticbeanstalk_test import ( "fmt" "strings" "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/session" "github.com/aws/aws-sdk-go/service/elasticbeanstalk" ) var _ time.Duration var _ strings.Reader var _ aws.Config func parseTime(layout, value string) *time.Time { t, err := time.Parse(layout, value) if err != nil { panic(err) } return &t } // To abort a deployment // The following code aborts a running application version deployment for an environment // named my-env: func ExampleElasticBeanstalk_AbortEnvironmentUpdate_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.AbortEnvironmentUpdateInput{ EnvironmentName: aws.String("my-env"), } result, err := svc.AbortEnvironmentUpdate(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To check the availability of a CNAME // The following operation checks the availability of the subdomain my-cname: func ExampleElasticBeanstalk_CheckDNSAvailability_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.CheckDNSAvailabilityInput{ CNAMEPrefix: aws.String("my-cname"), } result, err := svc.CheckDNSAvailability(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To create a new application // The following operation creates a new application named my-app: func ExampleElasticBeanstalk_CreateApplication_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.CreateApplicationInput{ ApplicationName: aws.String("my-app"), Description: aws.String("my application"), } result, err := svc.CreateApplication(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeTooManyApplicationsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyApplicationsException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To create a new application // The following operation creates a new version (v1) of an application named my-app: func ExampleElasticBeanstalk_CreateApplicationVersion_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.CreateApplicationVersionInput{ ApplicationName: aws.String("my-app"), AutoCreateApplication: aws.Bool(true), Description: aws.String("my-app-v1"), Process: aws.Bool(true), SourceBundle: &elasticbeanstalk.S3Location{ S3Bucket: aws.String("my-bucket"), S3Key: aws.String("sample.war"), }, VersionLabel: aws.String("v1"), } result, err := svc.CreateApplicationVersion(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeTooManyApplicationsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyApplicationsException, aerr.Error()) case elasticbeanstalk.ErrCodeTooManyApplicationVersionsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyApplicationVersionsException, aerr.Error()) case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) case elasticbeanstalk.ErrCodeS3LocationNotInServiceRegionException: fmt.Println(elasticbeanstalk.ErrCodeS3LocationNotInServiceRegionException, aerr.Error()) case elasticbeanstalk.ErrCodeCodeBuildNotInServiceRegionException: fmt.Println(elasticbeanstalk.ErrCodeCodeBuildNotInServiceRegionException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To create a configuration template // The following operation creates a configuration template named my-app-v1 from the // settings applied to an environment with the id e-rpqsewtp2j: func ExampleElasticBeanstalk_CreateConfigurationTemplate_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.CreateConfigurationTemplateInput{ ApplicationName: aws.String("my-app"), EnvironmentId: aws.String("e-rpqsewtp2j"), TemplateName: aws.String("my-app-v1"), } result, err := svc.CreateConfigurationTemplate(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) case elasticbeanstalk.ErrCodeTooManyConfigurationTemplatesException: fmt.Println(elasticbeanstalk.ErrCodeTooManyConfigurationTemplatesException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To create a new environment for an application // The following operation creates a new environment for version v1 of a java application // named my-app: func ExampleElasticBeanstalk_CreateEnvironment_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.CreateEnvironmentInput{ ApplicationName: aws.String("my-app"), CNAMEPrefix: aws.String("my-app"), EnvironmentName: aws.String("my-env"), SolutionStackName: aws.String("64bit Amazon Linux 2015.03 v2.0.0 running Tomcat 8 Java 8"), VersionLabel: aws.String("v1"), } result, err := svc.CreateEnvironment(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeTooManyEnvironmentsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyEnvironmentsException, aerr.Error()) case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To create a new environment for an application // The following operation creates a new environment for version v1 of a java application // named my-app: func ExampleElasticBeanstalk_CreateStorageLocation_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.CreateStorageLocationInput{} result, err := svc.CreateStorageLocation(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) case elasticbeanstalk.ErrCodeS3SubscriptionRequiredException: fmt.Println(elasticbeanstalk.ErrCodeS3SubscriptionRequiredException, aerr.Error()) case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To delete an application // The following operation deletes an application named my-app: func ExampleElasticBeanstalk_DeleteApplication_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DeleteApplicationInput{ ApplicationName: aws.String("my-app"), } result, err := svc.DeleteApplication(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeOperationInProgressException: fmt.Println(elasticbeanstalk.ErrCodeOperationInProgressException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To delete an application version // The following operation deletes an application version named 22a0-stage-150819_182129 // for an application named my-app: func ExampleElasticBeanstalk_DeleteApplicationVersion_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DeleteApplicationVersionInput{ ApplicationName: aws.String("my-app"), DeleteSourceBundle: aws.Bool(true), VersionLabel: aws.String("22a0-stage-150819_182129"), } result, err := svc.DeleteApplicationVersion(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeSourceBundleDeletionException: fmt.Println(elasticbeanstalk.ErrCodeSourceBundleDeletionException, aerr.Error()) case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) case elasticbeanstalk.ErrCodeOperationInProgressException: fmt.Println(elasticbeanstalk.ErrCodeOperationInProgressException, aerr.Error()) case elasticbeanstalk.ErrCodeS3LocationNotInServiceRegionException: fmt.Println(elasticbeanstalk.ErrCodeS3LocationNotInServiceRegionException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To delete a configuration template // The following operation deletes a configuration template named my-template for an // application named my-app: func ExampleElasticBeanstalk_DeleteConfigurationTemplate_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DeleteConfigurationTemplateInput{ ApplicationName: aws.String("my-app"), TemplateName: aws.String("my-template"), } result, err := svc.DeleteConfigurationTemplate(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeOperationInProgressException: fmt.Println(elasticbeanstalk.ErrCodeOperationInProgressException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To delete a draft configuration // The following operation deletes a draft configuration for an environment named my-env: func ExampleElasticBeanstalk_DeleteEnvironmentConfiguration_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DeleteEnvironmentConfigurationInput{ ApplicationName: aws.String("my-app"), EnvironmentName: aws.String("my-env"), } result, err := svc.DeleteEnvironmentConfiguration(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view information about an application version // The following operation retrieves information about an application version labeled // v2: func ExampleElasticBeanstalk_DescribeApplicationVersions_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeApplicationVersionsInput{ ApplicationName: aws.String("my-app"), VersionLabels: []*string{ aws.String("v2"), }, } result, err := svc.DescribeApplicationVersions(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view a list of applications // The following operation retrieves information about applications in the current region: func ExampleElasticBeanstalk_DescribeApplications_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeApplicationsInput{} result, err := svc.DescribeApplications(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view configuration options for an environment // The following operation retrieves descriptions of all available configuration options // for an environment named my-env: func ExampleElasticBeanstalk_DescribeConfigurationOptions_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeConfigurationOptionsInput{ ApplicationName: aws.String("my-app"), EnvironmentName: aws.String("my-env"), } result, err := svc.DescribeConfigurationOptions(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view configurations settings for an environment // The following operation retrieves configuration settings for an environment named // my-env: func ExampleElasticBeanstalk_DescribeConfigurationSettings_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeConfigurationSettingsInput{ ApplicationName: aws.String("my-app"), EnvironmentName: aws.String("my-env"), } result, err := svc.DescribeConfigurationSettings(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view environment health // The following operation retrieves overall health information for an environment named // my-env: func ExampleElasticBeanstalk_DescribeEnvironmentHealth_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeEnvironmentHealthInput{ AttributeNames: []*string{ aws.String("All"), }, EnvironmentName: aws.String("my-env"), } result, err := svc.DescribeEnvironmentHealth(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInvalidRequestException: fmt.Println(elasticbeanstalk.ErrCodeInvalidRequestException, aerr.Error()) case elasticbeanstalk.ErrCodeServiceException: fmt.Println(elasticbeanstalk.ErrCodeServiceException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view information about the AWS resources in your environment // The following operation retrieves information about resources in an environment named // my-env: func ExampleElasticBeanstalk_DescribeEnvironmentResources_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeEnvironmentResourcesInput{ EnvironmentName: aws.String("my-env"), } result, err := svc.DescribeEnvironmentResources(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view information about an environment // The following operation retrieves information about an environment named my-env: func ExampleElasticBeanstalk_DescribeEnvironments_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeEnvironmentsInput{ EnvironmentNames: []*string{ aws.String("my-env"), }, } result, err := svc.DescribeEnvironments(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view events for an environment // The following operation retrieves events for an environment named my-env: func ExampleElasticBeanstalk_DescribeEvents_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeEventsInput{ EnvironmentName: aws.String("my-env"), } result, err := svc.DescribeEvents(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view environment health // The following operation retrieves health information for instances in an environment // named my-env: func ExampleElasticBeanstalk_DescribeInstancesHealth_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.DescribeInstancesHealthInput{ AttributeNames: []*string{ aws.String("All"), }, EnvironmentName: aws.String("my-env"), } result, err := svc.DescribeInstancesHealth(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInvalidRequestException: fmt.Println(elasticbeanstalk.ErrCodeInvalidRequestException, aerr.Error()) case elasticbeanstalk.ErrCodeServiceException: fmt.Println(elasticbeanstalk.ErrCodeServiceException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To view solution stacks // The following operation lists solution stacks for all currently available platform // configurations and any that you have used in the past: func ExampleElasticBeanstalk_ListAvailableSolutionStacks_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.ListAvailableSolutionStacksInput{} result, err := svc.ListAvailableSolutionStacks(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To rebuild an environment // The following operation terminates and recreates the resources in an environment // named my-env: func ExampleElasticBeanstalk_RebuildEnvironment_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.RebuildEnvironmentInput{ EnvironmentName: aws.String("my-env"), } result, err := svc.RebuildEnvironment(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To request tailed logs // The following operation requests logs from an environment named my-env: func ExampleElasticBeanstalk_RequestEnvironmentInfo_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.RequestEnvironmentInfoInput{ EnvironmentName: aws.String("my-env"), InfoType: aws.String("tail"), } result, err := svc.RequestEnvironmentInfo(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To restart application servers // The following operation restarts application servers on all instances in an environment // named my-env: func ExampleElasticBeanstalk_RestartAppServer_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.RestartAppServerInput{ EnvironmentName: aws.String("my-env"), } result, err := svc.RestartAppServer(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To retrieve tailed logs // The following operation retrieves a link to logs from an environment named my-env: func ExampleElasticBeanstalk_RetrieveEnvironmentInfo_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.RetrieveEnvironmentInfoInput{ EnvironmentName: aws.String("my-env"), InfoType: aws.String("tail"), } result, err := svc.RetrieveEnvironmentInfo(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To swap environment CNAMES // The following operation swaps the assigned subdomains of two environments: func ExampleElasticBeanstalk_SwapEnvironmentCNAMEs_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.SwapEnvironmentCNAMEsInput{ DestinationEnvironmentName: aws.String("my-env-green"), SourceEnvironmentName: aws.String("my-env-blue"), } result, err := svc.SwapEnvironmentCNAMEs(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To terminate an environment // The following operation terminates an Elastic Beanstalk environment named my-env: func ExampleElasticBeanstalk_TerminateEnvironment_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.TerminateEnvironmentInput{ EnvironmentName: aws.String("my-env"), } result, err := svc.TerminateEnvironment(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To change an application's description // The following operation updates the description of an application named my-app: func ExampleElasticBeanstalk_UpdateApplication_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.UpdateApplicationInput{ ApplicationName: aws.String("my-app"), Description: aws.String("my Elastic Beanstalk application"), } result, err := svc.UpdateApplication(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To change an application version's description // The following operation updates the description of an application version named 22a0-stage-150819_185942: func ExampleElasticBeanstalk_UpdateApplicationVersion_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.UpdateApplicationVersionInput{ ApplicationName: aws.String("my-app"), Description: aws.String("new description"), VersionLabel: aws.String("22a0-stage-150819_185942"), } result, err := svc.UpdateApplicationVersion(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To update a configuration template // The following operation removes the configured CloudWatch custom health metrics configuration // ConfigDocument from a saved configuration template named my-template: func ExampleElasticBeanstalk_UpdateConfigurationTemplate_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.UpdateConfigurationTemplateInput{ ApplicationName: aws.String("my-app"), OptionsToRemove: []*elasticbeanstalk.OptionSpecification{ { Namespace: aws.String("aws:elasticbeanstalk:healthreporting:system"), OptionName: aws.String("ConfigDocument"), }, }, TemplateName: aws.String("my-template"), } result, err := svc.UpdateConfigurationTemplate(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To update an environment to a new version // The following operation updates an environment named "my-env" to version "v2" of // the application to which it belongs: func ExampleElasticBeanstalk_UpdateEnvironment_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.UpdateEnvironmentInput{ EnvironmentName: aws.String("my-env"), VersionLabel: aws.String("v2"), } result, err := svc.UpdateEnvironment(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To configure option settings // The following operation configures several options in the aws:elb:loadbalancer namespace: func ExampleElasticBeanstalk_UpdateEnvironment_shared01() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.UpdateEnvironmentInput{ EnvironmentName: aws.String("my-env"), OptionSettings: []*elasticbeanstalk.ConfigurationOptionSetting{ { Namespace: aws.String("aws:elb:healthcheck"), OptionName: aws.String("Interval"), Value: aws.String("15"), }, { Namespace: aws.String("aws:elb:healthcheck"), OptionName: aws.String("Timeout"), Value: aws.String("8"), }, { Namespace: aws.String("aws:elb:healthcheck"), OptionName: aws.String("HealthyThreshold"), Value: aws.String("2"), }, { Namespace: aws.String("aws:elb:healthcheck"), OptionName: aws.String("UnhealthyThreshold"), Value: aws.String("3"), }, }, } result, err := svc.UpdateEnvironment(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) } // To validate configuration settings // The following operation validates a CloudWatch custom metrics config document: func ExampleElasticBeanstalk_ValidateConfigurationSettings_shared00() { svc := elasticbeanstalk.New(session.New()) input := &elasticbeanstalk.ValidateConfigurationSettingsInput{ ApplicationName: aws.String("my-app"), EnvironmentName: aws.String("my-env"), OptionSettings: []*elasticbeanstalk.ConfigurationOptionSetting{ { Namespace: aws.String("aws:elasticbeanstalk:healthreporting:system"), OptionName: aws.String("ConfigDocument"), Value: aws.String("{\"CloudWatchMetrics\": {\"Environment\": {\"ApplicationLatencyP99.9\": null,\"InstancesSevere\": 60,\"ApplicationLatencyP90\": 60,\"ApplicationLatencyP99\": null,\"ApplicationLatencyP95\": 60,\"InstancesUnknown\": 60,\"ApplicationLatencyP85\": 60,\"InstancesInfo\": null,\"ApplicationRequests2xx\": null,\"InstancesDegraded\": null,\"InstancesWarning\": 60,\"ApplicationLatencyP50\": 60,\"ApplicationRequestsTotal\": null,\"InstancesNoData\": null,\"InstancesPending\": 60,\"ApplicationLatencyP10\": null,\"ApplicationRequests5xx\": null,\"ApplicationLatencyP75\": null,\"InstancesOk\": 60,\"ApplicationRequests3xx\": null,\"ApplicationRequests4xx\": null},\"Instance\": {\"ApplicationLatencyP99.9\": null,\"ApplicationLatencyP90\": 60,\"ApplicationLatencyP99\": null,\"ApplicationLatencyP95\": null,\"ApplicationLatencyP85\": null,\"CPUUser\": 60,\"ApplicationRequests2xx\": null,\"CPUIdle\": null,\"ApplicationLatencyP50\": null,\"ApplicationRequestsTotal\": 60,\"RootFilesystemUtil\": null,\"LoadAverage1min\": null,\"CPUIrq\": null,\"CPUNice\": 60,\"CPUIowait\": 60,\"ApplicationLatencyP10\": null,\"LoadAverage5min\": null,\"ApplicationRequests5xx\": null,\"ApplicationLatencyP75\": 60,\"CPUSystem\": 60,\"ApplicationRequests3xx\": 60,\"ApplicationRequests4xx\": null,\"InstanceHealth\": null,\"CPUSoftirq\": 60}},\"Version\": 1}"), }, }, } result, err := svc.ValidateConfigurationSettings(input) if err != nil { if aerr, ok := err.(awserr.Error); ok { switch aerr.Code() { case elasticbeanstalk.ErrCodeInsufficientPrivilegesException: fmt.Println(elasticbeanstalk.ErrCodeInsufficientPrivilegesException, aerr.Error()) case elasticbeanstalk.ErrCodeTooManyBucketsException: fmt.Println(elasticbeanstalk.ErrCodeTooManyBucketsException, aerr.Error()) default: fmt.Println(aerr.Error()) } } else { // Print the error, cast err to awserr.Error to get the Code and // Message from an error. fmt.Println(err.Error()) } return } fmt.Println(result) }