java.lang.NoSuchMethodError

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • {code} java.lang.NoSuchMethodError: org.springframework.data.cassandra.mapping.CassandraPersistentProperty.getActualType()Ljava/lang/Class; at org.springframework.data.cassandra.core.CassandraTemplate$1.doWithPersistentProperty(CassandraTemplate.java:307) at org.springframework.data.cassandra.core.CassandraTemplate$1.doWithPersistentProperty(CassandraTemplate.java:302) at org.springframework.data.mapping.model.BasicPersistentEntity.doWithProperties(BasicPersistentEntity.java:240) at org.springframework.data.cassandra.core.CassandraTemplate.appendIdCriteria(CassandraTemplate.java:302) at org.springframework.data.cassandra.core.CassandraTemplate.appendIdCriteria(CassandraTemplate.java:321) at org.springframework.data.cassandra.core.CassandraTemplate.selectOneById(CassandraTemplate.java:282) at org.springframework.data.cassandra.repository.support.SimpleCassandraRepository.findOne(SimpleCassandraRepository.java:69) {code} Here is my code that causes the stacktrace above: Service Unit Test: {code} DateTime date = new DateTime(DateTimeZone.UTC).withDayOfMonth(24).withHourOfDay(19).withMinuteOfHour(1) .withSecondOfMinute(0).withMillisOfSecond(0); FooKey key = new FooKey(UUID.fromString("f73f4a00-9d88-11e3-be4b-009c02935f8e"), "2014", date.toDate()); Foo data = service.selectById(key); Assert.assertNotNull(data); {code} The service code: {code} @Service public class FooServiceImpl implements IFooService { @Autowired private IFooRepository repository; @Override public Foo save(final Foo entity) { return repository.save(entity); } @Override public void delete(final Foo entity) { repository.delete(entity); } @Override public Foo selectById(final FooKey id) { return repository.findOne(id); } } {code} Repository: {code} @Repository public interface IFooRepository extends CassandraRepository<Foo, FooKey> { } {code} I checked the source code in GitHub and it is missing that method. Edit: I would like to mention that this error happens on trying to find one entity or trying to delete an entity.
    via by Colin McQueen,
  • {code} java.lang.NoSuchMethodError: org.springframework.data.cassandra.mapping.CassandraPersistentProperty.getActualType()Ljava/lang/Class; at org.springframework.data.cassandra.core.CassandraTemplate$1.doWithPersistentProperty(CassandraTemplate.java:307) at org.springframework.data.cassandra.core.CassandraTemplate$1.doWithPersistentProperty(CassandraTemplate.java:302) at org.springframework.data.mapping.model.BasicPersistentEntity.doWithProperties(BasicPersistentEntity.java:240) at org.springframework.data.cassandra.core.CassandraTemplate.appendIdCriteria(CassandraTemplate.java:302) at org.springframework.data.cassandra.core.CassandraTemplate.appendIdCriteria(CassandraTemplate.java:321) at org.springframework.data.cassandra.core.CassandraTemplate.selectOneById(CassandraTemplate.java:282) at org.springframework.data.cassandra.repository.support.SimpleCassandraRepository.findOne(SimpleCassandraRepository.java:69) {code} Here is my code that causes the stacktrace above: Service Unit Test: {code} DateTime date = new DateTime(DateTimeZone.UTC).withDayOfMonth(24).withHourOfDay(19).withMinuteOfHour(1) .withSecondOfMinute(0).withMillisOfSecond(0); FooKey key = new FooKey(UUID.fromString("f73f4a00-9d88-11e3-be4b-009c02935f8e"), "2014", date.toDate()); Foo data = service.selectById(key); Assert.assertNotNull(data); {code} The service code: {code} @Service public class FooServiceImpl implements IFooService { @Autowired private IFooRepository repository; @Override public Foo save(final Foo entity) { return repository.save(entity); } @Override public void delete(final Foo entity) { repository.delete(entity); } @Override public Foo selectById(final FooKey id) { return repository.findOne(id); } } {code} Repository: {code} @Repository public interface IFooRepository extends CassandraRepository<Foo, FooKey> { } {code} I checked the source code in GitHub and it is missing that method. Edit: I would like to mention that this error happens on trying to find one entity or trying to delete an entity.
    via by Colin McQueen,
    • java.lang.NoSuchMethodError: org.springframework.data.cassandra.mapping.CassandraPersistentProperty.getActualType()Ljava/lang/Class; at org.springframework.data.cassandra.core.CassandraTemplate$1.doWithPersistentProperty(CassandraTemplate.java:307) at org.springframework.data.cassandra.core.CassandraTemplate$1.doWithPersistentProperty(CassandraTemplate.java:302) at org.springframework.data.mapping.model.BasicPersistentEntity.doWithProperties(BasicPersistentEntity.java:240) at org.springframework.data.cassandra.core.CassandraTemplate.appendIdCriteria(CassandraTemplate.java:302) at org.springframework.data.cassandra.core.CassandraTemplate.appendIdCriteria(CassandraTemplate.java:321) at org.springframework.data.cassandra.core.CassandraTemplate.selectOneById(CassandraTemplate.java:282) at org.springframework.data.cassandra.repository.support.SimpleCassandraRepository.findOne(SimpleCassandraRepository.java:69)
    No Bugmate found.