App Within Minutes - ClassEditSheet 

Page / - last modified by Julien Fleury on 2020/12/12 16:56 

ClassEditSheet 
last modified by Julien Fleury
on 2020/12/12 16:56

Table of Contents

Failed to execute the [velocity] macro. Cause: [Connection refused (Connection refused)]. Click on this message for details.
org.xwiki.rendering.macro.MacroExecutionException: Failed to evaluate Velocity Macro for content [{{html clean="false"}}
## Determine the action button that triggered the request
#set ($action = 'edit')
#foreach ($paramName in $request.getParameterMap().keySet())
  #if ($paramName.startsWith('xaction_'))
    #set ($action = $paramName.substring(8))
    #break
  #end
#end
#if ($action == 'edit')
  #doEdit()
#elseif ($action == 'save' || $action == 'saveandcontinue')
  #if ($services.csrf.isTokenValid($request.form_token))
    #doSave()
  #else
    $response.sendRedirect($services.csrf.getResubmissionURL())
  #end
#end
{{/html}}]
 at org.xwiki.rendering.internal.macro.velocity.VelocityMacro.evaluateString(VelocityMacro.java:139)
 at org.xwiki.rendering.internal.macro.velocity.VelocityMacro.evaluateString(VelocityMacro.java:52)
 at org.xwiki.rendering.macro.script.AbstractScriptMacro.evaluateBlock(AbstractScriptMacro.java:286)
 at org.xwiki.rendering.macro.script.AbstractScriptMacro.execute(AbstractScriptMacro.java:182)
 at org.xwiki.rendering.macro.script.AbstractScriptMacro.execute(AbstractScriptMacro.java:58)
 at org.xwiki.rendering.internal.transformation.macro.MacroTransformation.transform(MacroTransformation.java:297)
 at org.xwiki.rendering.internal.transformation.DefaultRenderingContext.transformInContext(DefaultRenderingContext.java:183)
 at org.xwiki.rendering.internal.transformation.DefaultTransformationManager.performTransformations(DefaultTransformationManager.java:103)
 at org.xwiki.display.internal.DocumentContentAsyncExecutor.executeInCurrentExecutionContext(DocumentContentAsyncExecutor.java:348)
 at org.xwiki.display.internal.DocumentContentAsyncExecutor.execute(DocumentContentAsyncExecutor.java:221)
 at org.xwiki.display.internal.DocumentContentAsyncRenderer.execute(DocumentContentAsyncRenderer.java:107)
 at org.xwiki.rendering.async.internal.block.AbstractBlockAsyncRenderer.render(AbstractBlockAsyncRenderer.java:157)
 at org.xwiki.rendering.async.internal.block.AbstractBlockAsyncRenderer.render(AbstractBlockAsyncRenderer.java:54)
 at org.xwiki.rendering.async.internal.DefaultAsyncRendererExecutor.syncRender(DefaultAsyncRendererExecutor.java:273)
 at org.xwiki.rendering.async.internal.DefaultAsyncRendererExecutor.render(DefaultAsyncRendererExecutor.java:250)
 at org.xwiki.rendering.async.internal.block.DefaultBlockAsyncRendererExecutor.execute(DefaultBlockAsyncRendererExecutor.java:125)
 at org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentDisplayer.java:67)
 at org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentDisplayer.java:43)
 at org.xwiki.display.internal.DefaultDocumentDisplayer.display(DefaultDocumentDisplayer.java:96)
 at org.xwiki.display.internal.DefaultDocumentDisplayer.display(DefaultDocumentDisplayer.java:39)
 at org.xwiki.sheet.internal.SheetDocumentDisplayer.display(SheetDocumentDisplayer.java:123)
 at org.xwiki.sheet.internal.SheetDocumentDisplayer.display(SheetDocumentDisplayer.java:52)
 at org.xwiki.display.internal.ConfiguredDocumentDisplayer.display(ConfiguredDocumentDisplayer.java:68)
 at org.xwiki.display.internal.ConfiguredDocumentDisplayer.display(ConfiguredDocumentDisplayer.java:42)
 at com.xpn.xwiki.doc.XWikiDocument.display(XWikiDocument.java:1225)
 at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:1362)
 at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:1329)
 at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:1243)
 at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:1371)
 at com.xpn.xwiki.api.Document.getRenderedContent(Document.java:803)
 at jdk.internal.reflect.GeneratedMethodAccessor593.invoke(Unknown Source)
 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.base/java.lang.reflect.Method.invoke(Method.java:566)
 at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:571)
 at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:554)
 at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:221)
 at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:368)
 at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:492)
 at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:147)
 at org.apache.velocity.runtime.directive.Foreach.renderBlock(Foreach.java:309)
 at org.apache.velocity.runtime.directive.Foreach.render(Foreach.java:279)
 at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:304)
 at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:439)
 at org.apache.velocity.Template.merge(Template.java:358)
 at org.apache.velocity.Template.merge(Template.java:262)
 at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:280)
 at com.xpn.xwiki.render.DefaultVelocityManager.evaluate(DefaultVelocityManager.java:321)
 at com.xpn.xwiki.internal.template.VelocityTemplateEvaluator.evaluateContent(VelocityTemplateEvaluator.java:95)
 at com.xpn.xwiki.internal.template.TemplateAsyncRenderer.evaluateContent(TemplateAsyncRenderer.java:217)
 at com.xpn.xwiki.internal.template.TemplateAsyncRenderer.renderVelocity(TemplateAsyncRenderer.java:180)
 at com.xpn.xwiki.internal.template.TemplateAsyncRenderer.render(TemplateAsyncRenderer.java:137)
 at com.xpn.xwiki.internal.template.TemplateAsyncRenderer.render(TemplateAsyncRenderer.java:53)
 at org.xwiki.rendering.async.internal.DefaultAsyncRendererExecutor.lambda$syncRender$0(DefaultAsyncRendererExecutor.java:267)
 at com.xpn.xwiki.internal.security.authorization.DefaultAuthorExecutor.call(DefaultAuthorExecutor.java:98)
 at org.xwiki.rendering.async.internal.DefaultAsyncRendererExecutor.syncRender(DefaultAsyncRendererExecutor.java:267)
 at org.xwiki.rendering.async.internal.DefaultAsyncRendererExecutor.render(DefaultAsyncRendererExecutor.java:250)
 at org.xwiki.rendering.async.internal.block.DefaultBlockAsyncRendererExecutor.render(DefaultBlockAsyncRendererExecutor.java:154)
 at com.xpn.xwiki.internal.template.InternalTemplateManager.render(InternalTemplateManager.java:772)
 at com.xpn.xwiki.internal.template.InternalTemplateManager.renderFromSkin(InternalTemplateManager.java:745)
 at com.xpn.xwiki.internal.template.InternalTemplateManager.renderFromSkin(InternalTemplateManager.java:725)
 at com.xpn.xwiki.internal.template.InternalTemplateManager.render(InternalTemplateManager.java:711)
 at com.xpn.xwiki.internal.template.DefaultTemplateManager.render(DefaultTemplateManager.java:78)
 at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:2523)
 at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:2501)
 at com.xpn.xwiki.pdf.impl.PdfExportImpl.export(PdfExportImpl.java:153)
 at com.xpn.xwiki.web.ExportAction.export(ExportAction.java:191)
 at com.xpn.xwiki.web.ExportAction.render(ExportAction.java:98)
 at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:589)
 at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:286)
 at com.xpn.xwiki.web.LegacyActionServlet.service(LegacyActionServlet.java:104)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
 at com.xpn.xwiki.web.ActionFilter.doFilter(ActionFilter.java:122)
 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
 at org.xwiki.wysiwyg.filter.ConversionFilter.doFilter(ConversionFilter.java:109)
 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
 at org.xwiki.container.servlet.filters.internal.SetHTTPHeaderFilter.doFilter(SetHTTPHeaderFilter.java:63)
 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
 at org.xwiki.container.servlet.filters.internal.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:208)
 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
 at org.xwiki.container.servlet.filters.internal.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:111)
 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
 at org.xwiki.resource.servlet.RoutingFilter.doFilter(RoutingFilter.java:132)
 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
 at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202)
 at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
 at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541)
 at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
 at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
 at org.apache.catalina.valves.RemoteIpValve.invoke(RemoteIpValve.java:747)
 at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:688)
 at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
 at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:351)
 at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:375)
 at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
 at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
 at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1594)
 at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
 at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
 at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
 at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
 at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: org.xwiki.velocity.XWikiVelocityException: Failed to evaluate content with namespace [xwiki:AppWithinMinutes.ClassEditSheet]
 at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:288)
 at com.xpn.xwiki.render.DefaultVelocityManager.evaluate(DefaultVelocityManager.java:321)
 at org.xwiki.rendering.internal.macro.velocity.VelocityMacro.evaluateString(VelocityMacro.java:131)
 ... 108 more
Caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'execute' in  class org.xwiki.query.internal.ScriptQuery threw exception org.xwiki.query.QueryException: Exception while executing query. Query statement = [ select doc.fullName from XWikiDocument as doc , BaseObject as category , com.xpn.xwiki.objects.LongProperty as category_priority1 WHERE 1=1  and doc.fullName=category.name and category.className='AppWithinMinutes.FormFieldCategoryClass' and category_priority1.id.id=category.id and category_priority1.id.name='priority' order by category_priority1.value ] at xwiki:AppWithinMinutes.ClassEditSheet[line 19, column 69]
 at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:308)
 at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:235)
 at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:368)
 at org.apache.velocity.runtime.parser.node.ASTReference.value(ASTReference.java:704)
 at org.apache.velocity.runtime.directive.Foreach.render(Foreach.java:237)
 at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:304)
 at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:147)
 at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:218)
 at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:331)
 at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:261)
 at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:304)
 at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:147)
 at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:218)
 at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:331)
 at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:261)
 at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:304)
 at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:147)
 at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:439)
 at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:190)
 at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:147)
 at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:218)
 at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:331)
 at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:261)
 at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:304)
 at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:147)
 at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:171)
 at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:439)
 at org.apache.velocity.Template.merge(Template.java:358)
 at org.apache.velocity.Template.merge(Template.java:262)
 at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:280)
 ... 110 more
