How to init “ AWSPricing client ” by AWSPricingClientBuilder the latest version sdk?AWS SDK AmazonCloudFormationClient template version issueAWS Java SDK Build ErrorAre AWS Error Codes available from the Java SDK?AWS Java SDK Context class not foundAWS Java SDK: How to use AmazonDaxClientBuilder to replace regular DynamoDB client in 1.11.174 sdk versionwhere to find specific version of aws-java-sdk?Using spark with latest aws-java-sdk?AWS Java SDK Version For Creating a LambdaAWS S3 Java SDK - ListVersionsRequest Get Only Latest VersionsAWS Java SDK Call by Profile

What's a natural way to say that someone works somewhere (for a job)?

Everything Bob says is false. How does he get people to trust him?

Was Spock the First Vulcan in Starfleet?

Can somebody explain Brexit in a few child-proof sentences?

Finding all intervals that match predicate in vector

The baby cries all morning

Is there a problem with hiding "forgot password" until it's needed?

The plural of 'stomach"

Implement the Thanos sorting algorithm

apt-get update is failing in debian

How do I rename a LINUX host without needing to reboot for the rename to take effect?

How can I get through very long and very dry, but also very useful technical documents when learning a new tool?

Can I Retrieve Email Addresses from BCC?

Bash method for viewing beginning and end of file

Trouble understanding overseas colleagues

How can a jailer prevent the Forge Cleric's Artisan's Blessing from being used?

How will losing mobility of one hand affect my career as a programmer?

Time travel short story where a man arrives in the late 19th century in a time machine and then sends the machine back into the past

Curses work by shouting - How to avoid collateral damage?

voltage of sounds of mp3files

Modify casing of marked letters

If a character can use a +X magic weapon as a spellcasting focus, does it add the bonus to spell attacks or spell save DCs?

How can I replace every global instance of "x[2]" with "x_2"

The Riley Riddle Mine



How to init “ AWSPricing client ” by AWSPricingClientBuilder the latest version sdk?


AWS SDK AmazonCloudFormationClient template version issueAWS Java SDK Build ErrorAre AWS Error Codes available from the Java SDK?AWS Java SDK Context class not foundAWS Java SDK: How to use AmazonDaxClientBuilder to replace regular DynamoDB client in 1.11.174 sdk versionwhere to find specific version of aws-java-sdk?Using spark with latest aws-java-sdk?AWS Java SDK Version For Creating a LambdaAWS S3 Java SDK - ListVersionsRequest Get Only Latest VersionsAWS Java SDK Call by Profile













0















My task is to get aws procuct pricing data, so I do the things as follows:



  1. set the Environment Variables(AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY)
    enter image description here


  2. fill the pom.xml(in Eclipse) with the code:


<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk-pricing</artifactId>
<version>1.11.513</version>
</dependency>


  1. then I code the test method like the code:

public static void testDescribeServices() 
System.out.println("nn begin ....");
AWSPricing client = AWSPricingClientBuilder.standard().withRegion("us-east-1").build();
System.out.println("step 0001");
DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
servicesRequest.setServiceCode("AmazonEC2");
DescribeServicesResult result = client.describeServices(servicesRequest);
List<Service> serviceList = result.getServices();



  1. run the method testDescribeServices(), the message on the console is like this: (I was disappointed)

begin ....
17:08:21.166 [main] DEBUG com.amazonaws.AmazonWebServiceClient - Internal logging successfully configured to commons logger: true
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.EnvironmentVariableCsmConfigurationProvider@130d63be: Unable to load Client Side Monitoring configurations from environment variables!
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.SystemPropertyCsmConfigurationProvider@42a48628: Unable to load Client Side Monitoring configurations from system properties variables!
17:08:21.831 [java-sdk-http-connection-reaper] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Closing connections idle longer than 60000 MILLISECONDS
17:08:21.839 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.ProfileCsmConfigurationProvider@689604d9: The 'default' profile does not define all the required properties!
Exception in thread "main" java.lang.NoSuchMethodError: com.amazonaws.client.AwsSyncClientParams.getAdvancedConfig()Lcom/amazonaws/client/builder/AdvancedConfig;
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:158)
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:142)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:61)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:27)
at com.amazonaws.client.builder.AwsSyncClientBuilder.build(AwsSyncClientBuilder.java:46)
at com.yunion.apps.metadata.TestAWSDemoAPI.testDescribeServices(TestAWSDemoAPI.java:31)
at com.yunion.apps.metadata.TestAWSDemoAPI.main(TestAWSDemoAPI.java:26)









