Harshith (Airbyte)
Could not connect with provided configuration. Error: Could not query the variable binlog_row_image
Any help would be appreciated as I have zero experience with MySQL.Nathan Atkins
07/15/2021, 8:10 PMshow variables where Variable_name = 'binlog_row_image'
user
07/15/2021, 8:44 PMMilad saidi
07/16/2021, 5:17 PMbinlog_row_image
was configured to value FULL. @Subodh (Airbyte) any idea here?Jaime Farres
07/17/2021, 4:29 PMcheckOperations.add(database -> {
List<String> image = database.resultSetQuery(connection -> {
final String sql = "show variables where Variable_name = 'binlog_row_image'";
return connection.createStatement().executeQuery(sql);
}, resultSet -> resultSet.getString("Value")).collect(toList());
if (image.size() != 1) {
throw new RuntimeException("Could not query the variable binlog_row_image");
}
String binlogRowImage = image.get(0);
if (!binlogRowImage.equalsIgnoreCase("FULL")) {
throw new RuntimeException("The variable binlog_row_image should be set to FULL, but it is : " + binlogRowImage);
}
});
While the MySQL documentation for show variables
says that the were clause should work it doesn't seem to and we get 500+ varaibles (name, value) rows back. It looks like the code is looking for a single row and then selecting the value here resultSet.getString("Value")).collect(toList())
If I change the query to show variables like 'binlog_row_image'
I get just one row back and I think the code would work correctly from there.
The documentation for both 5.7 and 8 say that the where clause should work, so I don't know what is going on there.
I guess one option would be to change the code that gets the value out of the list to find the row with Variable_name == "binlog_row_image" and then get the value. Then if the where clause worked or not it would find the value "FULL" and move on.user
07/17/2021, 5:16 PMshow
command in the extractor to use a like
instead of where
or deal with the possibility of getting a list of variables back?
It will be a bit before I can carve out the time to refresh on java and how to build, and test the changes to make a PR.user
07/19/2021, 10:54 AMwhere
clause works with other managed services like Amazon Aurora/RDS. We can change the query to use like
instead of where
clause but what if that change doesn't work on other managed versions (need to check this), can you once reach out to the service providers and ask them why is the query not working for their mysql but works for generic mysql and other hosted versions such as Amazon Aurora? I dont have experience with PureCloud
vendoruser
07/19/2021, 2:34 PMlike
version on the three versions I mention above and it works fine. Agree that this isn’t really something we should have to deal with at the Airbyte level, but we all know that this space is full of weird one off issues.
Let me know if you get the change made and I can test it with PureCloud.user
07/21/2021, 4:25 PMuser
07/21/2021, 4:45 PM