Caused by: org.xwiki.query.QueryException: Exception while executing query. Query statement = [ select doc.fullName from XWikiDocument as doc , BaseObject as category , com.xpn.xwiki.objects.LongProperty as category_priority1 WHERE 1=1  and doc.fullName=category.name and category.className='AppWithinMinutes.FormFieldCategoryClass' and category_priority1.id.id=category.id and category_priority1.id.name='priority' order by category_priority1.value ]
 at com.xpn.xwiki.store.hibernate.query.HqlQueryExecutor.execute(HqlQueryExecutor.java:176)
 at org.xwiki.query.internal.DefaultQueryExecutorManager.execute(DefaultQueryExecutorManager.java:72)
 at org.xwiki.query.internal.DefaultQuery.execute(DefaultQuery.java:306)
 at org.xwiki.query.xwql.internal.XWQLQueryExecutor.execute(XWQLQueryExecutor.java:124)
 at org.xwiki.query.internal.DefaultQueryExecutorManager.execute(DefaultQueryExecutorManager.java:72)
 at org.xwiki.query.internal.SecureQueryExecutorManager.execute(SecureQueryExecutorManager.java:67)
 at org.xwiki.query.internal.DefaultQuery.execute(DefaultQuery.java:306)
 at org.xwiki.query.internal.ScriptQuery.execute(ScriptQuery.java:254)
 at jdk.internal.reflect.GeneratedMethodAccessor506.invoke(Unknown Source)
 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.base/java.lang.reflect.Method.invoke(Method.java:566)
 at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:571)
 at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:554)
 at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:221)
 ... 138 more
Caused by: com.xpn.xwiki.XWikiException: Error number 0 in 3: Exception while hibernate execute
 at com.xpn.xwiki.store.XWikiHibernateBaseStore.execute(XWikiHibernateBaseStore.java:826)
 at com.xpn.xwiki.store.XWikiHibernateBaseStore.executeRead(XWikiHibernateBaseStore.java:889)
 at com.xpn.xwiki.store.hibernate.query.HqlQueryExecutor.execute(HqlQueryExecutor.java:164)
 ... 151 more
