doanduyhai / Achilles

An advanced Java Object Mapper/Query DSL generator for Cassandra
http://achilles.archinnov.info
Apache License 2.0
241 stars 92 forks source link

Inheritance not working with Entity #369

Closed shubhampatel2105 closed 4 years ago

shubhampatel2105 commented 4 years ago

I have a usecase where the Keys are shared between entities and as a result they have been written as a separate class. I am trying to use inheritance to solve this issue. But the compilation of entities are failing with message saying

[ERROR] Error while parsing: The class 'com.datastax.demo.killrchat.entity.UserEntity' should have at least 1 partition key (@PartitionKey) even when the super class has the filed present.

For demo I tried out the killrchat app with the approach suggested in ISSUE-247

Tried moving login to a separate class and extended it in UserEntity.