[
http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-977?pag...
]
Hardy Ferentschik updated HSEARCH-977:
--------------------------------------
Description:
MassIndexer hangs (and the reason was quite difficult to figure out from logs...) when I
have the following
(I simplified the actual class/interface hierarchy in this example; this should not matter
I believe...):
{code}
// PK sits in a super class
@Entity
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
@DiscriminatorColumn(length=40)
@org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
public abstract class MyElementImpl implements MyElement {
// ...
@Id
@DocumentId
public String getRDFId()
{
return uri;
}
//etc...
}
// in an entity sub-class I have a property/column 'id' -
@Entity
@org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
public class XrefImpl extends MyElementImpl implements Xref
{
//...
@Field(name="id", index=Index.TOKENIZED)
@Column(name="id")
public String getId()
{
return refId;
}
public void setId(String id)
{
this.refId = id;
}
// etc...
{code}
This seems to be Hibernate Search framework issue. This may be also an issue for other
Hibernate Search versions, but I do not remember which I have tried (I haven't tried
the latest yet).
- though I found a workaround/fix that works for me (using another setter/getter and index
field name):
{code}
// in the sub-class -
@Field(name="xrefId", index=Index.TOKENIZED)
@Column(name="id")
public String getIdx()
{
return refId;
}
public void setIdx(String id)
{
this.refId = id;
}
// make the actual interface method implementation transient
@Transient
public String getId()
...
{code}
Thank you.
was:
MassIndexer hangs (and the reason was quite difficult to figure out from logs...) when I
have the following
(I simplified the actual class/interface hierarchy in this example; this should not matter
I believe...):
// PK sits in a super class
@Entity
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
@DiscriminatorColumn(length=40)
@org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
public abstract class MyElementImpl implements MyElement {
// ...
@Id
@DocumentId
public String getRDFId()
{
return uri;
}
//etc...
}
// in an entity sub-class I have a property/column 'id' -
@Entity
@org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
public class XrefImpl extends MyElementImpl implements Xref
{
//...
@Field(name="id", index=Index.TOKENIZED)
@Column(name="id")
public String getId()
{
return refId;
}
public void setId(String id)
{
this.refId = id;
}
// etc...
This seems to be Hibernate Search framework issue. This may be also an issue for other
Hibernate Search versions, but I do not remember which I have tried (I haven't tried
the latest yet).
- though I found a workaround/fix that works for me (using another setter/getter and index
field name):
// in the sub-class -
@Field(name="xrefId", index=Index.TOKENIZED)
@Column(name="id")
public String getIdx()
{
return refId;
}
public void setIdx(String id)
{
this.refId = id;
}
// make the actual interface method implementation transient
@Transient
public String getId()
...
Thank you.
MassIndexer freezes when there is an indexed 'id' filed,
which is not document's id
-----------------------------------------------------------------------------------
Key: HSEARCH-977
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-977
Project: Hibernate Search
Issue Type: Bug
Components: massindexer
Affects Versions: 3.4.0.Final
Environment: Mac, Linux, MySQL 5.1.x; Java 1.6, Hibernate 3.6.3.Final,
hibernate-jpa-2.0-api 1.0.0.Final (entity annotations), Spring 3.0.5.RELEASE
Reporter: Igor
Labels: hibernate, search
MassIndexer hangs (and the reason was quite difficult to figure out from logs...) when I
have the following
(I simplified the actual class/interface hierarchy in this example; this should not
matter I believe...):
{code}
// PK sits in a super class
@Entity
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
@DiscriminatorColumn(length=40)
@org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
public abstract class MyElementImpl implements MyElement {
// ...
@Id
@DocumentId
public String getRDFId()
{
return uri;
}
//etc...
}
// in an entity sub-class I have a property/column 'id' -
@Entity
@org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
public class XrefImpl extends MyElementImpl implements Xref
{
//...
@Field(name="id", index=Index.TOKENIZED)
@Column(name="id")
public String getId()
{
return refId;
}
public void setId(String id)
{
this.refId = id;
}
// etc...
{code}
This seems to be Hibernate Search framework issue. This may be also an issue for other
Hibernate Search versions, but I do not remember which I have tried (I haven't tried
the latest yet).
- though I found a workaround/fix that works for me (using another setter/getter and
index field name):
{code}
// in the sub-class -
@Field(name="xrefId", index=Index.TOKENIZED)
@Column(name="id")
public String getIdx()
{
return refId;
}
public void setIdx(String id)
{
this.refId = id;
}
// make the actual interface method implementation transient
@Transient
public String getId()
...
{code}
Thank you.
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira