isis-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Benedict Jabines <jabines...@gmail.com>
Subject Re: Integration of Apache Isis and postgresql
Date Sat, 11 Nov 2017 01:37:10 GMT
I have created a separate connection to the db and I was able to
create a table registration.
Here is the code I tested:
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.Statement;

public class Test {
    public static void main(String args[]) {
        try {
            Class.forName("org.postgresql.Driver");
        } catch (ClassNotFoundException e) {
            System.out.println("error class not found exception");
            e.printStackTrace();
        }

        try {
            String URL = "jdbc:postgresql://192.168.99.100:5432/mubuss";
            String USER = "root";
            String PASS = "root";
            Connection conn = DriverManager.getConnection(URL, USER, PASS);
            Statement st = conn.createStatement();

            String sql = "CREATE TABLE REGISTRATION " +
                    "(id INTEGER not NULL, " +
                    " first VARCHAR(255), " +
                    " last VARCHAR(255), " +
                    " age INTEGER, " +
                    " PRIMARY KEY ( id ))";

            st.executeUpdate(sql);
        } catch (Exception es) {
            es.printStackTrace();
        }
    }
}

Take a look with the created table below:
[image: Inline image 1]

So I am guessing, there is another thing I need to do apart from
updating the pom.xml and isis.properties.

Hoping I can get a light. Thanks


<https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
Virus-free.
www.avast.com
<https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

On Fri, Nov 10, 2017 at 5:35 AM, Stephen Cameron <steve.cameron.62@gmail.com
> wrote:

