You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@isis.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2018/02/14 00:12:02 UTC
[jira] [Commented] (ISIS-1860) CommandReification.DISABLED is
broken / incorrectly documented.
[ https://issues.apache.org/jira/browse/ISIS-1860?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16363263#comment-16363263 ]
ASF subversion and git services commented on ISIS-1860:
-------------------------------------------------------
Commit 392d475ac421ace05b18128f10cb2dea543aeba0 in isis's branch refs/heads/maint-1.16.1 from [~danhaywood]
[ https://gitbox.apache.org/repos/asf?p=isis.git;h=392d475 ]
ISIS-1860: improves docs regarding CommandReification
> CommandReification.DISABLED is broken / incorrectly documented.
> ---------------------------------------------------------------
>
> Key: ISIS-1860
> URL: https://issues.apache.org/jira/browse/ISIS-1860
> Project: Isis
> Issue Type: Documentation
> Affects Versions: 1.16.0
> Reporter: Dan Haywood
> Assignee: Dan Haywood
> Priority: Major
> Fix For: 1.16.1
>
>
> Don't intend to change the implementation, but what I observe is that setting commandReification=DISABLED does not necessarily prevent a command from being persisted. All it does is prevent a CommandFacet from being installed on the corresponding action or property in the metamodel.
> A Command object is always created by CommandContext. If there is a CommandService implementation, then it delegates to that to act as the factory of the Command. So reification always occurs.
> If an action invocation or property edit causes objects to be modified, then the Command#setPersistHint(...) is set to true. And, if there is no command facet, then the CommandServiceJdo will default the Command#setPersistence(...) to PERSIST_IF_HINTED.
> The net result is that if commandReification is DISABLED, then commands are still persisted if they cause any objects to be dirtied.
> To prevent commands being persisted, instead use @Action(commandPersistence=NOT_PERSISTED), and make sure that @Action(command=ENABLED).
>
> object is updated with a persist hint. In the case of the incode platform's Command module, the CommandService#complete(Command) is called, its implementation will
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)