We're updating the issue view to help you get more done. 

Getting SQLException when trying to load a self referential AO Entity class

Description

I'm getting this exception:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 java.sql.SQLException: Index already exists: INDEX_AO_ACTIVITY_OBJ_ENTITY_AUTHOR_ID in statement [CREATE INDEX index_ao_activity_obj_entity_author_id ON AO_ACTIVITY_OBJ_ENTITY] at org.hsqldb.jdbc.Util.sqlException(Unknown Source) at org.hsqldb.jdbc.jdbcStatement.fetchResult(Unknown Source) at org.hsqldb.jdbc.jdbcStatement.executeUpdate(Unknown Source) at net.java.ao.schema.SchemaGenerator.executeUpdate(SchemaGenerator.java:70) at net.java.ao.schema.SchemaGenerator.migrate(SchemaGenerator.java:56) at net.java.ao.EntityManager.migrate(EntityManager.java:142) at com.atlassian.streams.thirdparty.ThirdPartyStreams$ThirdPartyStreamsDatabaseUpdater.update(ThirdPartyStreams.java:43) at net.java.ao.test.junit.ActiveObjectTransactionMethodRule.updateDatabase(ActiveObjectTransactionMethodRule.java:192) at net.java.ao.test.junit.ActiveObjectTransactionMethodRule.before(ActiveObjectTransactionMethodRule.java:75) at net.java.ao.test.junit.ActiveObjectTransactionMethodRule$1.evaluate(ActiveObjectTransactionMethodRule.java:57) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:76) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184) at org.junit.runners.ParentRunner.run(ParentRunner.java:236) at org.junit.runner.JUnitCore.run(JUnitCore.java:157) at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:60)

Basically, I have an ActivityObjEntity class, that is inherited by several other class. And ActivityObjEntity class also has a self referential on itself. I have attached the Entity classes that we are using.

Environment

None

Testing Notes

None

Status

Assignee

Unassigned

Reporter

Ryan Talusan

Labels

None

Add-on Type

None

Team

None

CC

None

Risk factor

None

QA Kickoff Status

None

QA Demo Status

None

Fix versions

Priority

Blocker