ec2-provider -> FileNotfound with swift3-middleware

Bug #1154033 reported by Tino Schmeier
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
pyjuju
Triaged
Low
Unassigned

Bug Description

Hello.

The expires-variable is set to 10 years in the future. This leads to the FileNotfound-Error (RequestTimeTooSkewed) because the swift3-middleware sets the timedelta-value to 10 minutes.

2013-03-12 11:21:37,135: juju.agents.machine@ERROR: Error starting unit: wordpress/2
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/juju/agents/machine.py", line 97, in watch_service_units
    yield self.unit_deployer.start_service_unit(unit_name)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1037, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/usr/lib/python2.7/dist-packages/juju/unit/deploy.py", line 77, in start_service_unit
    bundle = yield self.download_charm(charm_state)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1037, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/usr/lib/python2.7/dist-packages/juju/unit/charm.py", line 38, in download_charm
    raise FileNotFound(charm_state.bundle_url)
FileNotFound: File was not found: 'http://.....'

juju-code juju/providers/ec2/files.py:
...
# URLs are good for 10 years.
expires = int(time.time()) + 365 * 24 * 3600 * 10
...

swift-code swift3/middleware.py:
...
delta = datetime.timedelta(seconds=60 * 10)
            if d1 - d2 > delta or d2 - d1 > delta:
                return get_err_response('RequestTimeTooSkewed')(env, start_response)
...

If i change the expires to the expected value it works. Should this value be configurable, or is this an swift3-bug/feature?

Thanks
Tino

Revision history for this message
Dave Cheney (dave-cheney) wrote :

Reassigning to the Juju project.

affects: juju-core → juju
Curtis Hovey (sinzui)
Changed in juju:
importance: Undecided → Low
status: New → Triaged
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.