fix: bugs 535 and 539 only find storage for application being read #557
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
FullStatus was called without a filter. The storage returned in the structure was assumed to be for the application being read. In reality it was for all application's in the model. Unfortunately piecing which storage is for which application is non-trivial as the data is embedded deep in the structure on a unit level.
Instead call FullStatus with a filter of the application name when Reading, this ensures that the returned storage is for the current application only.
Updated an application acceptance test to ensure storage isn't written for applications without storage.
Fixes: #535, #539, #550
Type of change
QA steps
Additional notes
JUJU-6599