Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread Ignasi Barrera
FTR, I'm not a user of the SimianArmy, but I've just opened a PR to add support for temporary credentials: https://github.com/Netflix/SimianArmy/pull/331 On 21 June 2018 at 10:14, archiep...@gmail.com wrote: > Hi Ignasi, > Thank you! I will try this out and let you know if it worked. > > Cheers

Re: error while running JCloudsNove.java

2018-06-21 Thread Ignasi Barrera
It would be easier if you posted your code in a gist or similar. BTW, don't you have a proper Java IDE that can help you automatically import all required packages? On 21 June 2018 at 10:31, jayshankar nair wrote: > Hi Ignasi, > > I have included the header file. I am getting the following

Re: error while running JCloudsNove.java

2018-06-21 Thread Ignasi Barrera
You need the properties, to configure V3. The code in the example is OK and works. You need to fix your package imports. Use a proper java IDE. On 21 June 2018 at 10:47, jayshankar nair wrote: > Hi Ignasi, > > I commented the overrides properties and ran JCloudNova.java. I get the > following

Re: error while running JCloudsNove.java

2018-06-21 Thread jayshankar nair
Hello Ignasi, It  a small piece of code. I got it from jclouds website. I am attaching the codeThanks,Jayshankar | | Virus-free. www.avast.com | JCloudsNova.java Description: Binary data

Re: error while running JCloudsNove.java

2018-06-21 Thread Ignasi Barrera
You declare the local variable "overrides" in a different method where you use it. No offense, but just use a proper IDE to write your code. We can help you understand how jclouds works, and use it with your OpenStack distribution. We'll be more than happy to help there, but we're not here to

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread archieprad
Hi Andrea, Thanks for the quick response. I am using an IAM role that has full admin access. Which is why this case is even more perplexing. Do you have any other suggestions to try out? Cheers Archana On 2018/06/21 07:40:46, Andrea Turli wrote: > Archana, > > interesting! > > To debug

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread Andrea Turli
Mmm very interesting! The only thing that comes to my mind is: - is your account allowed to talk to all the regions? From the stacktrace above looks like org.jclouds.rest.AuthorizationException: POST https://ec2.us-east-1.amazonaws.com/ HTTP/1.1 -> HTTP/1.1 401 Unauthorized so maybe your account

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread Ignasi Barrera
Hi Archana, I see the problem here. When using temporary credentials in AWS, the session token must be included in a request header [1], so you need to provide it when configuring the jclouds context with the credentials. By default, the "ContextBuilder.credentials" signature does only allow to

Re: What parameters does Jclouds need to use listNodes() ?

2018-06-21 Thread Ignasi Barrera
You just need to provide the access tokens, and when using temporary credentials you need to build the ContextBuilder providing the access tokens and the session token too. See this [1] for more details (and let's try to continue the discussion there to avoid having the info spread in two places).

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread archieprad
Hi Andrea, Yes i changed the code a little and added a .endpoint("https://ec2-ap-southeast-1.com;), to change the region. Does that resolve it? Regards Archana On 2018/06/21 07:53:48, Andrea Turli wrote: > Mmm very interesting! > > The only thing that comes to my mind is: > - is your

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread archieprad
Hi Ignasi, Thank you! I will try this out and let you know if it worked. Cheers Archana On 2018/06/21 08:00:01, Ignasi Barrera wrote: > Hi Archana, > > I see the problem here. When using temporary credentials in AWS, the > session token must be included in a request header [1], so you need to

Re: error while running JCloudsNove.java

2018-06-21 Thread jayshankar nair
Hi Ignasi, I have included the header file. I am getting the following error in override.  javac -classpath ".:lib/*" JCloudsNova.javaJCloudsNova.java:56: error: cannot find symbol   .overrides(overrides)              ^  symbol:   variable overrides  location: class JCloudsNova1 error Code

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread archieprad
Hi Andrea, I tried the two methods that you suggested and neither of them work. I also tried another method listHardwareProfiles() and it works. Is there some different level of authentication required across these? Please do let me know what you think. Cheers Archana On 2018/06/20 07:26:44,

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread Andrea Turli
Archana, interesting! To debug this, I would attach a IAM role with e.g the AmazonEC2FullAccess policy set and re-test. If that works, I'll then try to play with more restricting policies, in case you don't like AmazonEC2FullAccess in production. Best, Andrea On Thu, Jun 21, 2018 at 9:34 AM

Re: error while running JCloudsNove.java

2018-06-21 Thread Ignasi Barrera
The KeystoneProperties class is in the "org.jclouds.openstack.keystone.config" package. If you have jclouds 2.1.0 you should have no issues to import all classes referenced in the example. On 21 June 2018 at 08:40, jayshankar nair wrote: > Hi, > > I am getting compilation errors. What is the

Re: Issue with jclouds computeService listNodes() ?

2018-06-21 Thread archieprad
Hi Andrea, Thanks for the quick response. I am using an IAM role that has full admin access. Which is why this case is even more perplexing. Do you have any other suggestions to try out? Cheers Archana On 2018/06/20 21:45:31, archiep...@gmail.com wrote: > Hi Ignasi, > So the function that

Re: error while running JCloudsNove.java

2018-06-21 Thread Ignasi Barrera
"Caused by: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?" It looks like you are configuring an "https" endpoint, but in the service list you passed, the V3 identity endpoint is "http". Copy the right endpoint and try again. On 21 June 2018 at 11:33, jayshankar nair

Re: error while running JCloudsNove.java

2018-06-21 Thread jayshankar nair
Hello Ignasi, I apologise for the silly mistake .I  would use better ide like Netbeans. I am still not able to run the code. I have sent the error dump earlier. Can u suggest some pointers.  Thanks in advance.JayshankarOn Thursday, June 21, 2018, 2:43:25 PM GMT+5:30, Ignasi Barrera wrote:

Re: Signature v4 support for non amazon S3

2018-06-21 Thread Ranjith R
I was looking at https://issues.apache.org/jira/browse/JCLOUDS-480 and it talks about the default signing for AWS being v4 and other s3 clones being v2. I just want to know if I can use v4 for a s3 clone? Is there any example that I can look at? Thanks, Ranjith On Mon, Jun 18, 2018 at 7:21 PM

Re: Signature v4 support for non amazon S3

2018-06-21 Thread Ignasi Barrera
I haven't tried it, but you should be able to define a Guice module that extends the default S3 module and overrides the request signer configuration. Then you can pass that one to the list of modules you pass when creating the context: @ConfiguresHttpApipublic static class S3V4SignerModule

Re: Signature v4 support for non amazon S3

2018-06-21 Thread Ranjith R
Thanks Ignasi. That worked. Thanks, Ranjith On Thu, Jun 21, 2018 at 4:03 PM Ignasi Barrera wrote: > I haven't tried it, but you should be able to define a Guice module that > extends the default S3 module and overrides the request signer > configuration. Then you can pass that one to the list

Re: Signature v4 support for non amazon S3

2018-06-21 Thread Ranjith R
With sigv4, we see that we are doing single chunk upload with signed payload. We also noticed that the data is read twice (once for calculating the hash and once for actual transfer). While reading the sig v4 documentation at

Re: Signature v4 support for non amazon S3

2018-06-21 Thread Ignasi Barrera
Yeah! :) On 21 June 2018 at 16:41, Ranjith R wrote: > Thanks Ignasi. That worked. > > Thanks, > Ranjith > > On Thu, Jun 21, 2018 at 4:03 PM Ignasi Barrera wrote: > >> I haven't tried it, but you should be able to define a Guice module that >> extends the default S3 module and overrides the

Re: error while running JCloudsNove.java

2018-06-21 Thread jayshankar nair
Hi, I am getting compilation errors. What is the header file for KeystoneProperties. error: package org.jclouds.openstack.keystone does not exist  import org.jclouds.openstack.keystone.*;  ^JCloudsNova.java:22: error: cannot find symboloverrides.put(KeystoneProperties.KEYSTONE_VERSION, "3");