alexeykudinkin commented on code in PR #7301:
URL: https://github.com/apache/hudi/pull/7301#discussion_r1042677431


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/hudi/HoodieBaseRelation.scala:
##########
@@ -140,18 +140,14 @@ abstract class HoodieBaseRelation(val sqlContext: 
SQLContext,
    */
   protected lazy val (tableAvroSchema: Schema, internalSchemaOpt: 
Option[InternalSchema]) = {
     val schemaResolver = new TableSchemaResolver(metaClient)
-    val internalSchemaOpt = if (!isSchemaEvolutionEnabled) {
-      None
-    } else {
-      Try {
-        
specifiedQueryTimestamp.map(schemaResolver.getTableInternalSchemaFromCommitMetadata)
-          .getOrElse(schemaResolver.getTableInternalSchemaFromCommitMetadata)
-      } match {
-        case Success(internalSchemaOpt) => toScalaOption(internalSchemaOpt)
-        case Failure(e) =>
-          logWarning("Failed to fetch internal-schema from the table", e)
-          None
-      }
+    val internalSchemaOpt = Try {
+      
specifiedQueryTimestamp.map(schemaResolver.getTableInternalSchemaFromCommitMetadata)

Review Comment:
   @fuyun2024 unfortunately we can't do that -- @nsivabalan is actually 
currently working on the opposite change that will make sure that Schema 
Evolution is guarded behind the flag such that we can force it disabled if 
needs to be (even though it might not be safe for some use-cases, there are 
cases when this still is necessary)



-- 
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