> Can you create an JDBC connection independantly of Apache Isis? It does
> seem like the basic connection is the problem?
>
> On Fri, Nov 10, 2017 at 2:21 AM, Paul Benedict Jabines <
> jabinespbi@gmail.com
> > wrote:
>
> > Hi,
> >
> > This is in connection to my previous message about ResultSet is closed.
> > This time I already created a repo in github.com[1]. I am just wondering
> > why there is a problem when the only thing I have done is
> >
> > (1) adding a dependency in my pom.xml:
> >
> > <dependency>
> >     <groupId>postgresql</groupId>
> >     <artifactId>postgresql</artifactId>
> >     <version>9.1-901.jdbc4</version>
> > </dependency>
> >
> > (2) and uncomment this part in isis.properties:
> >
> > isis.persistor.datanucleus.impl.javax.jdo.option.
> ConnectionDriverName=org.
> > postgresql.Driver
> > isis.persistor.datanucleus.impl.javax.jdo.option.
> > ConnectionURL=jdbc:postgresql://192.168.99.100:5432/mubuss
> > isis.persistor.datanucleus.impl.javax.jdo.option.ConnectionUserName=root
> > isis.persistor.datanucleus.impl.javax.jdo.option.ConnectionPassword=root
> >
> > The full stacktrace of the error is this:
> >
> > 21:58:57,818  [IsisWicketApplication main       ERROR]  Failed to
> > initialize
> > com.google.inject.ProvisionException: Unable to provision, see the
> > following errors:
> >
> > 1) Error in custom provider,
> > org.datanucleus.exceptions.NucleusDataStoreException: This ResultSet
> > is closed.
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   while locating org.apache.isis.core.runtime.system.session.
> > IsisSessionFactory
> >     for field at
> > org.apache.isis.viewer.wicket.viewer.IsisWicketApplication.
> > isisSessionFactory(IsisWicketApplication.java:155)
> >   while locating domainapp.webapp.DomainApplication
> >
> > 1 error
> >         at com.google.inject.internal.Errors.
> > throwProvisionExceptionIfErrorsExist(Errors.java:486)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:67)
> >         at com.google.inject.internal.InjectorImpl.injectMembers(
> > InjectorImpl.java:987)
> >         at org.apache.isis.viewer.wicket.viewer.IsisWicketApplication.
> > init(IsisWicketApplication.java:368)
> >         at domainapp.webapp.DomainApplication.init(
> > DomainApplication.java:59)
> >         at org.apache.wicket.Application.initApplication(Application.
> > java:953)
> >         at org.apache.wicket.protocol.http.WicketFilter.init(
> > WicketFilter.java:429)
> >         at org.apache.wicket.protocol.http.WicketFilter.init(
> > WicketFilter.java:353)
> >         at org.eclipse.jetty.servlet.FilterHolder.initialize(
> > FilterHolder.java:139)
> >         at org.eclipse.jetty.servlet.ServletHandler.initialize(
> > ServletHandler.java:725)
> >         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> > ServletContextHandler.java:348)
> >         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> > WebAppContext.java:1480)
> >         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> > WebAppContext.java:1442)
> >         at org.eclipse.jetty.server.handler.ContextHandler.
> > doStart(ContextHandler.java:799)
> >         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> > ServletContextHandler.java:261)
> >         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> > WebAppContext.java:540)
> >         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> > start(AbstractLifeCycle.java:68)
> >         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> > start(ContainerLifeCycle.java:131)
> >         at org.eclipse.jetty.server.Server.start(Server.java:452)
> >         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> > doStart(ContainerLifeCycle.java:105)
> >         at org.eclipse.jetty.server.handler.AbstractHandler.
> > doStart(AbstractHandler.java:113)
> >         at org.eclipse.jetty.server.Server.doStart(Server.java:419)
> >         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> > start(AbstractLifeCycle.java:68)
> >         at org.apache.isis.core.webserver.WebServer.start(
> > WebServer.java:179)
> >         at org.apache.isis.core.webserver.WebServer.run(
> > WebServer.java:131)
> >         at org.apache.isis.core.webserver.WebServer.main(
> > WebServer.java:98)
> >         at org.apache.isis.WebServer.main(WebServer.java:25)
> > Caused by: org.datanucleus.exceptions.NucleusDataStoreException: This
> > ResultSet is closed.
> >         at org.datanucleus.store.rdbms.ConnectionFactoryImpl$
> > ManagedConnectionImpl.getConnection(ConnectionFactoryImpl.java:459)
> >         at org.datanucleus.store.rdbms.AbstractSchemaTransaction.
> > getCurrentConnection(AbstractSchemaTransaction.java:87)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager$ClassAdder.
> > performTablesValidation(RDBMSStoreManager.java:3365)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager$ClassAdder.
> > run(RDBMSStoreManager.java:2877)
> >         at org.datanucleus.store.rdbms.AbstractSchemaTransaction.
> execute(
> > AbstractSchemaTransaction.java:119)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager.
> > createSchemaForClasses(RDBMSStoreManager.java:3855)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.createSchema(
> > DataNucleusApplicationComponents.java:194)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.createPmfAndSchemaIfRequired(
> > DataNucleusApplicationComponents.java:153)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.initialize(
> DataNucleusApplicationComponen
> > ts.java:108)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.<init>(DataNucleusApplicationComponen
> > ts.java:101)
> >         at org.apache.isis.core.runtime.system.persistence.
> > PersistenceSessionFactory.createDataNucleusApplicationComponents(
> > PersistenceSessionFactory.java:99)
> >         at org.apache.isis.core.runtime.system.persistence.
> > PersistenceSessionFactory.init(PersistenceSessionFactory.java:76)
> >         at org.apache.isis.core.runtime.system.session.
> > IsisSessionFactoryBuilder.buildSessionFactory(IsisSessionFactoryBuilder.
> > java:196)
> >         at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:118)
> >         at org.apache.isis.core.runtime.runner.IsisInjectModule$$
> > FastClassByGuice$$a813f90e.invoke(<generated>)
> >         at com.google.inject.internal.ProviderMethod$
> > FastClassProviderMethod.doProvision(ProviderMethod.java:264)
> >         at com.google.inject.internal.ProviderMethod$Factory.
> > provision(ProviderMethod.java:401)
> >         at com.google.inject.internal.ProviderMethod$Factory.get(
> > ProviderMethod.java:376)
> >         at com.google.inject.internal.ProviderToInternalFactoryAdapt
> > er$1.call(ProviderToInternalFactoryAdapter.java:46)
> >         at com.google.inject.internal.InjectorImpl.callInContext(
> > InjectorImpl.java:1092)
> >         at com.google.inject.internal.ProviderToInternalFactoryAdapt
> > er.get(ProviderToInternalFactoryAdapter.java:40)
> >         at com.google.inject.internal.SingletonScope$1.get(
> > SingletonScope.java:194)
> >         at com.google.inject.internal.InternalFactoryToProviderAdapt
> > er.get(InternalFactoryToProviderAdapter.java:41)
> >         at com.google.inject.internal.SingleFieldInjector.inject(
> > SingleFieldInjector.java:54)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:132)
> >         at com.google.inject.internal.MembersInjectorImpl$1.call(
> > MembersInjectorImpl.java:93)
> >         at com.google.inject.internal.MembersInjectorImpl$1.call(
> > MembersInjectorImpl.java:80)
> >         at com.google.inject.internal.InjectorImpl.callInContext(
> > InjectorImpl.java:1085)
> >         at com.google.inject.internal.MembersInjectorImpl.
> injectAndNotify(
> > MembersInjectorImpl.java:80)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:62)
> >         ... 25 more
> > Caused by: org.postgresql.util.PSQLException: This ResultSet is closed.
> >         at org.postgresql.jdbc2.AbstractJdbc2ResultSet.checkClosed(
> > AbstractJdbc2ResultSet.java:2674)
> >         at org.postgresql.jdbc2.AbstractJdbc2ResultSet.setFetchSize(
> > AbstractJdbc2ResultSet.java:1791)
> >         at org.postgresql.jdbc4.Jdbc4Statement.createResultSet(
> > Jdbc4Statement.java:39)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement$
> > StatementResultHandler.handleResultRows(AbstractJdbc2Statement.java:211)
> >         at org.postgresql.core.v3.QueryExecutorImpl.processResults(
> > QueryExecutorImpl.java:1772)
> >         at org.postgresql.core.v3.QueryExecutorImpl.execute(
> > QueryExecutorImpl.java:257)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(
> > AbstractJdbc2Statement.java:500)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(
> > AbstractJdbc2Statement.java:374)
> >         at org.postgresql.jdbc2.AbstractJdbc2Connection.execSQLUpdate(
> > AbstractJdbc2Connection.java:263)
> >         at org.postgresql.jdbc2.AbstractJdbc2Connection.
> > getTransactionIsolation(AbstractJdbc2Connection.java:775)
> >         at org.datanucleus.store.rdbms.datasource.dbcp.
> > DelegatingConnection.getTransactionIsolation(
> > DelegatingConnection.java:330)
> >         at org.datanucleus.store.rdbms.datasource.dbcp.
> PoolingDataSource$
> > PoolGuardConnectionWrapper.getTransactionIsolation(
> > PoolingDataSource.java:247)
> >         at org.datanucleus.store.rdbms.ConnectionFactoryImpl$
> > ManagedConnectionImpl.getConnection(ConnectionFactoryImpl.java:427)
> >         ... 54 more
> > 21:58:57,858  [ThreadPoolSupport    main       INFO ]  join'ing 6
> > tasks: waited 0 milliseconds
> > 21:58:57,858  [WicketFilter         main       ERROR]  The
> > initialization of an application with name 'WicketFilter' has failed.
> > com.google.inject.ProvisionException: Unable to provision, see the
> > following errors:
> >
> > 1) Error in custom provider,
> > org.datanucleus.exceptions.NucleusDataStoreException: This ResultSet
> > is closed.
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   while locating org.apache.isis.core.runtime.system.session.
> > IsisSessionFactory
> >     for field at
> > org.apache.isis.viewer.wicket.viewer.IsisWicketApplication.
> > isisSessionFactory(IsisWicketApplication.java:155)
> >   while locating domainapp.webapp.DomainApplication
> >
> > 1 error
> >         at com.google.inject.internal.Errors.
> > throwProvisionExceptionIfErrorsExist(Errors.java:486)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:67)
> >         at com.google.inject.internal.InjectorImpl.injectMembers(
> > InjectorImpl.java:987)
> >         at org.apache.isis.viewer.wicket.viewer.IsisWicketApplication.
> > init(IsisWicketApplication.java:368)
> >         at domainapp.webapp.DomainApplication.init(
> > DomainApplication.java:59)
> >         at org.apache.wicket.Application.initApplication(Application.
> > java:953)
> >         at org.apache.wicket.protocol.http.WicketFilter.init(
> > WicketFilter.java:429)
> >         at org.apache.wicket.protocol.http.WicketFilter.init(
> > WicketFilter.java:353)
> >         at org.eclipse.jetty.servlet.FilterHolder.initialize(
> > FilterHolder.java:139)
> >         at org.eclipse.jetty.servlet.ServletHandler.initialize(
> > ServletHandler.java:725)
> >         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> > ServletContextHandler.java:348)
> >         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> > WebAppContext.java:1480)
> >         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> > WebAppContext.java:1442)
> >         at org.eclipse.jetty.server.handler.ContextHandler.
> > doStart(ContextHandler.java:799)
> >         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> > ServletContextHandler.java:261)
> >         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> > WebAppContext.java:540)
> >         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> > start(AbstractLifeCycle.java:68)
> >         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> > start(ContainerLifeCycle.java:131)
> >         at org.eclipse.jetty.server.Server.start(Server.java:452)
> >         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> > doStart(ContainerLifeCycle.java:105)
> >         at org.eclipse.jetty.server.handler.AbstractHandler.
> > doStart(AbstractHandler.java:113)
> >         at org.eclipse.jetty.server.Server.doStart(Server.java:419)
> >         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> > start(AbstractLifeCycle.java:68)
> >         at org.apache.isis.core.webserver.WebServer.start(
> > WebServer.java:179)
> >         at org.apache.isis.core.webserver.WebServer.run(
> > WebServer.java:131)
> >         at org.apache.isis.core.webserver.WebServer.main(
> > WebServer.java:98)
> >         at org.apache.isis.WebServer.main(WebServer.java:25)
> > Caused by: org.datanucleus.exceptions.NucleusDataStoreException: This
> > ResultSet is closed.
> >         at org.datanucleus.store.rdbms.ConnectionFactoryImpl$
> > ManagedConnectionImpl.getConnection(ConnectionFactoryImpl.java:459)
> >         at org.datanucleus.store.rdbms.AbstractSchemaTransaction.
> > getCurrentConnection(AbstractSchemaTransaction.java:87)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager$ClassAdder.
> > performTablesValidation(RDBMSStoreManager.java:3365)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager$ClassAdder.
> > run(RDBMSStoreManager.java:2877)
> >         at org.datanucleus.store.rdbms.AbstractSchemaTransaction.
> execute(
> > AbstractSchemaTransaction.java:119)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager.
> > createSchemaForClasses(RDBMSStoreManager.java:3855)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.createSchema(
> > DataNucleusApplicationComponents.java:194)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.createPmfAndSchemaIfRequired(
> > DataNucleusApplicationComponents.java:153)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.initialize(
> DataNucleusApplicationComponen
> > ts.java:108)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.<init>(DataNucleusApplicationComponen
> > ts.java:101)
> >         at org.apache.isis.core.runtime.system.persistence.
> > PersistenceSessionFactory.createDataNucleusApplicationComponents(
> > PersistenceSessionFactory.java:99)
> >         at org.apache.isis.core.runtime.system.persistence.
> > PersistenceSessionFactory.init(PersistenceSessionFactory.java:76)
> >         at org.apache.isis.core.runtime.system.session.
> > IsisSessionFactoryBuilder.buildSessionFactory(IsisSessionFactoryBuilder.
> > java:196)
> >         at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:118)
> >         at org.apache.isis.core.runtime.runner.IsisInjectModule$$
> > FastClassByGuice$$a813f90e.invoke(<generated>)
> >         at com.google.inject.internal.ProviderMethod$
> > FastClassProviderMethod.doProvision(ProviderMethod.java:264)
> >         at com.google.inject.internal.ProviderMethod$Factory.
> > provision(ProviderMethod.java:401)
> >         at com.google.inject.internal.ProviderMethod$Factory.get(
> > ProviderMethod.java:376)
> >         at com.google.inject.internal.ProviderToInternalFactoryAdapt
> > er$1.call(ProviderToInternalFactoryAdapter.java:46)
> >         at com.google.inject.internal.InjectorImpl.callInContext(
> > InjectorImpl.java:1092)
> >         at com.google.inject.internal.ProviderToInternalFactoryAdapt
> > er.get(ProviderToInternalFactoryAdapter.java:40)
> >         at com.google.inject.internal.SingletonScope$1.get(
> > SingletonScope.java:194)
> >         at com.google.inject.internal.InternalFactoryToProviderAdapt
> > er.get(InternalFactoryToProviderAdapter.java:41)
> >         at com.google.inject.internal.SingleFieldInjector.inject(
> > SingleFieldInjector.java:54)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:132)
> >         at com.google.inject.internal.MembersInjectorImpl$1.call(
> > MembersInjectorImpl.java:93)
> >         at com.google.inject.internal.MembersInjectorImpl$1.call(
> > MembersInjectorImpl.java:80)
> >         at com.google.inject.internal.InjectorImpl.callInContext(
> > InjectorImpl.java:1085)
> >         at com.google.inject.internal.MembersInjectorImpl.
> injectAndNotify(
> > MembersInjectorImpl.java:80)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:62)
> >         ... 25 more
> > Caused by: org.postgresql.util.PSQLException: This ResultSet is closed.
> >         at org.postgresql.jdbc2.AbstractJdbc2ResultSet.checkClosed(
> > AbstractJdbc2ResultSet.java:2674)
> >         at org.postgresql.jdbc2.AbstractJdbc2ResultSet.setFetchSize(
> > AbstractJdbc2ResultSet.java:1791)
> >         at org.postgresql.jdbc4.Jdbc4Statement.createResultSet(
> > Jdbc4Statement.java:39)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement$
> > StatementResultHandler.handleResultRows(AbstractJdbc2Statement.java:211)
> >         at org.postgresql.core.v3.QueryExecutorImpl.processResults(
> > QueryExecutorImpl.java:1772)
> >         at org.postgresql.core.v3.QueryExecutorImpl.execute(
> > QueryExecutorImpl.java:257)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(
> > AbstractJdbc2Statement.java:500)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(
> > AbstractJdbc2Statement.java:374)
> >         at org.postgresql.jdbc2.AbstractJdbc2Connection.execSQLUpdate(
> > AbstractJdbc2Connection.java:263)
> >         at org.postgresql.jdbc2.AbstractJdbc2Connection.
> > getTransactionIsolation(AbstractJdbc2Connection.java:775)
> >         at org.datanucleus.store.rdbms.datasource.dbcp.
> > DelegatingConnection.getTransactionIsolation(
> > DelegatingConnection.java:330)
> >         at org.datanucleus.store.rdbms.datasource.dbcp.
> PoolingDataSource$
> > PoolGuardConnectionWrapper.getTransactionIsolation(
> > PoolingDataSource.java:247)
> >         at org.datanucleus.store.rdbms.ConnectionFactoryImpl$
> > ManagedConnectionImpl.getConnection(ConnectionFactoryImpl.java:427)
> >         ... 54 more
> > 21:58:57,894  [Application          main       INFO ]  [WicketFilter]
> > destroy: Wicket core library initializer
> > 21:58:57,894  [Application          main       INFO ]  [WicketFilter]
> > destroy: DevUtils DebugBar Initializer
> > 21:58:57,895  [Application          main       INFO ]  [WicketFilter]
> > destroy: Wicket extensions initializer
> > 21:58:58,088  [WebAppContext        main       WARN ]  Failed startup
> > of context o.e.j.w.WebAppContext@50d0686{/,file:///D:/Paul/Workspace/
> > mubuss/webapp/src/main/webapp/,UNAVAILABLE}{src/main/webapp}
> > javax.servlet.ServletException: com.google.inject.ProvisionException:
> > Unable to provision, see the following errors:
> >
> > 1) Error in custom provider,
> > org.datanucleus.exceptions.NucleusDataStoreException: This ResultSet
> > is closed.
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   while locating org.apache.isis.core.runtime.system.session.
> > IsisSessionFactory
> >     for field at
> > org.apache.isis.viewer.wicket.viewer.IsisWicketApplication.
> > isisSessionFactory(IsisWicketApplication.java:155)
> >   while locating domainapp.webapp.DomainApplication
> >
> > 1 error
> >         at org.apache.wicket.protocol.http.WicketFilter.init(
> > WicketFilter.java:455)
> >         at org.apache.wicket.protocol.http.WicketFilter.init(
> > WicketFilter.java:353)
> >         at org.eclipse.jetty.servlet.FilterHolder.initialize(
> > FilterHolder.java:139)
> >         at org.eclipse.jetty.servlet.ServletHandler.initialize(
> > ServletHandler.java:725)
> >         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> > ServletContextHandler.java:348)
> >         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> > WebAppContext.java:1480)
> >         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> > WebAppContext.java:1442)
> >         at org.eclipse.jetty.server.handler.ContextHandler.
> > doStart(ContextHandler.java:799)
> >         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> > ServletContextHandler.java:261)
> >         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> > WebAppContext.java:540)
> >         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> > start(AbstractLifeCycle.java:68)
> >         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> > start(ContainerLifeCycle.java:131)
> >         at org.eclipse.jetty.server.Server.start(Server.java:452)
> >         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> > doStart(ContainerLifeCycle.java:105)
> >         at org.eclipse.jetty.server.handler.AbstractHandler.
> > doStart(AbstractHandler.java:113)
> >         at org.eclipse.jetty.server.Server.doStart(Server.java:419)
> >         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> > start(AbstractLifeCycle.java:68)
> >         at org.apache.isis.core.webserver.WebServer.start(
> > WebServer.java:179)
> >         at org.apache.isis.core.webserver.WebServer.run(
> > WebServer.java:131)
> >         at org.apache.isis.core.webserver.WebServer.main(
> > WebServer.java:98)
> >         at org.apache.isis.WebServer.main(WebServer.java:25)
> > Caused by: com.google.inject.ProvisionException: Unable to provision,
> > see the following errors:
> >
> > 1) Error in custom provider,
> > org.datanucleus.exceptions.NucleusDataStoreException: This ResultSet
> > is closed.
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:109)
> >   while locating org.apache.isis.core.runtime.system.session.
> > IsisSessionFactory
> >     for field at
> > org.apache.isis.viewer.wicket.viewer.IsisWicketApplication.
> > isisSessionFactory(IsisWicketApplication.java:155)
> >   while locating domainapp.webapp.DomainApplication
> >
> > 1 error
> >         at com.google.inject.internal.Errors.
> > throwProvisionExceptionIfErrorsExist(Errors.java:486)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:67)
> >         at com.google.inject.internal.InjectorImpl.injectMembers(
> > InjectorImpl.java:987)
> >         at org.apache.isis.viewer.wicket.viewer.IsisWicketApplication.
> > init(IsisWicketApplication.java:368)
> >         at domainapp.webapp.DomainApplication.init(
> > DomainApplication.java:59)
> >         at org.apache.wicket.Application.initApplication(Application.
> > java:953)
> >         at org.apache.wicket.protocol.http.WicketFilter.init(
> > WicketFilter.java:429)
> >         ... 20 more
> > Caused by: org.datanucleus.exceptions.NucleusDataStoreException: This
> > ResultSet is closed.
> >         at org.datanucleus.store.rdbms.ConnectionFactoryImpl$
> > ManagedConnectionImpl.getConnection(ConnectionFactoryImpl.java:459)
> >         at org.datanucleus.store.rdbms.AbstractSchemaTransaction.
> > getCurrentConnection(AbstractSchemaTransaction.java:87)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager$ClassAdder.
> > performTablesValidation(RDBMSStoreManager.java:3365)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager$ClassAdder.
> > run(RDBMSStoreManager.java:2877)
> >         at org.datanucleus.store.rdbms.AbstractSchemaTransaction.
> execute(
> > AbstractSchemaTransaction.java:119)
> >         at org.datanucleus.store.rdbms.RDBMSStoreManager.
> > createSchemaForClasses(RDBMSStoreManager.java:3855)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.createSchema(
> > DataNucleusApplicationComponents.java:194)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.createPmfAndSchemaIfRequired(
> > DataNucleusApplicationComponents.java:153)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.initialize(
> DataNucleusApplicationComponen
> > ts.java:108)
> >         at org.apache.isis.core.runtime.system.persistence.
> > DataNucleusApplicationComponents.<init>(DataNucleusApplicationComponen
> > ts.java:101)
> >         at org.apache.isis.core.runtime.system.persistence.
> > PersistenceSessionFactory.createDataNucleusApplicationComponents(
> > PersistenceSessionFactory.java:99)
> >         at org.apache.isis.core.runtime.system.persistence.
> > PersistenceSessionFactory.init(PersistenceSessionFactory.java:76)
> >         at org.apache.isis.core.runtime.system.session.
> > IsisSessionFactoryBuilder.buildSessionFactory(IsisSessionFactoryBuilder.
> > java:196)
> >         at org.apache.isis.core.runtime.runner.IsisInjectModule.
> > provideIsisSessionFactory(IsisInjectModule.java:118)
> >         at org.apache.isis.core.runtime.runner.IsisInjectModule$$
> > FastClassByGuice$$a813f90e.invoke(<generated>)
> >         at com.google.inject.internal.ProviderMethod$
> > FastClassProviderMethod.doProvision(ProviderMethod.java:264)
> >         at com.google.inject.internal.ProviderMethod$Factory.
> > provision(ProviderMethod.java:401)
> >         at com.google.inject.internal.ProviderMethod$Factory.get(
> > ProviderMethod.java:376)
> >         at com.google.inject.internal.ProviderToInternalFactoryAdapt
> > er$1.call(ProviderToInternalFactoryAdapter.java:46)
> >         at com.google.inject.internal.InjectorImpl.callInContext(
> > InjectorImpl.java:1092)
> >         at com.google.inject.internal.ProviderToInternalFactoryAdapt
> > er.get(ProviderToInternalFactoryAdapter.java:40)
> >         at com.google.inject.internal.SingletonScope$1.get(
> > SingletonScope.java:194)
> >         at com.google.inject.internal.InternalFactoryToProviderAdapt
> > er.get(InternalFactoryToProviderAdapter.java:41)
> >         at com.google.inject.internal.SingleFieldInjector.inject(
> > SingleFieldInjector.java:54)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:132)
> >         at com.google.inject.internal.MembersInjectorImpl$1.call(
> > MembersInjectorImpl.java:93)
> >         at com.google.inject.internal.MembersInjectorImpl$1.call(
> > MembersInjectorImpl.java:80)
> >         at com.google.inject.internal.InjectorImpl.callInContext(
> > InjectorImpl.java:1085)
> >         at com.google.inject.internal.MembersInjectorImpl.
> injectAndNotify(
> > MembersInjectorImpl.java:80)
> >         at com.google.inject.internal.MembersInjectorImpl.injectMembers(
> > MembersInjectorImpl.java:62)
> >         ... 25 more
> > Caused by: org.postgresql.util.PSQLException: This ResultSet is closed.
> >         at org.postgresql.jdbc2.AbstractJdbc2ResultSet.checkClosed(
> > AbstractJdbc2ResultSet.java:2674)
> >         at org.postgresql.jdbc2.AbstractJdbc2ResultSet.setFetchSize(
> > AbstractJdbc2ResultSet.java:1791)
> >         at org.postgresql.jdbc4.Jdbc4Statement.createResultSet(
> > Jdbc4Statement.java:39)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement$
> > StatementResultHandler.handleResultRows(AbstractJdbc2Statement.java:211)
> >         at org.postgresql.core.v3.QueryExecutorImpl.processResults(
> > QueryExecutorImpl.java:1772)
> >         at org.postgresql.core.v3.QueryExecutorImpl.execute(
> > QueryExecutorImpl.java:257)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(
> > AbstractJdbc2Statement.java:500)
> >         at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(
> > AbstractJdbc2Statement.java:374)
> >         at org.postgresql.jdbc2.AbstractJdbc2Connection.execSQLUpdate(
> > AbstractJdbc2Connection.java:263)
> >         at org.postgresql.jdbc2.AbstractJdbc2Connection.
> > getTransactionIsolation(AbstractJdbc2Connection.java:775)
> >         at org.datanucleus.store.rdbms.datasource.dbcp.
> > DelegatingConnection.getTransactionIsolation(
> > DelegatingConnection.java:330)
> >         at org.datanucleus.store.rdbms.datasource.dbcp.
> PoolingDataSource$
> > PoolGuardConnectionWrapper.getTransactionIsolation(
> > PoolingDataSource.java:247)
> >         at org.datanucleus.store.rdbms.ConnectionFactoryImpl$
> > ManagedConnectionImpl.getConnection(ConnectionFactoryImpl.java:427)
> >         ... 54 more
> >
> > For the postgresql, I use this docker-compose.yml:
> >
> > db:
> >   image: "postgres:latest"
> >   ports:
> >     - "5432:5432"
> >   environment:
> >     - POSTGRES_PASSWORD=root
> >     - POSTGRES_USER=root
> >     - POSTGRES_DATABASE=root
> >
> > I hope someone can shed a light on this. Thanks.
> >
> > [1] https://github.com/jabinespbi/Mubuss
> >
> > Best regards,
> > - Paul
> >
> > <https://www.avast.com/sig-email?utm_medium=email&utm_
> > source=link&utm_campaign=sig-email&utm_content=webmail>
> > Virus-free.
> > www.avast.com
> > <https://www.avast.com/sig-email?utm_medium=email&utm_
> > source=link&utm_campaign=sig-email&utm_content=webmail>
> > <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
> >
>



-- 
- Paul

Mime
  • Unnamed multipart/related (inline, None, 0 bytes)
View raw message