[
http://jira.magnolia-cms.com/browse/MAGNOLIA-3346?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Daniel Lipp updated MAGNOLIA-3346:
----------------------------------
Summary: Change Content2BeanTransformerImpl#setProperty for better fail
safety (was: Change call flow of Content2BeanTransformerImpl#setProperty for
better fail safety )
Description:
Current implementation can produce misleading logs/exceptions in case you have
an error in the adder-method: right now we'll call the setter on any exception
of the call of the adder. If there was an exception in the adder, nothing is
put out but we try to call the setter with the same params. This will most
likely fail and you'll get this in the logs. So logs tell there's been a
problem with the setter but actually the adder is the culprit.
That's why the setter should only be called in case the adder does not exist.
In case there is an adder and calling it throws an exception, we should
properly output this exception and not try to call the setter at all.
was:
Current implementation can produce misleading logs/exceptions in case you have
an error in the adder-method: right now we'll call the setter on any exception
of the call of the adder.
Actually the setter should only be called in case the adder does not exist. In
case there is an adder and calling it throws an exception, we should properly
output this exception and not try to call the setter at all.
> Change Content2BeanTransformerImpl#setProperty for better fail safety
> ----------------------------------------------------------------------
>
> Key: MAGNOLIA-3346
> URL: http://jira.magnolia-cms.com/browse/MAGNOLIA-3346
> Project: Magnolia
> Issue Type: Improvement
> Components: core
> Affects Versions: 4.3.8
> Reporter: Daniel Lipp
> Assignee: Philipp Bärfuss
> Priority: Minor
>
> Current implementation can produce misleading logs/exceptions in case you
> have an error in the adder-method: right now we'll call the setter on any
> exception of the call of the adder. If there was an exception in the adder,
> nothing is put out but we try to call the setter with the same params. This
> will most likely fail and you'll get this in the logs. So logs tell there's
> been a problem with the setter but actually the adder is the culprit.
> That's why the setter should only be called in case the adder does not exist.
> In case there is an adder and calling it throws an exception, we should
> properly output this exception and not try to call the setter at all.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.magnolia-cms.com/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------