maria-discuss team mailing list archive
-
maria-discuss team
-
Mailing list archive
-
Message #05860
MariaDbConnector 1.x -> 2.6, problem updating/inserting Torque objects
-
To:
"maria-discuss@xxxxxxxxxxxxxxxxxxx" <maria-discuss@xxxxxxxxxxxxxxxxxxx>
-
From:
Clemens Wyss - MySign AG <clemens.wyss@xxxxxxxxx>
-
Date:
Tue, 21 Jul 2020 04:39:16 +0000
-
Accept-language:
de-CH, en-US
-
Arc-authentication-results:
i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mysign.ch; dmarc=pass action=none header.from=mysign.ch; dkim=pass header.d=mysign.ch; arc=none
-
Arc-message-signature:
i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xfZEc3lZ7w5v/xpQs8F8Xk5sOTTgaI/MzaoFgzwl3iQ=; b=Ys0K1M+5XE2Lyr/dVtggO26hrQKjJ9b2VEoy7XurT5NBJB5mWwOFc+nVT5qQUR05QU3lk3mhLnuUu0lvXBv6c8UN3IToPqT9hnsR4YydM6wf4UE1zWmaHUwLOmqWrbaEo9ts6N/KMIv5aCKt0haAtAAfhe1B7deAdIlH2E46sazXE85Sk0qrz0jr5vhGZElprW8GDPaNPSOkf4u5TsMaFPYwIATkrdNT0t5goVEp5e/EOLkP7gFpFAW18i4ZoI7cFza2t10z/acit7h1gAA4HZJL8LnVhsu5tkZKYPxoea13dTfKy4T/H6sOIM81Uq1IQWhDlSNCdIzjo1Gf3sB7pA==
-
Arc-seal:
i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jSCAA47n9aaQDXtLIdofaR4oNDfRCeM+BIZyQXvaBNSoJoaLjhENzRL8dG7s0aptKcoGioNh1n2YIQx0CH4Off8PXkURI3g/139CYEsrj5xTtXKwD2qdssi5ir5qedj/nwI4f1/5PxnQZJTsEZZUSgj53m0R5ssZYgzC0X8aG34ehc+vcO4B1mVK6F/EhV7+mQituz2/TZntujjHs9kDlpd1lumCQ3kxkhPI/bYXZ32Nrh3/MJvUwFNAYBObcoo8pQLQJBiwAiYuoZ93+nVACyEzU56lY9ufQftH+pcsZBPE3lo/pTLUvX1Nc9bVe6ZuHy1kRBHJvz9LVgHGRD4LZg==
-
Authentication-results:
lists.launchpad.net; dkim=none (message not signed) header.d=none;lists.launchpad.net; dmarc=none action=none header.from=mysign.ch;
-
Thread-index:
AdZfGOkB1R0lSrcARcCFQG25/EW0Ng==
-
Thread-topic:
MariaDbConnector 1.x -> 2.6, problem updating/inserting Torque objects
We are about to update MariaDbConnector from 1.x to 2.6. Having a lot of legacy code we (still) make use of Apache Torque (and Village 1.5.3) "on top" of the connector. Option(s) we had to activate so far was/is:
useOldAliasMetadataBehavior=true
Problem:
Updating/inserting (Torque objects) Records does not work anymore with the new connector.
Debugging reveals that it is due to the resultSetConcurrency being CONCUR_READ_ONLY when trying to update/insert a Record. Torque seems to initially select the Record to be updated before effetively updating. Hence the Schema "attached" to the record has CONCUR_READ_ONLY
>record.schema().column(i).readOnly() // true ☹
I could patch org.mariadb.jdbc.internal.com.read.resultset. SelectResultSet# getMetaData to return
> new MariaDbResultSetMetaData(columnsInformation, options, forceAlias, false )
instead of
>new MariaDbResultSetMetaData(columnsInformation, options, forceAlias, true )
but that doesn't really feel "right" 😉
I'd appreciate any hint/advice regarding this issue
Thx
Clemens
Follow ups