title: Spring Data Cassandra Reactive - "MappingException Couldn't find PersistentEntity for type class java.lang.Object"
body: <p>I am using spring-boot-starter-data-cassandra-reactive v2.0.0.M7 to interact with Cassandra using ReactiveApis. </p>
  
  <p>I have create Entity, Primarykey and Repository class. When I run the code, I run into below exception. I have been trying to fix this issue since last few hours without any success. Let me know if you need more info.</p>
  
  <pre><code>Caused by: org.springframework.data.mapping.MappingException: Couldn't find PersistentEntity for type class java.lang.Object!
      at org.springframework.data.mapping.context.MappingContext.getRequiredPersistentEntity(MappingContext.java:76) ~[spring-data-commons-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.cassandra.repository.support.ReactiveCassandraRepositoryFactory.getEntityInformation(ReactiveCassandraRepositoryFactory.java:103) ~[spring-data-cassandra-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.cassandra.repository.support.ReactiveCassandraRepositoryFactory.getTargetRepository(ReactiveCassandraRepositoryFactory.java:83) ~[spring-data-cassandra-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.repository.core.support.RepositoryFactorySupport.getRepository(RepositoryFactorySupport.java:300) ~[spring-data-commons-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.repository.core.support.RepositoryFactoryBeanSupport.lambda$afterPropertiesSet$3(RepositoryFactoryBeanSupport.java:287) ~[spring-data-commons-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.util.Lazy.getNullable(Lazy.java:141) ~[spring-data-commons-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.util.Lazy.get(Lazy.java:63) ~[spring-data-commons-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.repository.core.support.RepositoryFactoryBeanSupport.afterPropertiesSet(RepositoryFactoryBeanSupport.java:290) ~[spring-data-commons-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.data.cassandra.repository.support.ReactiveCassandraRepositoryFactoryBean.afterPropertiesSet(ReactiveCassandraRepositoryFactoryBean.java:99) ~[spring-data-cassandra-2.0.2.RELEASE.jar:2.0.2.RELEASE]
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1769) ~[spring-beans-5.0.2.RELEASE.jar:5.0.2.RELEASE]
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1706) ~[spring-beans-5.0.2.RELEASE.jar:5.0.2.RELEASE]
      ... 20 common frames omitted
  </code></pre>
  
  <p><strong>Relevant Code Snippet</strong></p>
  
  <pre><code>@Table(name = "scan")
  @Getter @Setter @NoArgsConstructor @ToString
  public class CScan {
  
      @PrimaryKey
      private CScanPrimaryKey toolSourceIdKey;
  
      @Column(name = "is_completed") 
      private String isCompleted;
  
      @Column(name = "update_date") 
      private LocalDateTime updateDate;
  
      @Column(name = "certification") 
      private String certification;
  
      @Column(name = "audit_updated") 
      private String auditUpdated;
  
      @Column(name = "sca_label") 
      private String scaLabel;
  
      @Column(name = "sca_buildId") 
      private String scaBuildId;
  
      @Column(name = "host_name") 
      private String hostName;
  
      @Column(name = "start_date") 
      private LocalDateTime startDate;
  
      @Column(name = "elapsed_time") 
      private int elapsedTime;
  
      @Column(name = "has_issue") 
      private String hasIssue;
  
      @Column(name = "updated") 
      private String updated;
  
      @Column(name = "sca_files") 
      private int scaFiles;
  
      @Column(name = "executable_loc") 
      private int executableLoc;
  
      @Column(name = "total_loc") 
      private int totalLoc;
  
      @Column(name = "engine_type") 
      private String engineType;
  
      @Column(name = "engine_version") 
      private String engineVersion;
  
      @Column(name = "guid") 
      private String guid;
  
      @Column(name = "project_label") 
      private String projectLabel;
  
      @Column(name = "version_label") 
      private String versionLabel;
  
      @Column(name = "proj_ver_id")
      private int projVerId;
  
      @Column(name = "proj_ver_name")
      private String projVerName;
  
      @Column(name = "proj_id")
      private int projId;
  
      @Column(name = "proj_name")
      private String projName;
  
      @Column(name = "artifact_id") 
      private int artifact_id;
  
      @Column(name = "object_version") 
      private int objectVersion;
  
      @Column(name = "migrated") 
      private String migrated;
  
      @Column(name = "server_version") 
      private Float serverVersion;
  
      @Column(name = "entry_name") 
      private String entryName;
  
  
      @Column(name = "fortify_annotations_loc") 
      private String fortifyAnnotationsLoc;
  
      @Column(name = "data_version") 
      private String dataVersion; 
  
  }
  
  
  
  @PrimaryKeyClass
  @Getter @Setter @NoArgsConstructor @ToString @EqualsAndHashCode(exclude={})
  public class CScanPrimaryKey implements Serializable {
  
      /**
       * 
       */
      private static final long serialVersionUID = 5703460462572087535L;
  
      @PrimaryKeyColumn(name = "tool_source_id", type = PrimaryKeyType.PARTITIONED)         
      private UUID toolSourceId;
  
      @PrimaryKeyColumn(name = "id", ordering = Ordering.ASCENDING)
      private int id; 
  
      @PrimaryKeyColumn(name = "upload_status", ordering = Ordering.ASCENDING)
      private String uploadStatus;    
  
  
  }
  
  
  @Repository
  public interface ReactiveScanRepository&lt;CScan&gt; extends ReactiveCassandraRepository&lt;CScan, CScanPrimaryKey&gt; {
  
  }
  </code></pre>