logstash-plugins / logstash-output-sqs

Apache License 2.0
4 stars 22 forks source link

sqs input does not work after a while #1

Open suyograo opened 9 years ago

suyograo commented 9 years ago

From https://logstash.jira.com/browse/LOGSTASH-2255

Hi,

We have been using sqs output plugin on different logstash version. At last, It it is used on logstash 1.4.1. In that version, per every 2-3 weeks, the sqs plugin has been crashed. It has been stopping to receive from sqs queue but logstash has been continued to work.. After logstash restarted, everything goes fine. Yesterday it repeated, we catched below log.

Note: We are using IAM roles on Aws to authenticate aws sqs service.

{:timestamp=>"2014-06-22T08:10:43.067000+0000", :message=>"Error reading SQS queue.", :error=>#<AWS::SQS::Errors::SignatureDoesNotMatch: The request signature we calculated does not match the signature you provided. Check your AWS Secret Access Key and signing method. Consult the service documentation for details.

The Canonical String for this request should have been 'POST /544087101480/WsServiceLogs

content-length:231 content-type:application/x-www-form-urlencoded; charset=utf-8 host:sqs.eu-west-1.amazonaws.com user-agent:aws-sdk-ruby/1.35.0 jruby/1.9.3 java x-amz-content-sha256:e55e8ad53e44c3f51337e79c5be913b4980ecf21b7fdfd4f7bad182a2bb3b8bc x-amz-date:20140622T081042Z x-amz-security-token:AQoDYXdzECka0AOo3QtT3g/……………………………………………. EIk1IAokX2D53/F0qXjvND4XbEyCykZqdBQ==

content-length;content-type;host;user-agent;x-amz-content-sha256;x-amz-date;x-amz-security-token e55e8ad53e44c3f5…………………………b7fdfd4f7bad182a2bb3b8bc'

The String-to-Sign should have been 'AWS4-HMAC-SHA256 20140622T081042Z 20140622/eu-west-1/sqs/aws4_request 4100c5a8468784……………………………………..77c7794563d201'

thanks,

mcasado commented 9 years ago

Running into same exact issue. Any estimates when a fix for it will be available? THx

gbutt commented 9 years ago

Any errors in the SQS Output plugin will cause logstash to crash. It needs better error handling around the 'receive' event. Personally I'd rather see this kind of handling make it in to the core framework so one misbehaving plugin doesn't risk the stability of the entire app.

jrgns commented 7 years ago

Can anyone comment on if this is still an issue with the latest version of logstash (5) and the latest version of this plugin (4) ?