Multiple mysql sources streamed to the same snowflake db are failing after the first successful sync

  • Is this your first time deploying Airbyte?: Yes
  • OS Version / Instance: Ubuntu
  • Memory / Disk: you can use something like 4Gb / 1 Tb
  • Deployment: Docker
  • Airbyte Version: What version are you using now?
  • Source name/version:
  • Destination name/version: * 0.36.2-alpha
  • Step: The issue is happening after a first successful sync. the next time it will run it will fail on all connector using the same destination (Snowflake)
    logs-379.txt (3.2 MB)

The interesting part is that if I create another destination with a different snowflake user, as long as they are assigned with one source the continuously sync, once I add another source to the same destination it fails

Hi!
Could you please first upgrade your connectors to the latest version (I’ve no clue if it will solve the problem but it’s easier to troubleshoot if you run our latest connectors version).
I think you are facing multiple errors.
The first one I found in your log is a timeout on reading your MySQL source. Could you try to read less data or increase the wait_timeout on MySQL?

2022-06-20 09:57:20 e[44msourcee[0m > Exception in thread "main" java.lang.RuntimeException: java.lang.RuntimeException: com.mysql.cj.jdbc.exceptions.CommunicationsException: The last packet successfully received from the server was 7,200,066 milliseconds ago. The last packet sent successfully to the server was 7,230,135 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem.2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.source.relationaldb.AbstractRelationalDbSource.lambda$queryTable$0(AbstractRelationalDbSource.java:64)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.commons.util.LazyAutoCloseableIterator.computeNext(LazyAutoCloseableIterator.java:37)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:146)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:141)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.TransformedIterator.hasNext(TransformedIterator.java:46)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.commons.util.DefaultAutoCloseableIterator.computeNext(DefaultAutoCloseableIterator.java:38)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:146)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:141)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.TransformedIterator.hasNext(TransformedIterator.java:46)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.commons.util.DefaultAutoCloseableIterator.computeNext(DefaultAutoCloseableIterator.java:38)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:146)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:141)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.commons.util.CompositeIterator.computeNext(CompositeIterator.java:63)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:146)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:141)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.commons.util.DefaultAutoCloseableIterator.computeNext(DefaultAutoCloseableIterator.java:38)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:146)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:141)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.commons.util.DefaultAutoCloseableIterator.computeNext(DefaultAutoCloseableIterator.java:38)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:146)2022-06-20 09:57:20 e[44msourcee[0m > at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:141)2022-06-20 09:57:20 e[44msourcee[0m > at java.base/java.util.Iterator.forEachRemaining(Iterator.java:132)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.IntegrationRunner.lambda$produceMessages$2(IntegrationRunner.java:174)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.IntegrationRunner.watchForOrphanThreads(IntegrationRunner.java:230)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.IntegrationRunner.produceMessages(IntegrationRunner.java:173)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.IntegrationRunner.lambda$runInternal$0(IntegrationRunner.java:154)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.sentry.AirbyteSentry.executeWithTracing(AirbyteSentry.java:54)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.sentry.AirbyteSentry.executeWithTracing(AirbyteSentry.java:38)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.IntegrationRunner.runInternal(IntegrationRunner.java:154)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.base.IntegrationRunner.run(IntegrationRunner.java:105)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.source.mysql.MySqlSource.main(MySqlSource.java:211)2022-06-20 09:57:20 e[44msourcee[0m > Caused by: java.lang.RuntimeException: com.mysql.cj.jdbc.exceptions.CommunicationsException: The last packet successfully received from the server was 7,200,066 milliseconds ago. The last packet sent successfully to the server was 7,230,135 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem.2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.db.jdbc.StreamingJdbcDatabase.unsafeQuery(StreamingJdbcDatabase.java:75)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.db.jdbc.JdbcDatabase.unsafeQuery(JdbcDatabase.java:173)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.integrations.source.relationaldb.AbstractRelationalDbSource.lambda$queryTable$0(AbstractRelationalDbSource.java:61)2022-06-20 09:57:20 e[44msourcee[0m > ... 30 more2022-06-20 09:57:20 e[44msourcee[0m > Caused by: com.mysql.cj.jdbc.exceptions.CommunicationsException: The last packet successfully received from the server was 7,200,066 milliseconds ago. The last packet sent successfully to the server was 7,230,135 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem.2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.jdbc.exceptions.SQLError.createCommunicationsException(SQLError.java:174)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:64)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.jdbc.ServerPreparedStatement.serverExecute(ServerPreparedStatement.java:637)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.jdbc.ServerPreparedStatement.executeInternal(ServerPreparedStatement.java:418)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.jdbc.ClientPreparedStatement.executeQuery(ClientPreparedStatement.java:1003)2022-06-20 09:57:20 e[44msourcee[0m > at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:122)2022-06-20 09:57:20 e[44msourcee[0m > at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:122)2022-06-20 09:57:20 e[44msourcee[0m > at io.airbyte.db.jdbc.StreamingJdbcDatabase.unsafeQuery(StreamingJdbcDatabase.java:65)2022-06-20 09:57:20 e[44msourcee[0m > ... 32 more2022-06-20 09:57:20 e[44msourcee[0m > Caused by: com.mysql.cj.exceptions.CJCommunicationsException: The last packet successfully received from the server was 7,200,066 milliseconds ago. The last packet sent successfully to the server was 7,230,135 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem.2022-06-20 09:57:20 e[44msourcee[0m > at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)2022-06-20 09:57:20 e[44msourcee[0m > at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)2022-06-20 09:57:20 e[44msourcee[0m > at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)2022-06-20 09:57:20 e[44msourcee[0m > at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)2022-06-20 09:57:20 e[44msourcee[0m > at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:61)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:105)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:151)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.exceptions.ExceptionFactory.createCommunicationsException(ExceptionFactory.java:167)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.ServerPreparedQuery.readExecuteResult(ServerPreparedQuery.java:419)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.ServerPreparedQuery.serverExecute(ServerPreparedQuery.java:208)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.jdbc.ServerPreparedStatement.serverExecute(ServerPreparedStatement.java:635)2022-06-20 09:57:20 e[44msourcee[0m > ... 37 more2022-06-20 09:57:20 e[44msourcee[0m > Caused by: java.io.EOFException: Can not read response from server. Expected to read 4 bytes, read 0 bytes before connection was unexpectedly lost.2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.FullReadInputStream.readFully(FullReadInputStream.java:67)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.SimplePacketReader.readHeader(SimplePacketReader.java:63)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.SimplePacketReader.readHeader(SimplePacketReader.java:45)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.TimeTrackingPacketReader.readHeader(TimeTrackingPacketReader.java:52)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.TimeTrackingPacketReader.readHeader(TimeTrackingPacketReader.java:41)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.MultiPacketReader.readHeader(MultiPacketReader.java:54)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.MultiPacketReader.readHeader(MultiPacketReader.java:44)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.ResultsetRowReader.read(ResultsetRowReader.java:71)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.ResultsetRowReader.read(ResultsetRowReader.java:42)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.NativeProtocol.read(NativeProtocol.java:1583)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.BinaryResultsetReader.read(BinaryResultsetReader.java:90)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.BinaryResultsetReader.read(BinaryResultsetReader.java:50)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.NativeProtocol.read(NativeProtocol.java:1596)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.protocol.a.NativeProtocol.readAllResults(NativeProtocol.java:1650)2022-06-20 09:57:20 e[44msourcee[0m > at com.mysql.cj.ServerPreparedQuery.readExecuteResult(ServerPreparedQuery.java:389)2022-06-20 09:57:20 e[44msourcee[0m > ... 39 more

The second error is related to normalization:

 Object 'AIRBYTE.DRATA_COM_TENANT._AIRBYTE_RAW_POLICY_VERSION' does not exist or not authorized.

Could you check on Snowflake that raw table are created on your destination? If they are there might a permission error. According to your log it looks like no data is being written to Snowflake, probably because of your MySQL timeout error, this would explain the absence of raw tables on your destination.

Hey there!
I do see some progress here, so after upgrading to the latest version now all the mysql connectors are working properly!
I am still seeing some issues with other connectors but I will close this ticket as I don’t think they are related