Git Product home page Git Product logo

goaws's People

Contributors

admiral-piett avatar andreyserdjuk avatar andykuszyk-form3 avatar canthefason avatar chrisdaly3 avatar days1eeper avatar dependabot[bot] avatar dexm avatar dhumphreys01 avatar eligijusvitkauskas-home24 avatar fffinkel avatar forrest-ua avatar iambbs avatar innossh avatar jeloou avatar jemmyw avatar kukushkin avatar mbklein avatar nelsonjchen avatar nicolas-miller-storable avatar p4tin avatar pfortin-urbn avatar pjarmalavicius avatar qhenkart avatar queeno avatar sebcante avatar slang25 avatar stanleyrh avatar tomasbartkus avatar ulich avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

goaws's Issues

Installation Error

When I run go get github.com/p4tin/GoAws

I get the following error:

can't load package: package github.com/p4tin/GoAws: case-insensitive import collision: "github.com/p4tin/GoAws/vendor/github.com/gorilla/context" and "github.com/p4tin/goaws/vendor/github.com/gorilla/context"

I'm on a mac and I assume this has something to do with the fact that the filesystem is case insensitive. Using go get github.com/p4tin/goaws seemed to fix it.

add json support for SQS

This is the best emulator I could find, unfortunately I'm using Spring Boot and our API accepts only JSON. It seems you only support XML for SQS, so I get:

c.a.http.DefaultErrorResponseHandler     : Unable to parse HTTP response (Invocation Id:0cd30c53-daa3-b1e8-4d99-cb64d5ee29fb) content to XML document 'Bad Request' 

org.xml.sax.SAXParseException: Content is not allowed in prolog.
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:203)
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:177)
	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:400)
	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:327)
	at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1472)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:994)
etc.

I dunno if I'm doing something wrong, but in case you only support XML, I'd like to ask for json support. I would like to use this emulator so much. Thank you very much.

QueueUrl >> make configurable

I'm integrating the docker image into a docker-compose environment. I'm having trouble as SQS queues coming back from getqueueurl are all pointing to localhost, which is not correct in this environment and won't work as obviously my application is running on a different container.

listSubscriptionsByTopic not working properly

listSubscriptionsByTopic() does not return the subscription list.
After adding a few subscriptions using sns.subscribe(topicArn, sqsArn) I can get the list of subscriptions using listSubscriptions()
But if I want to only get subsciptions for a specific topic using the listSubscriptionsByTopic, the only data in result is ResponseMetadata, although I see I have subscriptions for the specified topicArn.

Installation instructions may need update

When attempting to install the package per the instructions, I get an error:

ubuntu@ubuntu-xenial:~/go$ go get github.com/p4tin/goaws
package github.com/p4tin/goaws: no buildable Go source files in /home/ubuntu/go/src/github.com/p4tin/goaws

I have very little knowledge of Go, but it looks like it was caused by commit 69bc0b0, which removed all the .go files from the project root.

Perhaps the installation instructions need to be updated?

AWS.SimpleQueueService.NonExistentQueue

When trying to GetQueueAttributes, goaws cannot find the que. However, when ListQueues, you can see the que is listed.

Here is an example request:
GET
http://aws:4100/queue/A15-QA-CONVENIENCE-CURRENCY-CHANGE?Action=GetQueueAttributes&AttributeName=ApproximateNumberOfMessages&Version=2012-11-05

With response:

[2017-03-06 12:32:28,944: INFO/MainProcess] Connected to emq://LOCAL:**@aws:4100//
[2017-03-06 12:32:28,956: ERROR/MainProcess] 400 Bad Request
[2017-03-06 12:32:28,956: ERROR/MainProcess]   <ErrorResponse>
      <Error>
          <Type>Not Found</Type>
          <Code>AWS.SimpleQueueService.NonExistentQueue</Code>
          <Message>The specified ueue does not exist for this wsdl version.</Message>
          <RequestId>00000000-0000-0000-0000-000000000000</RequestId>
      </Error>
  </ErrorResponse>
[2017-03-06 12:32:28,957: CRITICAL/MainProcess] Frequent restarts detected: RestartFreqExceeded('5 in 1s',)
Traceback (most recent call last):
  File "/opt/python2.7/lib/python2.7/site-packages/celery/worker/consumer.py", line 285, in start
    self._restart_state.step()
  File "/opt/python2.7/lib/python2.7/site-packages/billiard/common.py", line 130, in step
    raise self.RestartFreqExceeded("%r in %rs" % (R, self.maxT))
