This is an automated email from the ASF dual-hosted git repository.

jonvex pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/hudi.git


The following commit(s) were added to refs/heads/asf-site by this push:
     new 45d37ddc407 [HUDI-7482] Update schema evolution docs to explicitly 
state allowed type promotions (#10833)
45d37ddc407 is described below

commit 45d37ddc407f20c3de0739c2dbf5c277b5902f48
Author: Jon Vexler <[email protected]>
AuthorDate: Thu Mar 7 18:09:46 2024 -0800

    [HUDI-7482] Update schema evolution docs to explicitly state allowed type 
promotions (#10833)
    
    * update schema evolution to be more clear
    
    * add arrows to the table
    
    ---------
    
    Co-authored-by: Jonathan Vexler <=>
---
 website/docs/schema_evolution.md                   | 24 +++++++++++-----------
 .../version-0.14.1/schema_evolution.md             | 24 +++++++++++-----------
 2 files changed, 24 insertions(+), 24 deletions(-)

diff --git a/website/docs/schema_evolution.md b/website/docs/schema_evolution.md
index e8cfc53bff2..68ad442e434 100755
--- a/website/docs/schema_evolution.md
+++ b/website/docs/schema_evolution.md
@@ -42,18 +42,18 @@ For this we need to enable the following config
 | Demote datatype for a nested field                              | No  | No  
|                                                                               
                                                                                
                                                                                
                                                |
 | Demote datatype for a complex type (value of map or array)      | No  | No  
|                                                                               
                                                                                
                                                                                
                                                |
 
-###Type Promotions
-
-The incoming schema will automatically have types promoted to match the table 
schema
-
-| Incoming Schema \ Table Schema  | int   | long  | float  | double | string  
| bytes   |
-|---------------------------------|-------|-------|--------|--------|---------|---------|
-| int                             |   Y   |   Y   |    Y   |    Y   |    Y    
|   N     |
-| long                            |   N   |   Y   |    Y   |    Y   |    Y    
|   N     | 
-| float                           |   N   |   N   |    Y   |    Y   |    Y    
|   N     |  
-| double                          |   N   |   N   |    N   |    Y   |    Y    
|   N     |  
-| string                          |   N   |   N   |    N   |    N   |    Y    
|   Y     | 
-| bytes                           |   N   |   N   |    N   |    N   |    Y    
|   Y     |
+### Type Promotions
+
+This chart shows what the table schema will be when an incoming column type 
has changed (X means that it is not allowed):
+
+| Incoming Schema &#8595; \ Table Schema &#8594; | int    | long   | float  | 
double | string | bytes |
+|------------------------------------------------|--------|--------|--------|--------|--------|-------|
+| int                                            | int    | long   | float  | 
double | string | X     |
+| long                                           | long   | long   | float  | 
double | string | X     | 
+| float                                          | float  | float  | float  | 
double | string | X     |  
+| double                                         | double | double | double | 
double | string | X     |  
+| string                                         | string | string | string | 
string | string | bytes | 
+| bytes                                          | X      | X      | X      | 
X      | string | bytes |
 
 ## Schema Evolution on read
 
diff --git a/website/versioned_docs/version-0.14.1/schema_evolution.md 
b/website/versioned_docs/version-0.14.1/schema_evolution.md
index e8cfc53bff2..68ad442e434 100755
--- a/website/versioned_docs/version-0.14.1/schema_evolution.md
+++ b/website/versioned_docs/version-0.14.1/schema_evolution.md
@@ -42,18 +42,18 @@ For this we need to enable the following config
 | Demote datatype for a nested field                              | No  | No  
|                                                                               
                                                                                
                                                                                
                                                |
 | Demote datatype for a complex type (value of map or array)      | No  | No  
|                                                                               
                                                                                
                                                                                
                                                |
 
-###Type Promotions
-
-The incoming schema will automatically have types promoted to match the table 
schema
-
-| Incoming Schema \ Table Schema  | int   | long  | float  | double | string  
| bytes   |
-|---------------------------------|-------|-------|--------|--------|---------|---------|
-| int                             |   Y   |   Y   |    Y   |    Y   |    Y    
|   N     |
-| long                            |   N   |   Y   |    Y   |    Y   |    Y    
|   N     | 
-| float                           |   N   |   N   |    Y   |    Y   |    Y    
|   N     |  
-| double                          |   N   |   N   |    N   |    Y   |    Y    
|   N     |  
-| string                          |   N   |   N   |    N   |    N   |    Y    
|   Y     | 
-| bytes                           |   N   |   N   |    N   |    N   |    Y    
|   Y     |
+### Type Promotions
+
+This chart shows what the table schema will be when an incoming column type 
has changed (X means that it is not allowed):
+
+| Incoming Schema &#8595; \ Table Schema &#8594; | int    | long   | float  | 
double | string | bytes |
+|------------------------------------------------|--------|--------|--------|--------|--------|-------|
+| int                                            | int    | long   | float  | 
double | string | X     |
+| long                                           | long   | long   | float  | 
double | string | X     | 
+| float                                          | float  | float  | float  | 
double | string | X     |  
+| double                                         | double | double | double | 
double | string | X     |  
+| string                                         | string | string | string | 
string | string | bytes | 
+| bytes                                          | X      | X      | X      | 
X      | string | bytes |
 
 ## Schema Evolution on read
 

Reply via email to