share|improve this question
























  • Has anybody met with the same question?

    – 604320137
    Mar 8 at 9:18















0















My task is to get aws procuct pricing data, so I do the things as follows:



  1. set the Environment Variables(AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY)
    enter image description here


  2. fill the pom.xml(in Eclipse) with the code:


<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk-pricing</artifactId>
<version>1.11.513</version>
</dependency>


  1. then I code the test method like the code:

public static void testDescribeServices() 
System.out.println("nn begin ....");
AWSPricing client = AWSPricingClientBuilder.standard().withRegion("us-east-1").build();
System.out.println("step 0001");
DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
servicesRequest.setServiceCode("AmazonEC2");
DescribeServicesResult result = client.describeServices(servicesRequest);
List<Service> serviceList = result.getServices();



  1. run the method testDescribeServices(), the message on the console is like this: (I was disappointed)

begin ....
17:08:21.166 [main] DEBUG com.amazonaws.AmazonWebServiceClient - Internal logging successfully configured to commons logger: true
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.EnvironmentVariableCsmConfigurationProvider@130d63be: Unable to load Client Side Monitoring configurations from environment variables!
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.SystemPropertyCsmConfigurationProvider@42a48628: Unable to load Client Side Monitoring configurations from system properties variables!
17:08:21.831 [java-sdk-http-connection-reaper] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Closing connections idle longer than 60000 MILLISECONDS
17:08:21.839 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.ProfileCsmConfigurationProvider@689604d9: The 'default' profile does not define all the required properties!
Exception in thread "main" java.lang.NoSuchMethodError: com.amazonaws.client.AwsSyncClientParams.getAdvancedConfig()Lcom/amazonaws/client/builder/AdvancedConfig;
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:158)
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:142)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:61)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:27)
at com.amazonaws.client.builder.AwsSyncClientBuilder.build(AwsSyncClientBuilder.java:46)
at com.yunion.apps.metadata.TestAWSDemoAPI.testDescribeServices(TestAWSDemoAPI.java:31)
at com.yunion.apps.metadata.TestAWSDemoAPI.main(TestAWSDemoAPI.java:26)









share|improve this question
























  • Has anybody met with the same question?

    – 604320137
    Mar 8 at 9:18













0












0








0








My task is to get aws procuct pricing data, so I do the things as follows:



  1. set the Environment Variables(AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY)
    enter image description here


  2. fill the pom.xml(in Eclipse) with the code:


<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk-pricing</artifactId>
<version>1.11.513</version>
</dependency>


  1. then I code the test method like the code:

public static void testDescribeServices() 
System.out.println("nn begin ....");
AWSPricing client = AWSPricingClientBuilder.standard().withRegion("us-east-1").build();
System.out.println("step 0001");
DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
servicesRequest.setServiceCode("AmazonEC2");
DescribeServicesResult result = client.describeServices(servicesRequest);
List<Service> serviceList = result.getServices();



  1. run the method testDescribeServices(), the message on the console is like this: (I was disappointed)

begin ....
17:08:21.166 [main] DEBUG com.amazonaws.AmazonWebServiceClient - Internal logging successfully configured to commons logger: true
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.EnvironmentVariableCsmConfigurationProvider@130d63be: Unable to load Client Side Monitoring configurations from environment variables!
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.SystemPropertyCsmConfigurationProvider@42a48628: Unable to load Client Side Monitoring configurations from system properties variables!
17:08:21.831 [java-sdk-http-connection-reaper] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Closing connections idle longer than 60000 MILLISECONDS
17:08:21.839 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.ProfileCsmConfigurationProvider@689604d9: The 'default' profile does not define all the required properties!
Exception in thread "main" java.lang.NoSuchMethodError: com.amazonaws.client.AwsSyncClientParams.getAdvancedConfig()Lcom/amazonaws/client/builder/AdvancedConfig;
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:158)
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:142)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:61)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:27)
at com.amazonaws.client.builder.AwsSyncClientBuilder.build(AwsSyncClientBuilder.java:46)
at com.yunion.apps.metadata.TestAWSDemoAPI.testDescribeServices(TestAWSDemoAPI.java:31)
at com.yunion.apps.metadata.TestAWSDemoAPI.main(TestAWSDemoAPI.java:26)









