Sha256: f0133ec9d039e4c52f07c4837d9bb9037452be688cfbff43e86258bbd8bd9cdc

Contents?: true

Size: 496 Bytes

Versions: 20

Compression:

Stored size: 496 Bytes

Contents

module Fog
  module AWS
    class Storage
      class Real

        # Sync clock against S3 to avoid skew errors
        #
        def sync_clock
          response = begin
            get_service
          rescue => error
            error.response
          end
          Fog::Time.now = Time.parse(response.headers['Date'])
        end

      end # Real

      class Mock # :nodoc:all

        def sync_clock
          true
        end

      end # Mock
    end # Storage
  end # AWS
end # Fog

Version data entries

20 entries across 20 versions & 2 rubygems

Version Path
fog-0.8.2 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.8.1 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.8.0 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.7.2 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.7.1 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.7.0 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.6.0 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.5.3 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.5.2 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.5.1 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.5.0 lib/fog/storage/requests/aws/sync_clock.rb
phpfog-fog-0.4.1.3 lib/fog/storage/requests/aws/sync_clock.rb
phpfog-fog-0.4.1.2 lib/fog/storage/requests/aws/sync_clock.rb
phpfog-fog-0.4.1.1 lib/fog/storage/requests/aws/sync_clock.rb
phpfog-fog-0.4.1 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.4.1 lib/fog/storage/requests/aws/sync_clock.rb
fog-0.4.0 lib/fog/aws/requests/storage/sync_clock.rb
fog-0.3.34 lib/fog/aws/requests/storage/sync_clock.rb
fog-0.3.33 lib/fog/aws/requests/storage/sync_clock.rb
fog-0.3.32 lib/fog/aws/requests/storage/sync_clock.rb