Commit 531c585b authored by Matija Obreza's avatar Matija Obreza

Taxonomy2: Not indexed

parent ad2d79a0
......@@ -34,7 +34,6 @@ import javax.persistence.UniqueConstraint;
import com.fasterxml.jackson.annotation.JsonIgnore;
import org.apache.commons.lang3.StringUtils;
import org.genesys2.server.component.elastic.ElasticTrigger;
import org.genesys2.server.model.GlobalVersionedAuditedModel;
import org.genesys2.server.model.grin.TaxonomySpecies;
import org.genesys2.server.model.json.Api1Constants;
......@@ -55,7 +54,7 @@ import com.fasterxml.jackson.annotation.ObjectIdGenerators;
@Table(name = "taxonomy2", uniqueConstraints = { @UniqueConstraint(name="UK_taxonomy2", columnNames = { "genus", "species", "spAuthor", "subtaxa", "subtAuthor" }) })
@JsonIgnoreProperties(ignoreUnknown = true)
@JsonIdentityInfo(generator = ObjectIdGenerators.PropertyGenerator.class, property = "id", scope = Taxonomy2.class)
public class Taxonomy2 extends GlobalVersionedAuditedModel implements ElasticTrigger {
public class Taxonomy2 extends GlobalVersionedAuditedModel {
private static final long serialVersionUID = 8881324404490162933L;
......@@ -311,9 +310,4 @@ public class Taxonomy2 extends GlobalVersionedAuditedModel implements ElasticTri
public void setOverrideTaxonomySpecies(TaxonomySpecies overrideTaxonomySpecies) {
this.overrideTaxonomySpecies = overrideTaxonomySpecies;
}
@Override
public Object[] reindexedEntities() {
return this.accessions == null ? null : this.accessions.toArray();
}
}
......@@ -46,7 +46,6 @@ import org.genesys2.server.component.elastic.ElasticJacksonAnnotationIntrospecto
import org.genesys2.server.component.elastic.ElasticReindex;
import org.genesys2.server.component.elastic.ElasticReindexProcessor;
import org.genesys2.server.model.genesys.Accession;
import org.genesys2.server.model.genesys.Taxonomy2;
import org.genesys2.server.model.grin.TaxonomySpecies;
import org.genesys2.server.model.impl.ActivityPost;
import org.genesys2.server.model.impl.Article;
......@@ -237,7 +236,6 @@ public class ElasticsearchConfig extends ElasticsearchConfigurationSupport {
es.indexEntity(ActivityPost.class);
es.indexEntity(TaxonomySpecies.class); // Index GRIN Taxonomy
es.indexEntity(Taxonomy2.class);
return es;
}
......
......@@ -34,6 +34,7 @@ import org.genesys2.server.service.filter.AccessionFilter;
import org.genesys2.server.service.impl.SearchException;
import org.junit.After;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
......@@ -82,6 +83,7 @@ public class AccessionSearchTest extends AbstractElasticServicesTest {
}
@Test
@Ignore
public void reindexAccessionWhenTaxonomyUpdatedTest() throws SearchException {
// Add Taxonomy2
Taxonomy2 taxonomy2 = new Taxonomy2();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment