Results matching “PAWS”

Paws XXV (A break though)

Well today’s post marks a tuning point in Paws me thinks, at least in the S3 name-space. I have been spending quite allot of time trying to get this action to work;

PutBucketAcl

It is the most nasty bit of AWS code I have come across so far. First one needs to send this XML up to AWS;

<AccessControlPolicy xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
  <Owner>
    <ID>852b113e7a2f25102679df27bb0ae12b3f85be6BucketOwnerCanonicalUserID</ID>
    <DisplayName>OwnerDisp…

Paws XXIV (A little Buzz)

Well after the panic stations I talked about in my last post. I have calmed down a little. It seems that huge check in was for the compiled version of the code base and 99% of the changes where just auto-auto-generated stuff chugged out by boto when it re-compiles.

That being said I did find this thread while investigating the mother of all pushes; https://github.com/pplu/aws-sdk-perl/issues/244

Requirements for stabilisation?

shadowcat-mst commented on 24 May 2018
So, a number of components in Paws have something like this -
https://meta…

Paws XXIII (Bad Paws!! Bad Paws!!)

So I have been happily plugging away at the Paws 'S3' actions and my little Boto fix of


/{Bucket}?action
/{Bucket}?action&id={Id}

I was able to get all of these 'Actions' to work;

  • DeleteBucketAnalyticsConfiguration
  • DeleteBucketInventoryConfiguration
  • DeleteBucketMetricsConfiguration
  • GetBucketAnalyticsConfiguration
  • GetBucketInventoryConfiguration
  • GetBucketMetricsConfiguration
  • ListBucketInventoryConfiguration
  • ListBucketMetricsConfigurat…

Paws XXII (Plana est terra)

The next action I had a crack at was 'PutCORSConfiguration' and I was getting the usual;

<Error> <Code>MalformedXML</Code> <Message>The XML you provided was not well-formed or did not validate against our published schema </Message> </Error>

At this points in my Paws adventure I checked the API doc for URI Request Parameters of the PutCORSConfiguration;

PUT /?cors HTTP/1.1 Host: Bucket.s3.amazonaws.com Content-MD5: ContentMD5

a…

Paws XXI (The Adult Version)

We last left out PAWS hero she was just about ready to fix the S3 'PutBucketAnalyticsConfiguration' call. Having first fixed up the botocore json file to properly define the URI for the call.

She now had to find a way to get the 'xmlns' schema attribute add to the root of the XML that is sent to the API.

Turns out I was in very virgin territory there has been no Paws code to take this into account and checking the py code it was not very helpful so I have to put my thinking cap on for this one.

I was thinking I could just make it a new 'trait' like I did for the '…

Paws XX (Dos Equis)

Well the saw-buck edition of Paws proved to be a real tough one a least for me. I my last post I was just thinking of fixing all the S3 calls that do not have a test I was just going to start with all the delete calls but I decided to rater take a functional approach and tackle the calls in that order so I started out with the 'Analytics' calls

  • DeleteBucketAnalyticsConfiguration
  • GetBucketAnalyticsConfiguration
  • ListBucketAnalyticsConfigurations
  • PutBucketAnalyticsConfiguration

The first one I was going to play with was the 'PutBuc…

Paws XIX (The I between)

Paws S3 is coming together nicely I just have one more 'S3' todo test to look at and that is the get 'ListObjectVersions' test.

To start I fixed up the 'ListObjectVersions' test much like this



call: ListObjectVersions
service: S3
tests:
- expected: bucket
op: eq
path: Name
- expected: my
op: eq
path: Prefix
- expected: 5
op: eq
path: MaxKeys
- expected: 0
op: eq
path: IsTruncated
- expected: my-image.jp…

Paws XVIII

Well the first thing for my S3 todo fixes was to get everything back up to github for my fix for 'GetBucketLocation' once that was done I decided to tackle the rest of the 'todo' tests.

I started out with 'GetBucketPolicy' but I notices that when I set up a real test for the code I get this as the content response;


'content' => '{"Version":"2012-10-17","Id":"S3-Console-Auto-Gen-Policy-1567770368320","Statement":[{"Sid":"S3PolicyStmt-DO-NOT-MODIFY-1567770368320","Effect":"Allow","Principal":{"Service":"s3.amazonaws.com"},"Action":"s3:PutObject"…

Paws XVII (The last of the direct line for the Bourbons at least)

I finally (well a few days ago) had a response to another of my questions up on gitihub;

-->me I added in th status as you suggests. I found it under botocore as "location":"statusCode", It is used in a number of other classes


-->they

This means that we can make the builders put the trait on the appropiate attributes, which I see you already found ?

-->me

I added it in as a new trait as you suggested, not 100% sure on the name though

-->they

I think the name would better be ParamInStatus (just as a reflex of the ot…

Paw XVI

Well I though I hit the correct fix when Paws does its XML parsing and drops the 'Root' node but I found I have to apply some sort 'trait' to my class rather than an attribute so I am going to start this time with my code for 'RestXMLResponse.pm' first and then work that fix back into boto and the templates.

What I want to do is this


 if ($ret_class->can('_stream_param')) {
      $unserialized_struct = {}
    } else {
      if (not defined $content or $content eq '') {
        $unserialized_struct = {}
      } else {
        my $keep_root = 0;
…
  1 2 3 4 5 6  

About byterock

user-pic Long time Perl guy, a few CPAN mods allot of work on DBD::Oracle and a few YAPC presentations