You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "alexeykudinkin (via GitHub)" <gi...@apache.org> on 2023/01/31 05:59:41 UTC

[GitHub] [hudi] alexeykudinkin opened a new pull request, #7802: [DNM] Disable default Avro schema validation

alexeykudinkin opened a new pull request, #7802:
URL: https://github.com/apache/hudi/pull/7802

   ### Change Logs
   
   As we discussed earlier today, disabling executing Avro schema validation by default.
   
   ### Impact
   
   No impact
   
   ### Risk level (write none, low medium or high below)
   
   Low
   
   ### Documentation Update
   
   _Describe any necessary documentation update if there is any new feature, config, or user-facing change_
   
   - _The config description must be updated if new configs are added or the default value of the configs are changed_
   - _Any new feature or user-facing change requires updating the Hudi website. Please create a Jira ticket, attach the
     ticket number here and follow the [instruction](https://hudi.apache.org/contribute/developer-setup#website) to make
     changes to the website._
   
   ### Contributor's checklist
   
   - [ ] Read through [contributor's guide](https://hudi.apache.org/contribute/how-to-contribute)
   - [ ] Change Logs and Impact were stated clearly
   - [ ] Adequate tests were added if applicable
   - [ ] CI passed
   


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] hudi-bot commented on pull request #7802: [DNM] Disable default Avro schema validation

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #7802:
URL: https://github.com/apache/hudi/pull/7802#issuecomment-1411207044

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805",
       "triggerID" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "triggerType" : "PUSH"
     }, {
       "hash" : "9c39a3a58b9407bdbccdb3765fee62ced4674462",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14824",
       "triggerID" : "9c39a3a58b9407bdbccdb3765fee62ced4674462",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 88d82b6c21f0c4d81409dae0f5420cea116954ba Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805) 
   * 9c39a3a58b9407bdbccdb3765fee62ced4674462 Azure: [PENDING](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14824) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] hudi-bot commented on pull request #7802: [DNM] Disable default Avro schema validation

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #7802:
URL: https://github.com/apache/hudi/pull/7802#issuecomment-1411200687

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805",
       "triggerID" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "triggerType" : "PUSH"
     }, {
       "hash" : "9c39a3a58b9407bdbccdb3765fee62ced4674462",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "9c39a3a58b9407bdbccdb3765fee62ced4674462",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 88d82b6c21f0c4d81409dae0f5420cea116954ba Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805) 
   * 9c39a3a58b9407bdbccdb3765fee62ced4674462 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] hudi-bot commented on pull request #7802: [DNM] Disable default Avro schema validation

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #7802:
URL: https://github.com/apache/hudi/pull/7802#issuecomment-1411338697

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805",
       "triggerID" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "triggerType" : "PUSH"
     }, {
       "hash" : "9c39a3a58b9407bdbccdb3765fee62ced4674462",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14824",
       "triggerID" : "9c39a3a58b9407bdbccdb3765fee62ced4674462",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 9c39a3a58b9407bdbccdb3765fee62ced4674462 Azure: [SUCCESS](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14824) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] hudi-bot commented on pull request #7802: [DNM] Disable default Avro schema validation

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #7802:
URL: https://github.com/apache/hudi/pull/7802#issuecomment-1410157230

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805",
       "triggerID" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 88d82b6c21f0c4d81409dae0f5420cea116954ba Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] hudi-bot commented on pull request #7802: [DNM] Disable default Avro schema validation

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #7802:
URL: https://github.com/apache/hudi/pull/7802#issuecomment-1409850470

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805",
       "triggerID" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 88d82b6c21f0c4d81409dae0f5420cea116954ba Azure: [PENDING](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=14805) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] alexeykudinkin commented on a diff in pull request #7802: [DNM] Disable default Avro schema validation

Posted by "alexeykudinkin (via GitHub)" <gi...@apache.org>.
alexeykudinkin commented on code in PR #7802:
URL: https://github.com/apache/hudi/pull/7802#discussion_r1092558919


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/hudi/HoodieSparkSqlWriter.scala:
##########
@@ -518,14 +518,17 @@ object HoodieSparkSqlWriter {
   }
 
   def addSchemaEvolutionParameters(parameters: Map[String, String], internalSchemaOpt: Option[InternalSchema], writeSchemaOpt: Option[Schema] = None): Map[String, String] = {
-    val schemaEvolutionEnable = if (internalSchemaOpt.isDefined) "true" else "false"
+    val schemaEvolutionEnabled = if (internalSchemaOpt.isDefined) "true" else "false"
+    val schemaReconciliationEnabled = parameters.getOrDefault(DataSourceWriteOptions.RECONCILE_SCHEMA.key(),
+      DataSourceWriteOptions.RECONCILE_SCHEMA.defaultValue().toString).toBoolean
 
-    val schemaValidateEnable = if (schemaEvolutionEnable.toBoolean && parameters.getOrDefault(DataSourceWriteOptions.RECONCILE_SCHEMA.key(), "false").toBoolean) {
-      // force disable schema validate, now we support schema evolution, no need to do validate
-      "false"
+    // Force disable schema validate, now we support schema evolution, no need to do validate
+    val schemaValidationEnabledOpt = if (schemaEvolutionEnabled.toBoolean && schemaReconciliationEnabled) {
+      Some(false)
     } else  {
-      parameters.getOrDefault(HoodieWriteConfig.AVRO_SCHEMA_VALIDATE_ENABLE.key(), "true")

Review Comment:
   This is the reason we didn't see any tests failing -- we're overriding it to always be true (unless specified)



-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] alexeykudinkin commented on pull request #7802: [DNM] Disable default Avro schema validation

Posted by "alexeykudinkin (via GitHub)" <gi...@apache.org>.
alexeykudinkin commented on PR #7802:
URL: https://github.com/apache/hudi/pull/7802#issuecomment-1410957574

   CI is green:
   
   <img width="1636" alt="Screenshot 2023-01-31 at 11 37 25 AM" src="https://user-images.githubusercontent.com/428277/215864603-54ed9f56-11a3-409e-a4e7-73b77795878e.png">
   
   https://dev.azure.com/apache-hudi-ci-org/apache-hudi-ci/_build/results?buildId=14805&view=results
   


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] yihua merged pull request #7802: [0.13.0 Only] Disable default Avro schema validation

Posted by "yihua (via GitHub)" <gi...@apache.org>.
yihua merged PR #7802:
URL: https://github.com/apache/hudi/pull/7802


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [hudi] hudi-bot commented on pull request #7802: [DNM] Disable default Avro schema validation

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #7802:
URL: https://github.com/apache/hudi/pull/7802#issuecomment-1409843991

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "88d82b6c21f0c4d81409dae0f5420cea116954ba",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 88d82b6c21f0c4d81409dae0f5420cea116954ba UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org