Forum: Ruby on Rails S3 throwing invalid argument using AWS S3 API

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Eric G. (Guest)
on 2007-01-07 00:46
Hello,

Im using the following amazon web service API for S3 :


http://amazon.rubyforge.org/

The problem is that after I establish a connection using
establish_connection!, and try using the "store" command, I keep getting
the following error. However, if I reboot my webrick server, it works
fine for about one hour and then starts throwing this error:

 Errno::EINVAL in UsersController#upload_pic

Invalid argument

RAILS_ROOT: ./script/../config/..
Application Trace | Framework Trace | Full Trace

E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:175:in `write'
E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:175:in `write0'
E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:151:in `write'
E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:166:in `writing'
E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:150:in `write'
E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1542:in `write_header'
E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1513:in
`send_request_with_body'
E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1496:in `exec'
E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1044:in `request'
E:/InstantRails/ruby/lib/ruby/gems/1.8/gems/aws-s3-0.3.0/lib/aws/s3/connection.rb:41:in
`request'


Does anyone know why this could be?
mixplate (Guest)
on 2007-06-05 18:51
hey have you ever found the solution? i think i have the same problem
even on my production server. ive read around google that there may be a
bug in ruby about handling timeouts/header information.


Aryk G. wrote:
> Hello,
>
> Im using the following amazon web service API for S3 :
>
>
> http://amazon.rubyforge.org/
>
> The problem is that after I establish a connection using
> establish_connection!, and try using the "store" command, I keep getting
> the following error. However, if I reboot my webrick server, it works
> fine for about one hour and then starts throwing this error:
>
>  Errno::EINVAL in UsersController#upload_pic
>
> Invalid argument
>
> RAILS_ROOT: ./script/../config/..
> Application Trace | Framework Trace | Full Trace
>
> E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:175:in `write'
> E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:175:in `write0'
> E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:151:in `write'
> E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:166:in `writing'
> E:/InstantRails/ruby/lib/ruby/1.8/net/protocol.rb:150:in `write'
> E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1542:in `write_header'
> E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1513:in
> `send_request_with_body'
> E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1496:in `exec'
> E:/InstantRails/ruby/lib/ruby/1.8/net/http.rb:1044:in `request'
> E:/InstantRails/ruby/lib/ruby/gems/1.8/gems/aws-s3-0.3.0/lib/aws/s3/connection.rb:41:in
> `request'
>
>
> Does anyone know why this could be?
This topic is locked and can not be replied to.