yuqi1129 opened a new issue, #13590:
URL: https://github.com/apache/gravitino/issues/13590

   ## Version
   
   main branch, `8e9ca0009d68dbf9edb5e313d3d51688b9c4cff1`; relational MySQL 
entity store, jdbc-mysql catalog, authorization enabled, Java 17.
   
   ## Describe what's wrong
   
   An unchanged table with eight nullable columns causes every `loadTable` call 
to update the Gravitino table/column versions and commit a transaction. Reads 
become metadata writes, increase change-log traffic, and accumulate column 
history.
   
   In the first single-client measured window, 700 successful GETs plus 
warmup/diagnostics corresponded to 820 metadata commits and column-version 
insert statements. There was no concurrent ALTER or external schema change. 
This is not merely the one-time normalization/import on first load. A later 
isolated ten-GET check, with identical response columns and physical SHOW 
CREATE TABLE output, increased current_version from 12994 to 13004, 
column-history rows from 103952 to 104032, and change-log rows from 137893 to 
137903.
   
   ## Error message and/or stacktrace
   
   Requests returned 200. The failure is unnecessary persistent mutation and 
degraded read throughput. The SQL digest showed repeated column-history 
SELECTs, column-version INSERTs, table updates, and COMMIT in a read-only 
workload.
   
   ## How to reproduce
   
   1. Configure an isolated jdbc-mysql catalog and relational entity store on 
main.
   2. Create a table with nullable integer/varchar columns, warm it through 
loadTable, then record table current_version and column-version row count.
   3. Repeatedly GET the same table without changing its definition. Record the 
versions and metadata SQL digests again.
   4. Compare connector-snapshot defaults with deserialized stored defaults. 
Connector snapshots use `LiteralDTO`; `POConverters.fromColumnPO` converts 
stored function args back to API literals. `isSameColumn` compares the 
different implementations directly.
   
   ## Additional context
   
   The observed source path is `ConnectorObjectSnapshot.detach` -> 
TableDTO/ColumnDTO -> `TableOperationDispatcher.isSameColumn` -> 
`updateColumnsIfNecessaryWhenLoad`. The default-value representations should be 
compared canonically. The equality probe confirmed LiteralDTO versus 
Literals$LiteralImpl compares unequal, while canonical DTO comparison is equal. 
With the same databases, a diagnostic null-default comparison override improved 
32-client GET throughput from about 59 to 608 requests/s (three-run medians); 
reverting to main restored about 57 requests/s. This override is a causal probe 
for these fixtures, not a general production fix.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to