morningman commented on code in PR #67899:
URL: https://github.com/apache/doris/pull/67899#discussion_r4432230553
##########
fe/fe-core/src/main/java/org/apache/doris/arrowflight/FlightSqlSchemaHelper.java:
##########
@@ -333,12 +374,21 @@ public void getTables(VectorSchemaRoot vectorSchemaRoot)
throws TException {
for (int dbIndex = 0; dbIndex < getDbsResult.getDbs().size();
dbIndex++) {
String dbName = getDbsResult.getDbs().get(dbIndex);
String catalogName = getDbsResult.isSetCatalogs() ?
getDbsResult.getCatalogs().get(dbIndex) : "";
- TListTableStatusResult listTableStatusResult =
listTableStatus(dbName, catalogName);
+ List<TTableStatus> tables = listTableStatus(dbName,
catalogName).getTables();
Review Comment:
Fixed in 747a1d46660. On a non-master FE in cloud mode, `listTableStatus`
now refreshes an OLAP table's partition versions only when the request needs
`UPDATE_TIME`, the one status column that reads them
(`OlapTable.getUpdateTime()` takes the partitions' visible version time).
GetTables asks for `TABLE_NAME` and `TABLE_TYPE` only, so no GetTables request,
VIEW-only or not, waits on the meta service or is cut short by it.
`information_schema.tables` scans that read `UPDATE_TIME` (projected or in a
predicate) and requests without `required_columns` still refresh as before
(#43451); `information_schema.views` asks for views only and never reaches the
refresh.
`FrontendServiceImplTest#testListTableStatusRefreshesCloudFollowerVersionsOnlyForUpdateTime`
runs the service as a cloud follower whose version RPC fails: with the
name/type projection it returns both the base table and the view without
calling it, and with `UPDATE_TIME` it still calls it. Without the change the
first listing ca
lls it and comes back empty, since the base table's failed refresh ends the
enumeration before either object is added.
`FlightSqlSchemaHelperTableTypesTest` now also checks that GetTables sends
exactly `TABLE_NAME` and `TABLE_TYPE`.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]