RestartFreqExceeded: 5 in 1s

SQS Improper Return Code

Hi, I found some behavior with sqs that doesn't perfectly match in the emulator.

Specifically, when attempting to create a queue, if you try and create another queue with the same name, it normally would just give a 200, since the queue has already been created. But if you try and create a queue with the same name and a different retention period, on the GUI it shows this:

image

And on the command line, aws gives back a 400 in this case. goaws returns a 200 regardless.

Implement create-topic

So far, this meets nearly all of my needs to a completely local development environment.

Thank you!

If you implement create-topic, it will then satisfy my needs to test everything, including infrastructure setup, locally.

I'm building our go chops now. We may implement this as a PR once we have confidence to do so.

As a GoAWS Docker user, I would like to pass AWS related information as parameter so I can use GoAWS together with other local AWS services, such as Local DynamoDB

I'm currently using a local DynamoDB Docker which supports the parameters below and as many of us do use SNS/SQS within other AWS services, would be nice to have these options so we could use GoAWS with other AWS local services.

-e AWS_ACCESS_KEY_ID=key -e AWS_SECRET_ACCESS_KEY=secret aws --region us-east-1 dynamodb --endpoint http://localhost:8000/

`go get github.com/p4tin/goaws` stopped working

At some point in the last months, the command in the Readme started giving this error on new machines:

$ go version
go version go1.2.1 linux/amd64
$ sudo GOPATH=/usr/local/src go get github.com/p4tin/goaws                                  
package github.com/p4tin/goaws
        imports github.com/p4tin/goaws
        imports github.com/p4tin/goaws: no buildable Go source files in /usr/local/src/src/github.com/p4tin/goaws

To work around this, I now do:

            go get -d github.com/p4tin/goaws
            cd /usr/local/src/github.com/p4tin/goaws
            git checkout 941608ca3f63bdace571268a241d6835002edd94
            go get github.com/p4tin/goaws

as that commit was one that got installed on existing machines. This sequence correctly compiles and installs a goaws binary.

If queue does not exist, do not crash

Hi,

Thank you for the quality of this docker container, it's very useful.

If you try to push on a non existing queue, you will have a "panic" error and the process is not sending any result or error, letting all clients waiting for answers.

All the best.

Max

Implement platform specific raw message delivery

SNS allows you to set platform specific data in the message body like so:

{
    "default":  "I am the default message.",
    "sqs": "I am the message that if raw delivery is enabled"
}

Currently, goaws doesn't handle platform specific data. Will be opening a fork to work on this, but also wanted to open an issue for more discussion.

Incompatible with Node js aws-sdk

Hi! This is less of an issue with goaws and more of an issue with the Node.js aws-sdk. I am able to setup goaws correctly and pass all of the tests from the aws cli, however when using the local SNS ARN, I am receiving the following error:

Invalid parameter: TopicArn Reason: A local ARN must begin with arn:null, not arn:aws:sns:local:000000000000:topic1

My code is simple

AWS.config.update({
    region: 'us-west-1'
});
var sns = new AWS.SNS();
var params = {
    Message: 'some text'
    TopicArn: 'arn:aws:sns:local:000000000000:topic1
}; 
sns.publish(params)

I am wondering if anyone has run into this issue before?!

Invalid type for parameter MessageAttributes.name, value: <>, type: <type 'unicode'>, valid types: <type 'dict'>

Trying to post this json:

{
	"id": "0aa432db-c1ee-40d2-aef9-4b80ff20010f",
	"identityId": "0aa432db-c1ee-40d2-aef9-4b80ff20010f",
	"name": "test",
	"state": "test",
	"createdAt": "2017-03-03T14:31:05.190Z",
	"modifiedAt": "2017-03-03T14:31:05.190Z",
	"repositoryName": "test",
	"applicationId": "0aa432db-c1ee-40d2-aef9-4b80ff20010f"
}

aws --endpoint-url http://localhost:4100 sqs send-message --queue-url http://aws:4100/queue/local-queue1 --message-body "project_created" --message-attributes file://project_created.json

results in:

