MYSQL Exception - Field 'ID' doesn't have a default value

Recently moved to Galera 5.7.17 cluster and been fine for a few days but today getting MySQL Exception error when creating a quick task. Cannot tell which table it is trying to write too, or why it's erroring. The ID column is part of a primary key pair typically so must require a value be set when creating, but DB table shows column as "No Default". Any ideas? 

 

Database:
- name:MySQL
- version:5.7.17-13-57
- minor version:7
- major version:5
Driver:
- name:MySQL Connector Java
- version:mysql-connector-java-5.1.42 ( Revision: 1f61b0b0270d9844b006572ba4e77f19c0f230d4 )
java.sql.SQLException: Field 'ID' doesn't have a default value
at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.create(EntityManagedActiveObjects.java:94)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects.create(TenantAwareActiveObjects.java:266)
... 2 filtered
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:56)
at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:60)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:70)
at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:53)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.eclipse.gemini.blueprint.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:57)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207)
at com.sun.proxy.$Proxy2630.create(Unknown Source)
at com.atlassian.greenhopper.manager.lexorank.collation.CollationIntegrityDao.createCollationCheckRows(CollationIntegrityDao.java:49)
at com.atlassian.greenhopper.manager.lexorank.collation.CollationIntegrityCheckerImpl.getLexoRankDaoContext(CollationIntegrityCheckerImpl.java:60)
at com.atlassian.greenhopper.manager.lexorank.LexoRankDaoImpl.getContext(LexoRankDaoImpl.java:182)
at com.atlassian.greenhopper.manager.lexorank.LexoRankDaoImpl.findByFieldAndIssueId(LexoRankDaoImpl.java:216)
at com.atlassian.greenhopper.service.lexorank.LexoRankOperation.rankRelativeToOtherIssue(LexoRankOperation.java:281)
at com.atlassian.greenhopper.service.lexorank.LexoRankOperation.execute(LexoRankOperation.java:109)
at com.atlassian.greenhopper.manager.lexorank.LexoRankManagerImpl.performRankOperation(LexoRankManagerImpl.java:300)
at com.atlassian.greenhopper.manager.lexorank.LexoRankManagerImpl.rankAfter(LexoRankManagerImpl.java:179)
at com.atlassian.greenhopper.service.rank.RankServiceImpl.doRankAfter(RankServiceImpl.java:283)
at com.atlassian.greenhopper.service.rank.RankServiceImpl.doRankAfter(RankServiceImpl.java:296)
at com.atlassian.greenhopper.service.rank.RankServiceImpl.access$100(RankServiceImpl.java:46)
at com.atlassian.greenhopper.service.rank.RankServiceImpl$2.apply(RankServiceImpl.java:118)
at com.atlassian.greenhopper.service.rank.RankServiceImpl$2.apply(RankServiceImpl.java:114)
at com.atlassian.greenhopper.service.ServiceOutcomes.flatMap(ServiceOutcomes.java:49)
at com.atlassian.greenhopper.service.rank.RankServiceImpl.rankAfter(RankServiceImpl.java:113)
at com.atlassian.greenhopper.web.rapid.sprint.SprintRankResource.getRankChanges(SprintRankResource.java:211)
at com.atlassian.greenhopper.web.rapid.sprint.SprintRankResource.lambda$updateSprintAndRank$0(SprintRankResource.java:120)
at com.atlassian.greenhopper.web.util.RestCall.response(RestCall.java:42)
at com.atlassian.greenhopper.web.AbstractResource.createResponse(AbstractResource.java:111)
at com.atlassian.greenhopper.web.AbstractResource.response(AbstractResource.java:91)
at com.atlassian.greenhopper.web.rapid.sprint.SprintRankResource.updateSprintAndRank(SprintRankResource.java:87)
... 3 filtered
at java.lang.reflect.Method.invoke(Method.java:498)
... 18 filtered
at com.atlassian.plugins.rest.module.RestDelegatingServletFilter$JerseyOsgiServletContainer.doFilter(RestDelegatingServletFilter.java:154)
... 1 filtered
at com.atlassian.plugins.rest.module.RestDelegatingServletFilter.doFilter(RestDelegatingServletFilter.java:68)
... 36 filtered
at com.atlassian.web.servlet.plugin.request.RedirectInterceptingFilter.doFilter(RedirectInterceptingFilter.java:21)
... 53 filtered
at com.atlassian.jira.security.JiraSecurityFilter.lambda$doFilter$0(JiraSecurityFilter.java:80)
... 1 filtered
at com.atlassian.jira.security.JiraSecurityFilter.doFilter(JiraSecurityFilter.java:78)
... 16 filtered
at com.atlassian.plugins.rest.module.servlet.RestSeraphFilter.doFilter(RestSeraphFilter.java:37)
... 20 filtered
at com.atlassian.jira.servermetrics.CorrelationIdPopulatorFilter.doFilter(CorrelationIdPopulatorFilter.java:30)
... 10 filtered
at com.atlassian.web.servlet.plugin.request.RedirectInterceptingFilter.doFilter(RedirectInterceptingFilter.java:21)
... 4 filtered
at com.atlassian.web.servlet.plugin.LocationCleanerFilter.doFilter(LocationCleanerFilter.java:36)
... 29 filtered
at com.atlassian.jira.servermetrics.MetricsCollectorFilter.doFilter(MetricsCollectorFilter.java:25)
... 28 filtered
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.sql.SQLException: Field 'ID' doesn't have a default value
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:964)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3973)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3909)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2527)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2680)
at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1858)
at com.mysql.jdbc.PreparedStatement.executeUpdateInternal(PreparedStatement.java:2079)
at com.mysql.jdbc.PreparedStatement.executeUpdateInternal(PreparedStatement.java:2013)
at com.mysql.jdbc.PreparedStatement.executeLargeUpdate(PreparedStatement.java:5104)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1998)
at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:98)
at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:98)
at net.java.ao.DatabaseProvider.executeInsertReturningKey(DatabaseProvider.java:1947)
at net.java.ao.DatabaseProvider.insertReturningKey(DatabaseProvider.java:1861)
at net.java.ao.EntityManager.create(EntityManager.java:366)
at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.create(EntityManagedActiveObjects.java:92)
... 276 more

 

 

1 answer

0 vote

Hi,

Is a Galera Cluster MariaDB?  If so I would try setting up a MYSQL database according to Connecting JIRA applications to MySQL to see if you get the same results as a test.

Neither MariaDB nor PerconaDB are supported. Both are proven to cause problems with JIRA applications.

In addition there is a Suggestion to support MariaDB that you can find at JRASERVER-32347.  Please vote on the issue to add impact and you'll be notified directly of any updates to the Suggestion ticket.

Cheers,

Branden

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Sarah Schuster
Posted Mar 28, 2018 in Jira Software

Can a company’s culture make or break agile adoption?

Can a new-to-agile team survive and thrive in a non-agile culture? If so, what advice would you give to those trying to be agile in a non-agile culture? What's the key(s) to success? Share your thoug...

11,957 views 15 13
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you