Changes in update_and_save not always committed
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Heat |
Fix Released
|
High
|
Zane Bitter |
Bug Description
This needs looking into by someone with more sqlalchemy knowledge than me, but in db/sqlalchemy/
One such case seems to be (and this affects code after Zane's commits to save the template during a stack-update) during a stack-update that adds a SoftwareDeployment; calls are made to store the template, and the code executes, but the changes are not made visible in the database.
Adding session.merge(self) just before the call to commit (line 79 in db/sqlalchemy/
I will submit a patch for this tomorrow; if there any pitfalls please let me know.
Changed in heat: | |
milestone: | none → juno-2 |
Changed in heat: | |
status: | Fix Committed → Fix Released |
Changed in heat: | |
milestone: | juno-2 → 2014.2 |
Thanks to great analysis by Steve, we were able to track down the problem to the fact that template updates are being stored without passing a context, which contains the shared DB session. If we use the shared DB session, no merging should be required. Working on a fix now.