Caused by: org.hibernate.exception.JDBCConnectionException: Unable to acquire JDBC Connection
 at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:112)
 at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
 at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
 at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99)
 at org.hibernate.resource.jdbc.internal.LogicalConnectionManagedImpl.acquireConnectionIfNeeded(LogicalConnectionManagedImpl.java:111)
 at org.hibernate.resource.jdbc.internal.LogicalConnectionManagedImpl.getPhysicalConnection(LogicalConnectionManagedImpl.java:138)
 at org.hibernate.resource.jdbc.internal.LogicalConnectionManagedImpl.getConnectionForTransactionManagement(LogicalConnectionManagedImpl.java:274)
 at org.hibernate.resource.jdbc.internal.LogicalConnectionManagedImpl.begin(LogicalConnectionManagedImpl.java:282)
 at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.begin(JdbcResourceLocalTransactionCoordinatorImpl.java:246)
 at org.hibernate.engine.transaction.internal.TransactionImpl.begin(TransactionImpl.java:83)
 at org.hibernate.internal.AbstractSharedSessionContract.beginTransaction(AbstractSharedSessionContract.java:480)
 at org.hibernate.engine.spi.SessionDelegatorBaseImpl.beginTransaction(SessionDelegatorBaseImpl.java:486)
 at com.xpn.xwiki.internal.store.hibernate.HibernateStore.beginTransaction(HibernateStore.java:802)
 at com.xpn.xwiki.internal.store.hibernate.HibernateStore.beginTransaction(HibernateStore.java:753)
 at com.xpn.xwiki.store.XWikiHibernateBaseStore.beginTransaction(XWikiHibernateBaseStore.java:532)
 at com.xpn.xwiki.store.XWikiHibernateBaseStore.execute(XWikiHibernateBaseStore.java:819)
 ... 153 more
Caused by: com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link failure

The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
 at com.mysql.cj.jdbc.exceptions.SQLError.createCommunicationsException(SQLError.java:174)
 at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:64)
 at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:833)
 at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:453)
 at com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:246)
 at com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:198)
 at org.apache.commons.dbcp2.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:52)
 at org.apache.commons.dbcp2.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:357)
 at org.apache.commons.pool2.impl.GenericObjectPool.create(GenericObjectPool.java:918)
 at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:431)
 at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:356)
 at org.apache.commons.dbcp2.PoolingDataSource.getConnection(PoolingDataSource.java:134)
 at org.apache.commons.dbcp2.BasicDataSource.getConnection(BasicDataSource.java:734)
 at com.xpn.xwiki.store.DBCPConnectionProvider.getConnection(DBCPConnectionProvider.java:258)
 at org.hibernate.internal.NonContextualJdbcConnectionAccess.obtainConnection(NonContextualJdbcConnectionAccess.java:38)
 at org.hibernate.resource.jdbc.internal.LogicalConnectionManagedImpl.acquireConnectionIfNeeded(LogicalConnectionManagedImpl.java:108)
 ... 164 more
Caused by: com.mysql.cj.exceptions.CJCommunicationsException: Communications link failure

The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
 at jdk.internal.reflect.GeneratedConstructorAccessor22357.newInstance(Unknown Source)
 at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
 at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
 at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:61)
 at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:105)
 at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:151)
 at com.mysql.cj.exceptions.ExceptionFactory.createCommunicationsException(ExceptionFactory.java:167)
 at com.mysql.cj.protocol.a.NativeSocketConnection.connect(NativeSocketConnection.java:89)
 at com.mysql.cj.NativeSession.connect(NativeSession.java:144)
 at com.mysql.cj.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:953)
 at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:823)
 ... 177 more
Caused by: java.net.ConnectException: Connection refused (Connection refused)
 at java.base/java.net.PlainSocketImpl.socketConnect(Native Method)
 at java.base/java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:412)
 at java.base/java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:255)
 at java.base/java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:237)
 at java.base/java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
 at java.base/java.net.Socket.connect(Socket.java:609)
 at com.mysql.cj.protocol.StandardSocketFactory.connect(StandardSocketFactory.java:155)
 at com.mysql.cj.protocol.a.NativeSocketConnection.connect(NativeSocketConnection.java:63)
 ... 180 more