Remove data persistence layer since #1279018 is fixed
Bug #1615115 reported by
Andreas Hasenack
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
block-storage-broker (Juju Charms Collection) |
New
|
Undecided
|
Unassigned |
Bug Description
Bug #1279018 has been fixed for a long time. Looks like we can remove the persistence layer we added as a workaround:
# XXX We can remove _persist_data when juju bug:1279018 is fixed to provide
# relation-data from *-relation-departed hook runs
def _persist_data(key, value):
"""Save C{key} and C{value} pairs in a persistent file for reference"""
data = {}
filepath = "%s/%s" % (hookenv.
if os.path.
with open(filepath) as inputfile:
data = json.load(
data[key] = value
with open(filepath, "w") as outfile:
To post a comment you must log in.