0d97c29882
Basic filtering is available via Resource._filter_fields and
Resource._children but partial filtering of fields is not supported.
This change allows a Resource to define custom sanitization methods
for individual fields. The specified method is applied after the
field has been generated.
For nested structures, particularly when elements are not Resource
types, it is easier to scan the field after generation and remove
specific elements than it is to modify the recursive descent already
implemented in to_wrapped_dict().
JobExecutions are filtered with this mechanism to set swift credential
values to empty strings and to remove the 'conf' section reported
for running Oozie actions.
Closes-Bug: #1300291
Change-Id: Ifb0b99a3e13d40306139b0d0021aead69e870205
(cherry picked from commit
|
||
---|---|---|
.. | ||
__init__.py | ||
api.py | ||
manager.py | ||
objects.py | ||
resource.py |