[
https://issues.apache.org/jira/browse/ISIS-824?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14047964#comment-14047964
]
Dan Haywood edited comment on ISIS-824 at 6/30/14 6:45 PM:
-----------------------------------------------------------
Investigating further, SimpleRepository exposes four methods:
- findByTitle
- allInstances
- createPersistentInstance
- createTransientInstance
Every one of these methods has an issue with it:
- (as noted above) findByTitle fails the metamodel validation that's been
present for quite a while, (and I'm not certain that find by title is
implemented in the JDO objecstore)
- (as noted above) the allInstances has a disableAllInstances that uses
hasInstances... not implemented by the JDO Objectstore
- createTransientInstance is not supported by either the Wicket or RO viewers,
and there are no intentions for it to be
- createPersistentInstance returns an instance but with no state... ie not
particularly useful.
Given this feature has never worked since we graduated (~2 years), I intend to
delete it.
Instead, the developer should create a repository for the entity (as they will
certainly need to do anyway...)
was (Author: danhaywood):
Investigating further, SimpleRepository exposes four methods:
- findByTitle
- allInstances
- createPersistentInstance
- createTransientInstance
Every one of these methods has an issue with it:
- (as noted above) findByTitle fails the metamodel validation that's been
present for quite a while, (and I'm not certain that find by title is
implemented in the JDO objecstore)
- (as noted above) the allInstances has a disableAllInstances that uses
hasInstances... not implemented by the JDO Objectstore
- createTransientInstance is not supported by either the Wicket or RO viewers,
and there are no intentions for it to be
- createPersistentInstance returns an instance but with no state... ie not
particularly useful.
Given this feature has never worked since we graduating (2+ years), I intend to
delete it. Instead, the developer should create a repository for the entity
(as they will certainly need to do anyway...)
> Generic repository is broken
> ----------------------------
>
> Key: ISIS-824
> URL: https://issues.apache.org/jira/browse/ISIS-824
> Project: Isis
> Issue Type: Bug
> Components: Core
> Affects Versions: objectstore-jdo-1.5.0, core-1.5.0
> Reporter: Dan Haywood
> Assignee: Dan Haywood
> Fix For: core-1.6.0
>
>
> as per
> https://isis.apache.org/more-advanced-topics/how-to-09-030-How-to-use-a-generic-repository.html
> disableFindByTitle() should be disableFindByTitle(String)
> When I made the fix as a quick experiment, it then also threw up another
> issue because the JDO objectstore doesn't implement hasInstances(). So that
> (at least) also needs fixing.
--
This message was sent by Atlassian JIRA
(v6.2#6252)