[Hibernate-JIRA] Created: (HSEARCH-642) Support for only manual indexing of particular entity types
by Kyrill Alyoshin (JIRA)
Support for only manual indexing of particular entity types
-----------------------------------------------------------
Key: HSEARCH-642
URL: http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-642
Project: Hibernate Search
Issue Type: Improvement
Components: engine
Affects Versions: 3.2.1
Reporter: Kyrill Alyoshin
I have an interesting use case. Basically I have to find internal duplicates (in full text search terms) among a bunch of entities of a particular type. The most elegant way to do it, would be:
1. Not to index those entities when they are saved (the problem is that only a minority of entities need to be de-duped).
2. Before de-duping process starts, manually index those particular entities.
3. De-dupe them using Lucene's capabilities.
4. Purge those entities from the index.
Is it possible to mark a particular entity to be indexed only manually?
hibernate.search.indexing_strategy = manual
seems to be a global configuration. Can it be applied somehow on a per entity basis? If not, I think this is a valuable RFE.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[Hibernate-JIRA] Created: (HHH-5874) Use of referencedColumnName in @JoinColumns produce error, without this execute correctly
by Sento Niñerola Molina (JIRA)
Use of referencedColumnName in @JoinColumns produce error, without this execute correctly
-----------------------------------------------------------------------------------------
Key: HHH-5874
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5874
Project: Hibernate Core
Issue Type: Bug
Components: annotations, core, query-sql
Environment: Hibernate version shipped with JBoss 5.0.1 GA (3.5 Final?), PostgreSQL 9.0 64 bits, Java 6 64 bits, Windows 7 64 bits
Reporter: Sento Niñerola Molina
Hello everyone:
I'm having a very strange error when using Hibernate JPA shipped in the JBoss AS 5.0.1.
When I put @ManyToOne relationship, with several @JoinColumn within a @JoinColumns (since I have FK to entities with composite PK) and set the parameter "referencedColumnName" an exception occurs: org.hibernate.AnnotationException: Column name DDPROV_ID of test.DdProvincia not found in JoinColumns.referencedColumnName, where DDPROV_ID is one of the columns that forms the PK of the table DDPROVINCIAS.
The strange thing is that if I remove the parameter "referencedColumnName", everything works fine. How is this possible? Moreover, the JPA standard indicates that this attribute is mandatory in a @JoinColumn when exists more than two inside @JoinColumns.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[Hibernate-JIRA] Created: (HHH-5871) Problem locking an proxy to session when an detached proxy is already on its persistence context
by pedro santos (JIRA)
Problem locking an proxy to session when an detached proxy is already on its persistence context
------------------------------------------------------------------------------------------------
Key: HHH-5871
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5871
Project: Hibernate Core
Issue Type: Bug
Affects Versions: 3.6.0
Environment: web app over tomcat using hibernate version 3.5.6-Final and spring.version 3.0.5.RELEASE with SpringWebApplicationFactory configured as an filter on web.xml
Reporter: pedro santos
Attachments: stackTrace.txt, test-fix.patch
Problem locking an proxy to session when an detached proxy is already on its persistence context
The call: session.lock(proxy, LockMode.NONE) is throwing:
org.hibernate.TransientObjectException: Proxy is detached (i.e, session is null). The read-only/modifiable setting is only accessible when the proxy is associated with an open session.
The problem is that I'm not able to lock an proxy on session due an old detached proxy already add on its persistence context. I'm sending an test case demonstrating the bug, plus the fix on TwoPhaseLoad to don't test lazyInitializer ready only property when it is not available.
What is weird on all this problem is: how did an detached proxy get in another opened session? I'm simulating it on the test case, but my application code don't even look like it. I created the test case only by analyzing the exception stack trace. This problem is happening time to time and crash the production app.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[Hibernate-JIRA] Commented: (HHH-1395) Hierarchical entity data management using 'modified preorder tree traversal algorithm' (nested set trees)
by Josh Joy (JIRA)
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1395?page=c... ]
Josh Joy commented on HHH-1395:
-------------------------------
Regarding the previousparent, when the update listener is executed nsthread id is part of the query. For some reason when the setPreviousParent(final NestedSetNode<BusinessHierarchyTree> parent) is invoked not all of the properties are set. Thus the nsthread always is 0.
To resolve this is how I implemented the method.
if (parent != null) {
final BusinessHierarchyTree node = new BusinessHierarchyTree();
BeanUtils.copyProperties(parent, node);
node.setNsThread(this.getNsThread());
this.previousParent = node;
}
> Hierarchical entity data management using 'modified preorder tree traversal algorithm' (nested set trees)
> ----------------------------------------------------------------------------------------------------------
>
> Key: HHH-1395
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1395
> Project: Hibernate Core
> Issue Type: New Feature
> Components: core, query-hql
> Environment: Hibernate 3.1 plus Annotations extending EJB3 implementation
> Reporter: James Salt
> Attachments: nestedset.tar.gz, utils-parent-20091117.tar.gz
>
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> An enhancement to allow entities to exist in a managed tree (DAG) structure, via the use of property annotations and entity annotations. With an extension to the HQL language to mimic the Oracle recusive query clause.
> This would be classically be useful for Bill of Material uses, or any tree like entity structure.
> I have implemented a homebrew approach using the 'adjacency list method' , and a post persist call back method to set the node path. Although I think a more full blown optimised algorithm would be the 'modified preorder tree traversal algorithm'.
> In the annotations world this could be implemented using an annotation like @Hierarchical to the entity, with a @Parent (mask for @ManyToOne) annotation on the parent field/parameter and @Children (mask for @OneToMany) annotation on the list of children entities.
> Then a postupdate method could be implemented for the entity type, that recalculates the tree meta data -i.e. parent, left and right.
> I believe this would be a valuable extension (useful for many common data models) to the hibernate core product that could be exposed through annotations as I have discussed and the hbm.xml.
> The users of such a system would be aware of the performance implications on insert/update/delete, but gain a massive performance gain on querying a tree data model.
>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[Hibernate-JIRA] Created: (HHH-3872) Criteria on alias causes partial collection materialization
by Adrian Moos (JIRA)
Criteria on alias causes partial collection materialization
-----------------------------------------------------------
Key: HHH-3872
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-3872
Project: Hibernate Core
Issue Type: Bug
Components: query-criteria
Affects Versions: 3.3.0.CR1
Reporter: Adrian Moos
I have a parent entity with a one-to-many assocation to a child entity:
<hibernate-mapping package="ch.bedag.a11.ccinfo.business.entity" default-lazy="false">
<class name="Parent" table="PARENT">
<id name="id" type="long" column="ID" unsaved-value="null">
<generator class="sequence">
<param name="sequence">SEQ_T_PARENT</param>
</generator>
</id>
<set name="children" cascade="all-delete-orphan" inverse="true">
<key column="PARENT_ID" foreign-key="CHILD_FK1"/>
<one-to-many class="Child"/>
</set>
</class>
<class name="Child"
<id name="id" type="long" column="ID" unsaved-value="null">
<generator class="sequence">
<param name="sequence">SEQ_T_CHILD</param>
</generator>
</id>
<property name="businessKey" column="BUSINESSKEY" not-null="true"/>
</class>
</hibernate-mapping>
I then do:
Criteria parentCriteria = aSession.createCriteria(Parent.class);
parentCriteria.createAlias("children", "c", CriteriaSpecification.LEFT_JOIN);
parentCriteria.setResultTransformer(CriteriaSpecification.DISTINCT_ROOT_ENTITY);
parentCriteria.add(Restrictions.eq("c.businessKey", 123456789));
List parents = parentCriteria.list();
Expected behaviour: Since each parent in parents is a materialized entity, I'd expect its children set to contain all its children.
Observed behaviour: It contains only children with matching business key.
Is my expectation correct?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[Hibernate-JIRA] Created: (HBX-1174) Hibernate XML Mapping file wizard does not generate files when project is located outside the Eclipse workspace
by Bernd Winter (JIRA)
Hibernate XML Mapping file wizard does not generate files when project is located outside the Eclipse workspace
---------------------------------------------------------------------------------------------------------------
Key: HBX-1174
URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-1174
Project: Hibernate Tools
Issue Type: Bug
Components: eclipse
Environment: Hibernate Tools for Eclipse 3.3.0.v20101206-2100-H28-Beta2
Eclipse 3.6.1.r361_v20100909
Win XP Pro SP3
Reporter: Bernd Winter
Attachments: exWS_0.PNG, exWS_2.PNG, feature.PNG, inWS_0.PNG, inWS_2.PNG, result.PNG
I was adding Hibernate support to a project and tried to use Hibernate Tools for the first time. Using the wizard for the Hibernate Configuration File worked fine. Then I wanted to use the wizard for adding mapping files (feature.PNG). Stepping through the wizard was fine, without any warning or error messages. However, after pressing the Finish button at the end... nothing changed. No file was generated anywhere.
When trying to analyze what was going wrong I noticed suspicious path information in some screens of the wizard (see exWS_2.PNG). I had similar problems when working with another project on Windows 7 (don't know whether the OS has any influence here...): I remember the path looking even more corrupted back then, a relative path going back a few directories; but taking the depth levels into account, the starting point would have been an incorrect directory.
So I had the idea that it might have something to do with the configured Eclipse default workspace. Maybe it's used as a basis for referencing the directories in an incorrect way. To cut a long story short: When creating the exact same project inside the currently used Eclipse workspace, everything works fine.
The default Eclipse workspace is: C:\CVS\workspace
See the project path and wirzard screen of the successful project: inWS_0.PNG, inWS_2.PNG
and the failed project: exWS_0.PNG, exWS_2.PNG
and the result after conducting the same experiment with both projects: result.PNG
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[Hibernate-JIRA] Commented: (HHH-1395) Hierarchical entity data management using 'modified preorder tree traversal algorithm' (nested set trees)
by Hajo Kliemeck (JIRA)
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1395?page=c... ]
Hajo Kliemeck commented on HHH-1395:
------------------------------------
is there any progress on this issue?
> Hierarchical entity data management using 'modified preorder tree traversal algorithm' (nested set trees)
> ----------------------------------------------------------------------------------------------------------
>
> Key: HHH-1395
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1395
> Project: Hibernate Core
> Issue Type: New Feature
> Components: core, query-hql
> Environment: Hibernate 3.1 plus Annotations extending EJB3 implementation
> Reporter: James Salt
> Attachments: nestedset.tar.gz, utils-parent-20091117.tar.gz
>
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> An enhancement to allow entities to exist in a managed tree (DAG) structure, via the use of property annotations and entity annotations. With an extension to the HQL language to mimic the Oracle recusive query clause.
> This would be classically be useful for Bill of Material uses, or any tree like entity structure.
> I have implemented a homebrew approach using the 'adjacency list method' , and a post persist call back method to set the node path. Although I think a more full blown optimised algorithm would be the 'modified preorder tree traversal algorithm'.
> In the annotations world this could be implemented using an annotation like @Hierarchical to the entity, with a @Parent (mask for @ManyToOne) annotation on the parent field/parameter and @Children (mask for @OneToMany) annotation on the list of children entities.
> Then a postupdate method could be implemented for the entity type, that recalculates the tree meta data -i.e. parent, left and right.
> I believe this would be a valuable extension (useful for many common data models) to the hibernate core product that could be exposed through annotations as I have discussed and the hbm.xml.
> The users of such a system would be aware of the performance implications on insert/update/delete, but gain a massive performance gain on querying a tree data model.
>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months