Table "TOKENENTRY" not found; SQL statement:

Enter code here…
Anyone please help me.See i am very much new to Axon .I have configured my own eventstore and sagastore but i am getting below error

Table “TOKENENTRY” not found; SQL statement:
select tokenentry0_.segment as col_0_0_ from TokenEntry tokenentry0_ where tokenentry0_.processorName=? order by tokenentry0_.segment ASC [42102-199]
2019-10-29 05:39:02.728 WARN 3964 — [[projections]-0] o.a.e.TrackingEventProcessor : Fetch Segments for Processor ‘projections’ failed: org.hibernate.exception.SQLGrammarException: could not prepare statement. Preparing for retry in 8s
2019-10-29 05:39:02.728 WARN 3964 — [agaProcessor]-0] o.a.e.TrackingEventProcessor : Fetch Segments for Processor ‘projections2’ failed: org.hibernate.exception.SQLGrammarException: could not prepare statement. Preparing for retry in 8s

Can anyone provide me a complete Gitrepo link please?

`

@Configuration
public class SagaStoreConfig {

    @Bean
    @ConfigurationProperties("sagastore.datasource")
    public DataSourceProperties dataSourceEsProperties() {
        return new DataSourceProperties();
    }

    private DataSource esDataSource() {
        return dataSourceEsProperties().initializeDataSourceBuilder().build();
    }

    @Bean("sagaEntityManagerFactory")
    public LocalContainerEntityManagerFactoryBean sagaEntityManagerFactory(EntityManagerFactoryBuilder builder) {
        return builder.dataSource(esDataSource())
                .persistenceUnit("saga")
                .packages(SagaEntry.class,
                        AssociationValueEntry.class , TokenEntry.class)
                .build();
    }

    @Bean
    @Qualifier("sagaTx")
    PlatformTransactionManager platformTransactionManager(@Qualifier("sagaEntityManagerFactory") LocalContainerEntityManagerFactoryBean localContainerEntityManagerFactoryBean){
        return new JpaTransactionManager(localContainerEntityManagerFactoryBean.getObject());
    }

    @Bean("tokenStore")
    public TokenStore jpaTokenStore(@Qualifier("eventSerializer") Serializer eventSerializer , @Qualifier("sagaEntityManagerFactory")LocalContainerEntityManagerFactoryBean localContainerEntityManagerFactoryBean)  {
        return  JpaTokenStore.builder()
                .entityManagerProvider(new SimpleEntityManagerProvider(localContainerEntityManagerFactoryBean.getObject().createEntityManager()))
                .serializer(eventSerializer)
                .build();
    }

    @Bean("sagaStore")
    public JpaSagaStore jpaSagaStore(@Qualifier("eventSerializer") Serializer eventSerializer, @Qualifier("sagaEntityManagerFactory")LocalContainerEntityManagerFactoryBean localContainerEntityManagerFactoryBean){
        return JpaSagaStore.builder()
                .entityManagerProvider(new SimpleEntityManagerProvider(
                        localContainerEntityManagerFactoryBean.getObject().createEntityManager()))
                .serializer(eventSerializer)
                .build();
    }

}

If you are using Spring Boot, did you specify an @EntityScan anywhere? If so, you’ll need to add some of the Axon packages to that as well, since default entity scan rules don’t apply anymore.

If you’re not using Spring Boot, you’ll need to add the Axon Entities explicitly to your EntityManager configuration, next to your own entities.
The packages containing entities are:

  • org.axonframework.eventhandling.tokenstore
  • org.axonframework.modelling.saga.repository.jpa
  • org.axonframework.eventsourcing.eventstore.jpa
    Note that you have quite a lot of configuration. In general, we recommend using the Spring Boot Autoconfiguration. It reduces the amount of configuration (to almost 0), improving readability and reducing the chance of making configuration mistakes.

Hope this helps.

Cheers,

twitter-icon_128x128.png