Invalid type for parameter MessageAttributes.id, value: 0aa432db-c1ee-40d2-aef9-4b80ff20010f, type: <type 'unicode'>, valid types: <type 'dict'>
Invalid type for parameter MessageAttributes.identityId, value: 0aa432db-c1ee-40d2-aef9-4b80ff20010f, type: <type 'unicode'>, valid types: <type 'dict'>
Invalid type for parameter MessageAttributes.name, value: test, type: <type 'unicode'>, valid types: <type 'dict'>
Invalid type for parameter MessageAttributes.state, value: test, type: <type 'unicode'>, valid types: <type 'dict'>
Invalid type for parameter MessageAttributes.createdAt, value: 2017-03-03T14:31:05.190Z, type: <type 'unicode'>, valid types: <type 'dict'>
Invalid type for parameter MessageAttributes.modifiedAt, value: 2017-03-03T14:31:05.190Z, type: <type 'unicode'>, valid types: <type 'dict'>
Invalid type for parameter MessageAttributes.repositoryName, value: test, type: <type 'unicode'>, valid types: <type 'dict'>
Invalid type for parameter MessageAttributes.applicationId, value: 0aa432db-c1ee-40d2-aef9-4b80ff20010f, type: <type 'unicode'>, valid types: <type 'dict'>```

Trying with:

```{"project_created": {
	"id": "0aa432db-c1ee-40d2-aef9-4b80ff20010f",
	"identityId": "0aa432db-c1ee-40d2-aef9-4b80ff20010f",
	"name": "test",
	"state": "test",
	"createdAt": "2017-03-03T14:31:05.190Z",
	"modifiedAt": "2017-03-03T14:31:05.190Z",
	"repositoryName": "test",
	"applicationId": "0aa432db-c1ee-40d2-aef9-4b80ff20010f"
    }
}```

I get:

```Parameter validation failed:
Missing required parameter in MessageAttributes.project_created: "DataType"
Unknown parameter in MessageAttributes.project_created: "id", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType
Unknown parameter in MessageAttributes.project_created: "identityId", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType
Unknown parameter in MessageAttributes.project_created: "name", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType
Unknown parameter in MessageAttributes.project_created: "state", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType
Unknown parameter in MessageAttributes.project_created: "createdAt", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType
Unknown parameter in MessageAttributes.project_created: "modifiedAt", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType
Unknown parameter in MessageAttributes.project_created: "repositoryName", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType
Unknown parameter in MessageAttributes.project_created: "applicationId", must be one of: StringValue, BinaryValue, StringListValues, BinaryListValues, DataType```

What am I missing?

Subject and Message is empty when receiving message from queue that was published with sns

Hi,
thanks for the project. I'm having an issue when receiving a message from SQS that was published by SNS:

sebastian:~/Development/message$ aws --endpoint-url http://localhost:4100 sns create-topic --name something-happend
{
    "TopicArn": "arn:aws:sns:local:000000000000:something-happend"
}
sebastian:~/Development/message$ aws --endpoint-url http://localhost:4100 sqs create-queue --queue-name something-happened
{
    "QueueUrl": "http://localhost:4100/queue/something-happened"
}
sebastian:~/Development/message$ aws --endpoint-url http://localhost:4100 sns subscribe --topic-arn arn:aws:sns:local:000000000000:something-happend --protocol sqs --notification-endpoint http://localhost:4100/queue/something-happened
{
    "SubscriptionArn": "arn:aws:sns:local:000000000000:something-happend:41846153-40d1-42fc-af39-649b48bac0fb"
}
sebastian:~/Development/message$ aws --endpoint-url http://localhost:4100 sns publish --topic-arn arn:aws:sns:local:000000000000:something-happend --subject test --message test
{
    "MessageId": "c91ac05a-be13-4a4a-9d04-8646274b0389"
}
sebastian:~/Development/message$ aws --endpoint-url http://localhost:4100 sqs receive-message --queue-url http://localhost:4100/something-happened
{
    "Messages": [
        {
            "ReceiptHandle": "29f556cc-79b8-4f1e-b3b8-7d34e121a9b2#fa293d47-48ef-4402-8173-43f2df13b1d6",
            "MessageId": "29f556cc-79b8-4f1e-b3b8-7d34e121a9b2",
            "Body": "{\"Type\":\"Notification\",\"MessageId\":\"9f967ab3-dce0-4667-93f2-20032cb409d2\",\"TopicArn\":\"arn:aws:sns:local:000000000000:something-happend\",\"Subject\":\"\",\"Message\":\"\",\"TimeStamp\":\"2016-12-22T10:12:26:012Z\\n\"}",
            "MD5OfBody": "b49c3ab34610f6ac60fa57006fe040ef"
        }
    ]
}
sebastian:~/Development/message$ aws --endpoint-url http://localhost:4100 sqs receive-message --queue-url http://localhost:4100/something-happened

Problem is that Subject and Message is empty when receiving the message from SQS.

Am I doing something wrong or is that not implemented (yet)?

if QueueUrl is empty in request parameters, request fails

I am using AWSSDK 2.3.55.2 for .Net Framework
I have connected to the goaws.exe via the next C# code:

var request = new ReceiveMessageRequest
{
QueueUrl = "http://localhost:4100/queue/test_queue",
MaxNumberOfMessages = 5,
WaitTimeSeconds = 0
};

        var amazonSqsConfig = new AmazonSQSConfig();
        amazonSqsConfig.ServiceURL = "http://localhost.fiddler:4100";

        var amazonSqsClient = new AmazonSQSClient(new BasicAWSCredentials("x", "x"), amazonSqsConfig);
        Debugger.Break();
        ReceiveMessageResponse response = amazonSqsClient.ReceiveMessageAsync(request).Result;

As a result, in the response I am expecting to get messages that are already in the test_queue, but instead I am receiving the next error:

{"The remote server returned an error: (400) Bad Request."}. Message: "The specified ueue does not exist for this wsdl version."

To figure out what happens and why I used fiddler to track the post request that AmazonSQSClient is sending. I figured out that AmazonSQSClient sends the next POST request:

POST http://localhost:4100/queue/development_brandupdatesmessage_v0 HTTP/1.1
User-Agent: aws-sdk-dotnet-45/2.3.55.2 .NET Runtime/4.0 .NET Framework/4.0 OS/6.2.9200.0 ClientAsync
Content-Type: application/x-www-form-urlencoded; charset=utf-8
host: localhost:4100
X-Amz-Date: 20170209T084928Z
X-Amz-Content-SHA256: 4fc28a78714c6b6ecd8bb88bcc81331e9d279dfe61f617b50574070e171cd4a5
Authorization: AWS4-HMAC-SHA256 Credential=x/20170209/us-east-1/sqs/aws4_request, SignedHeaders=content-type;host;user-agent;x-amz-content-sha256;x-amz-date, Signature=0abc1eb8930d27786ae49e60198124e80505ffabeb23335d9fb33e78aab877fd
Content-Length: 80
Connection: Keep-Alive

Action=ReceiveMessage&MaxNumberOfMessages=5&Version=2012-11-05&WaitTimeSeconds=0

As we can see here in the request body there is no QueueUrl parameter. It is now in the request Url:

POST http://localhost:4100/queue/development_brandupdatesmessage_v0 HTTP/1.1

The bug is that goaws cannot handle this situation. For aws it is not a problem.
The fix would be if QueueUrl is not present in the request body, take it from the request url.

SNS subscribe(topicArn, sqsArn) is duplicating subscriptions

Just like queues and topics do not duplicate if you call the CreateQueue/CreateTopic with the same name multiple times, the Subscribe(topicArn, queueArn) does not duplicate the subscription when using same topicArn and queueArn pair on actual aws, while goaws does not work like expected, it keeps adding the subscriptions.

This can be tested using the postman collection from the readme, executing the Subscribe multiple times and then checking the result of ListSubscriptions will show that there are multiple subscriptions with same topic/queue pairs.

sns list-topic returns empty when it should not if accessed via hostname

This works fine for me when accessed from localhost, but when you try to list-topics via docker to docker network connections, you get an empty array of topics.

> aws \
    --endpoint-url http://my-docker-container:4100 \
    sns \
    create-topic \
    --name some-cool-topic

> aws \
    --endpoint-url http://my-docker-container:4100 
    sns \
    list-topics
{
    "Topics": []
}

I'm trying to debug the issue, and I can see that that ListTopics seems to have the right data, at some point afterwords the topics are getting lost.

Any ideas? My Go is not so good.

MD5 checksum of message attributes incorrect

It seems that the checksum generation of SQS message attributes is not implemented, correct? In
https://github.com/p4tin/goaws/blob/c4d80809ebe7f664226bd62fc60f355ae7a8b8ed/app/gosqs/gosqs.go#L131 the checksum of the message attributes is always computed from the static string GoAws.

When using the java sdk when talking to SQS, sending a message to the queue fails because the client computes a different checksum for the message attributes than what goaws returns.

    private static void sendMessageOperationMd5Check(SendMessageRequest sendMessageRequest, SendMessageResult sendMessageResult) {
        String messageBodySent = sendMessageRequest.getMessageBody();
        String bodyMd5Returned = sendMessageResult.getMD5OfMessageBody();
        String clientSideBodyMd5 = calculateMessageBodyMd5(messageBodySent);
        if(!clientSideBodyMd5.equals(bodyMd5Returned)) {
            throw new AmazonClientException(String.format("MD5 returned by SQS does not match the calculation on the original request. (MD5 calculated by the %s: \"%s\", MD5 checksum returned: \"%s\")", new Object[]{"message body", clientSideBodyMd5, bodyMd5Returned}));
        } else {
            Map<String, MessageAttributeValue> messageAttrSent = sendMessageRequest.getMessageAttributes();
            if(messageAttrSent != null && !messageAttrSent.isEmpty()) {
                String clientSideAttrMd5 = calculateMessageAttributesMd5(messageAttrSent);
                String attrMd5Returned = sendMessageResult.getMD5OfMessageAttributes();
                if(!clientSideAttrMd5.equals(attrMd5Returned)) {
                    throw new AmazonClientException(String.format("MD5 returned by SQS does not match the calculation on the original request. (MD5 calculated by the %s: \"%s\", MD5 checksum returned: \"%s\")", new Object[]{"message attributes", clientSideAttrMd5, attrMd5Returned}));
                }
            }

        }
    }
com.amazonaws.AmazonClientException: MD5 returned by SQS does not match the calculation on the original request. (MD5 calculated by the message attributes: "3226c32921e2bcda84eed17654164acc", MD5 checksum returned: "b095c6d16871105acb75d59332513337")
	at com.amazonaws.services.sqs.MessageMD5ChecksumHandler.sendMessageOperationMd5Check(MessageMD5ChecksumHandler.java:120) ~[aws-java-sdk-sqs-1.11.98.jar:na]
	at com.amazonaws.services.sqs.MessageMD5ChecksumHandler.afterResponse(MessageMD5ChecksumHandler.java:80) ~[aws-java-sdk-sqs-1.11.98.jar:na]
	at com.amazonaws.handlers.RequestHandler2Adaptor.afterResponse(RequestHandler2Adaptor.java:49) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.http.AmazonHttpClient$RequestExecutor.afterResponse(AmazonHttpClient.java:971) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.http.AmazonHttpClient$RequestExecutor.doExecute(AmazonHttpClient.java:745) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.http.AmazonHttpClient$RequestExecutor.executeWithTimer(AmazonHttpClient.java:716) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.http.AmazonHttpClient$RequestExecutor.execute(AmazonHttpClient.java:699) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.http.AmazonHttpClient$RequestExecutor.access$500(AmazonHttpClient.java:667) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.http.AmazonHttpClient$RequestExecutionBuilderImpl.execute(AmazonHttpClient.java:649) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:513) ~[aws-java-sdk-core-1.11.98.jar:na]
	at com.amazonaws.services.sqs.AmazonSQSClient.doInvoke(AmazonSQSClient.java:1689) ~[aws-java-sdk-sqs-1.11.98.jar:na]
	at com.amazonaws.services.sqs.AmazonSQSClient.invoke(AmazonSQSClient.java:1665) ~[aws-java-sdk-sqs-1.11.98.jar:na]
	at com.amazonaws.services.sqs.AmazonSQSClient.sendMessage(AmazonSQSClient.java:1435) ~[aws-java-sdk-sqs-1.11.98.jar:na]
	at com.amazon.sqs.javamessaging.AmazonSQSMessagingClientWrapper.sendMessage(AmazonSQSMessagingClientWrapper.java:168) ~[amazon-sqs-java-messaging-lib-1.0.2.jar:na]
	at com.amazon.sqs.javamessaging.SQSMessageProducer.sendInternal(SQSMessageProducer.java:111) ~[amazon-sqs-java-messaging-lib-1.0.2.jar:na]
	at com.amazon.sqs.javamessaging.SQSMessageProducer.send(SQSMessageProducer.java:291) ~[amazon-sqs-java-messaging-lib-1.0.2.jar:na]
	at org.springframework.jms.core.JmsTemplate.doSend(JmsTemplate.java:626) ~[spring-jms-4.3.7.RELEASE.jar:4.3.7.RELEASE]
	at org.springframework.jms.core.JmsTemplate.doSend(JmsTemplate.java:597) ~[spring-jms-4.3.7.RELEASE.jar:4.3.7.RELEASE]
	at org.springframework.jms.core.JmsTemplate$4.doInJms(JmsTemplate.java:574) ~[spring-jms-4.3.7.RELEASE.jar:4.3.7.RELEASE]
	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:484) ~[spring-jms-4.3.7.RELEASE.jar:4.3.7.RELEASE]
	at org.springframework.jms.core.JmsTemplate.send(JmsTemplate.java:570) ~[spring-jms-4.3.7.RELEASE.jar:4.3.7.RELEASE]
	at org.springframework.jms.core.JmsTemplate.convertAndSend(JmsTemplate.java:658) ~[spring-jms-4.3.7.RELEASE.jar:4.3.7.RELEASE]

Fix issues using python - boto

Seems like some of the calls from boto either send params differently or expect results in a different way. This ticket is to implement those boto idiosyncrasies without affecting the underlying code that works with other clients.

Log all messages to a file

When Publish or Send Message is called log the messages to a log file that will be added to the environment yaml file (default to: ./goaws_messages.log). Logging messages should be able to be turned on and off in yaml.

Readme build instructions not working

The instructions to build & to "go get .." command give the error "Can't load package .": No buildable go files in (path). Can't figure out a way around this

Cannot receive message with aws cli

$ aws --version
aws-cli/1.2.9 Python/3.4.3 Linux/3.13.0-103-generic
$ sudo docker images
REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE
pafortin/goaws      latest              902625ed9b2a        5 months ago        14.46 MB

When I try to receive a message in the queue:

$ aws --endpoint-url http://localhost:4100 sqs receive-message --queue-url http://localhost:4100/test1
{
    "Messages": []
}

but if I turn on debug logs, I can in part see the result:

$ aws --debug --endpoint-url http://localhost:4100 sqs receive-message --queue-url http://localhost:4100/test1                         
...
2017-01-13 14:22:21,582 - botocore.endpoint - DEBUG - Sending http request: <PreparedRequest [POST]>
2017-01-13 14:22:21,592 - botocore.response - DEBUG - Response Body:
b'  <ReceiveMessageResponse>\n      <ReceiveMessageResult>\n          <Message>\n              <MessageId>cb599c62-1e89-42c0-87b8-63a1cbfaffb7</MessageId>\n              <ReceiptHandle>cb599c62-1e89-42c0-87b8-63a1cbfaffb7#564933e2-a158-441a-b880-de6a490dfec8</ReceiptHandle>\n              <MD5OfBody>9d3f5eaac3b1b4dd509f39e71e25f954</MD5OfBody>\n              <Body>this is a test of the GoAws Queue messaging</Body>\n          </Message>\n      </ReceiveMessageResult>\n      <ResponseMetadata>\n          <RequestId>00000000-0000-0000-0000-000000000000</RequestId>\n      </ResponseMetadata>\n  </ReceiveMessageResponse>'
2017-01-13 14:22:21,594 - botocore.hooks - DEBUG - Event needs-retry.sqs.ReceiveMessage: calling handler <botocore.retryhandler.RetryHandler object at 0x7f1fa44a6b00>
2017-01-13 14:22:21,595 - botocore.retryhandler - DEBUG - No retry needed.
2017-01-13 14:22:21,597 - botocore.hooks - DEBUG - Event after-call.sqs.ReceiveMessage: calling handler <awscli.errorhandler.ErrorHandler object at 0x7f1fa47b4ba8>
2017-01-13 14:22:21,598 - awscli.errorhandler - DEBUG - HTTP Response Code: 200
{
    "Messages": []
}

I thought the aws cli tools may require some particular format in the response that is not fully implemented, so I'll report it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.