share|improve this question
















My task is to get aws procuct pricing data, so I do the things as follows:



  1. set the Environment Variables(AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY)
    enter image description here


  2. fill the pom.xml(in Eclipse) with the code:


<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk-pricing</artifactId>
<version>1.11.513</version>
</dependency>


  1. then I code the test method like the code:

public static void testDescribeServices() 
System.out.println("nn begin ....");
AWSPricing client = AWSPricingClientBuilder.standard().withRegion("us-east-1").build();
System.out.println("step 0001");
DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
servicesRequest.setServiceCode("AmazonEC2");
DescribeServicesResult result = client.describeServices(servicesRequest);
List<Service> serviceList = result.getServices();



  1. run the method testDescribeServices(), the message on the console is like this: (I was disappointed)

begin ....
17:08:21.166 [main] DEBUG com.amazonaws.AmazonWebServiceClient - Internal logging successfully configured to commons logger: true
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.EnvironmentVariableCsmConfigurationProvider@130d63be: Unable to load Client Side Monitoring configurations from environment variables!
17:08:21.831 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.SystemPropertyCsmConfigurationProvider@42a48628: Unable to load Client Side Monitoring configurations from system properties variables!
17:08:21.831 [java-sdk-http-connection-reaper] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Closing connections idle longer than 60000 MILLISECONDS
17:08:21.839 [main] DEBUG com.amazonaws.monitoring.CsmConfigurationProviderChain - Unable to load configuration from com.amazonaws.monitoring.ProfileCsmConfigurationProvider@689604d9: The 'default' profile does not define all the required properties!
Exception in thread "main" java.lang.NoSuchMethodError: com.amazonaws.client.AwsSyncClientParams.getAdvancedConfig()Lcom/amazonaws/client/builder/AdvancedConfig;
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:158)
at com.amazonaws.services.pricing.AWSPricingClient.<init>(AWSPricingClient.java:142)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:61)
at com.amazonaws.services.pricing.AWSPricingClientBuilder.build(AWSPricingClientBuilder.java:27)
at com.amazonaws.client.builder.AwsSyncClientBuilder.build(AwsSyncClientBuilder.java:46)
at com.yunion.apps.metadata.TestAWSDemoAPI.testDescribeServices(TestAWSDemoAPI.java:31)
at com.yunion.apps.metadata.TestAWSDemoAPI.main(TestAWSDemoAPI.java:26)






aws-java-sdk restclientbuilder






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 8 at 10:04







604320137

















asked Mar 8 at 9:16









604320137604320137

11




11












  • Has anybody met with the same question?

    – 604320137
    Mar 8 at 9:18

















  • Has anybody met with the same question?

    – 604320137
    Mar 8 at 9:18
















Has anybody met with the same question?

– 604320137
Mar 8 at 9:18





Has anybody met with the same question?

– 604320137
Mar 8 at 9:18












1 Answer
1






active

oldest

votes


















0














after trying some setting , I make some progress, and the new method is :



public static void testDescribeServices(String accessKey, String secretKey) 
BasicAWSCredentials basicAWSCredentials = new BasicAWSCredentials(accessKey, secretKey);
AWSCredentialsProvider credentialsProvider = new AWSStaticCredentialsProvider(basicAWSCredentials);
AWSPricingClientBuilder builder = AWSPricingClientBuilder.standard();
builder.setCredentials(credentialsProvider);
builder.withRegion("us-east-1");
CsmConfigurationProvider csmConfigurationProvider = new EnvironmentVariableCsmConfigurationProvider();
builder.setClientSideMonitoringConfigurationProvider(csmConfigurationProvider);
System.out.println("step 0001");
AWSPricing awsPricing = builder.build();
System.out.println("step 0002");
DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
servicesRequest.setServiceCode("AmazonEC2");
System.out.println("step 0003");
DescribeServicesResult result = awsPricing.describeServices(servicesRequest);
System.out.println("nn step 0004");
List<Service> serviceList = result.getServices();
System.out.println("nn step 0005");



