I have a brand new download of broadleaf-commerce source code. It allows me to run mvn clean install
and I am able to run mvn spring:boot run
in admin
. However, when I run mvn package
in the root folder. I see different jar file
and I run java -jar admin/target/admin.jar
with exception
onContext. To display the conditions report re-run your application with 'debug' enabled.
2020-10-07 23:54:33.045 ERROR 4853 --- [ main] o.s.boot.SpringApplication : Application run failed
org.hibernate.exception.SQLGrammarException: could not extract ResultSet
at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:63) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.extract(ResultSetReturnImpl.java:69) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.Loader.getResultSet(Loader.java:2265) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.Loader.executeQueryStatement(Loader.java:2028) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.Loader.executeQueryStatement(Loader.java:1990) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.Loader.doQuery(Loader.java:949) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:351) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:321) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.Loader.loadCollectionBatch(Loader.java:2536) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.loader.collection.plan.LegacyBatchingCollectionInitializerBuilder$LegacyBatchingCollectionInitializer.initialize(LegacyBatchingCollectionInitializerBuilder.java:83) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.persister.collection.AbstractCollectionPersister.initialize(AbstractCollectionPersister.java:692) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.event.internal.DefaultInitializeCollectionEventListener.onInitializeCollection(DefaultInitializeCollectionEventListener.java:75) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.internal.SessionImpl.initializeCollection(SessionImpl.java:2266) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.collection.internal.AbstractPersistentCollection$4.doWork(AbstractPersistentCollection.java:585) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.collection.internal.AbstractPersistentCollection.withTemporarySessionIfNeeded(AbstractPersistentCollection.java:263) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.collection.internal.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:581) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.collection.internal.AbstractPersistentCollection.read(AbstractPersistentCollection.java:148) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.hibernate.collection.internal.PersistentBag.iterator(PersistentBag.java:390) ~[hibernate-core-5.3.17.Final.jar!/:5.3.17.Final]
at org.broadleafcommerce.core.search.service.solr.index.SolrIndexServiceImpl.attachIndexableDocumentFields(SolrIndexServiceImpl.java:524) ~[broadleaf-framework-6.1.3-GA.jar!/:na]
at org.broadleafcommerce.core.search.service.solr.index.SolrIndexServiceImpl.buildDocument(SolrIndexServiceImpl.java:506) ~[broadleaf-framework-6.1.3-GA.jar!/:na]
at
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52) ~[ROOT.jar:1.0.0-SNAPSHOT]
Caused by: java.sql.SQLSyntaxErrorException: Unknown column 'fieldtypes0_.ARCHIVED' in 'where clause'
My Configuration
database.user=root
# local database password
#
database.password=dockerPassword
database.driver=com.mysql.jdbc.Driver
# this connection URL assumes that it is connecting to a schema called broadleaf
database.url=jdbc:mysql://127.0.0.1:3306/broadleaf
blPU.hibernate.hbm2ddl.auto=create
blCMSStorage.hibernate.hbm2ddl.auto=create
blSecurePU.hibernate.hbm2ddl.auto=create
blEventPU.hibernate.hbm2ddl.auto=create
When running with java -jar
, be sure to include -javaagent:target/agents/spring-instrument.jar
as an argument so Spring can instrument the classes.