However, the result is



Exception in thread "main" com.amazonaws.services.pricing.model.AWSPricingException: User: arn:aws:iam::285906155448:user/dev1 is not authorized to perform: pricing:DescribeServices **(Service: AWSPricing; Status Code: 400; Error Code: AccessDeniedException; Request ID: 13155463-4198-11e9-8f92-f1f731c320f2)**





share|improve this answer






















    Your Answer






    StackExchange.ifUsing("editor", function ()
    StackExchange.using("externalEditor", function ()
    StackExchange.using("snippets", function ()
    StackExchange.snippets.init();
    );
    );
    , "code-snippets");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "1"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55060024%2fhow-to-init-awspricing-client-by-awspricingclientbuilder-the-latest-version%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    after trying some setting , I make some progress, and the new method is :



    public static void testDescribeServices(String accessKey, String secretKey) 
    BasicAWSCredentials basicAWSCredentials = new BasicAWSCredentials(accessKey, secretKey);
    AWSCredentialsProvider credentialsProvider = new AWSStaticCredentialsProvider(basicAWSCredentials);
    AWSPricingClientBuilder builder = AWSPricingClientBuilder.standard();
    builder.setCredentials(credentialsProvider);
    builder.withRegion("us-east-1");
    CsmConfigurationProvider csmConfigurationProvider = new EnvironmentVariableCsmConfigurationProvider();
    builder.setClientSideMonitoringConfigurationProvider(csmConfigurationProvider);
    System.out.println("step 0001");
    AWSPricing awsPricing = builder.build();
    System.out.println("step 0002");
    DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
    servicesRequest.setServiceCode("AmazonEC2");
    System.out.println("step 0003");
    DescribeServicesResult result = awsPricing.describeServices(servicesRequest);
    System.out.println("nn step 0004");
    List<Service> serviceList = result.getServices();
    System.out.println("nn step 0005");



    However, the result is



    Exception in thread "main" com.amazonaws.services.pricing.model.AWSPricingException: User: arn:aws:iam::285906155448:user/dev1 is not authorized to perform: pricing:DescribeServices **(Service: AWSPricing; Status Code: 400; Error Code: AccessDeniedException; Request ID: 13155463-4198-11e9-8f92-f1f731c320f2)**





    share|improve this answer



























      0














      after trying some setting , I make some progress, and the new method is :



      public static void testDescribeServices(String accessKey, String secretKey) 
      BasicAWSCredentials basicAWSCredentials = new BasicAWSCredentials(accessKey, secretKey);
      AWSCredentialsProvider credentialsProvider = new AWSStaticCredentialsProvider(basicAWSCredentials);
      AWSPricingClientBuilder builder = AWSPricingClientBuilder.standard();
      builder.setCredentials(credentialsProvider);
      builder.withRegion("us-east-1");
      CsmConfigurationProvider csmConfigurationProvider = new EnvironmentVariableCsmConfigurationProvider();
      builder.setClientSideMonitoringConfigurationProvider(csmConfigurationProvider);
      System.out.println("step 0001");
      AWSPricing awsPricing = builder.build();
      System.out.println("step 0002");
      DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
      servicesRequest.setServiceCode("AmazonEC2");
      System.out.println("step 0003");
      DescribeServicesResult result = awsPricing.describeServices(servicesRequest);
      System.out.println("nn step 0004");
      List<Service> serviceList = result.getServices();
      System.out.println("nn step 0005");



      However, the result is



      Exception in thread "main" com.amazonaws.services.pricing.model.AWSPricingException: User: arn:aws:iam::285906155448:user/dev1 is not authorized to perform: pricing:DescribeServices **(Service: AWSPricing; Status Code: 400; Error Code: AccessDeniedException; Request ID: 13155463-4198-11e9-8f92-f1f731c320f2)**





      share|improve this answer

























        0












        0








        0







        after trying some setting , I make some progress, and the new method is :



        public static void testDescribeServices(String accessKey, String secretKey) 
        BasicAWSCredentials basicAWSCredentials = new BasicAWSCredentials(accessKey, secretKey);
        AWSCredentialsProvider credentialsProvider = new AWSStaticCredentialsProvider(basicAWSCredentials);
        AWSPricingClientBuilder builder = AWSPricingClientBuilder.standard();
        builder.setCredentials(credentialsProvider);
        builder.withRegion("us-east-1");
        CsmConfigurationProvider csmConfigurationProvider = new EnvironmentVariableCsmConfigurationProvider();
        builder.setClientSideMonitoringConfigurationProvider(csmConfigurationProvider);
        System.out.println("step 0001");
        AWSPricing awsPricing = builder.build();
        System.out.println("step 0002");
        DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
        servicesRequest.setServiceCode("AmazonEC2");
        System.out.println("step 0003");
        DescribeServicesResult result = awsPricing.describeServices(servicesRequest);
        System.out.println("nn step 0004");
        List<Service> serviceList = result.getServices();
        System.out.println("nn step 0005");



        However, the result is



        Exception in thread "main" com.amazonaws.services.pricing.model.AWSPricingException: User: arn:aws:iam::285906155448:user/dev1 is not authorized to perform: pricing:DescribeServices **(Service: AWSPricing; Status Code: 400; Error Code: AccessDeniedException; Request ID: 13155463-4198-11e9-8f92-f1f731c320f2)**





        share|improve this answer













        after trying some setting , I make some progress, and the new method is :



        public static void testDescribeServices(String accessKey, String secretKey) 
        BasicAWSCredentials basicAWSCredentials = new BasicAWSCredentials(accessKey, secretKey);
        AWSCredentialsProvider credentialsProvider = new AWSStaticCredentialsProvider(basicAWSCredentials);
        AWSPricingClientBuilder builder = AWSPricingClientBuilder.standard();
        builder.setCredentials(credentialsProvider);
        builder.withRegion("us-east-1");
        CsmConfigurationProvider csmConfigurationProvider = new EnvironmentVariableCsmConfigurationProvider();
        builder.setClientSideMonitoringConfigurationProvider(csmConfigurationProvider);
        System.out.println("step 0001");
        AWSPricing awsPricing = builder.build();
        System.out.println("step 0002");
        DescribeServicesRequest servicesRequest = new DescribeServicesRequest();
        servicesRequest.setServiceCode("AmazonEC2");
        System.out.println("step 0003");
        DescribeServicesResult result = awsPricing.describeServices(servicesRequest);
        System.out.println("nn step 0004");
        List<Service> serviceList = result.getServices();
        System.out.println("nn step 0005");



        However, the result is



        Exception in thread "main" com.amazonaws.services.pricing.model.AWSPricingException: User: arn:aws:iam::285906155448:user/dev1 is not authorized to perform: pricing:DescribeServices **(Service: AWSPricing; Status Code: 400; Error Code: AccessDeniedException; Request ID: 13155463-4198-11e9-8f92-f1f731c320f2)**






        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Mar 8 at 11:55









        604320137604320137

        11




        11





























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55060024%2fhow-to-init-awspricing-client-by-awspricingclientbuilder-the-latest-version%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Identity Server 4 is not redirecting to Angular app after login2019 Community Moderator ElectionIdentity Server 4 and dockerIdentityserver implicit flow unauthorized_clientIdentityServer Hybrid Flow - Access Token is null after user successful loginIdentity Server to MVC client : Page Redirect After loginLogin with Steam OpenId(oidc-client-js)Identity Server 4+.NET Core 2.0 + IdentityIdentityServer4 post-login redirect not working in Edge browserCall to IdentityServer4 generates System.NullReferenceException: Object reference not set to an instance of an objectIdentityServer4 without HTTPS not workingHow to get Authorization code from identity server without login form

            How to get text form Clipboard with JavaScript in Firefox 56?How to validate an email address in JavaScript?How do JavaScript closures work?How do I remove a property from a JavaScript object?How do you get a timestamp in JavaScript?How do I copy to the clipboard in JavaScript?How do I include a JavaScript file in another JavaScript file?Get the current URL with JavaScript?How to replace all occurrences of a string in JavaScriptHow to check whether a string contains a substring in JavaScript?How do I remove a particular element from an array in JavaScript?

            Can't initialize raids on a new ASUS Prime B360M-A motherboard2019 Community Moderator ElectionSimilar to RAID config yet more like mirroring solution?Can't get motherboard serial numberWhy does the BIOS entry point start with a WBINVD instruction?UEFI performance Asus Maximus V Extreme