wangxlong opened a new pull request #13972:
URL: https://github.com/apache/flink/pull/13972


   … null keys
   
   ## What is the purpose of the change
   
   Fix JSON format fails to serialize map value with null keys
   
   ## Brief change log
   
   1.  Add map-null-key.mode and map-null-key.literal
       to `JsonRowDeserializationSchema`, `MaxwellJsonSerializationSchema` , 
`DebeziumJsonSerializationSchema` and `CanalJsonSerializationSchema`.
   2. Add decoding format options validator and decoding format options 
validator to `CanalJsonFormatFactory`, `DebeziumJsonFormatFactory` and 
`MaxwellJsonFormatFactory`.
   3.  Fix `GenericMapData`  hash code NPE when map value with null keys .
   4. Update documents for `Canal`,  `Debezium` and `Json`.
        `Maxwell` document is missing, creating issue 
[FLINK-20034](https://issues.apache.org/jira/browse/FLINK-20034) to track it.
   
   ## Verifying this change
   
   This change added tests and can be verified as follows:
   1.  JsonRowDataSerDeSchemaTest#testSerializationMapNullKey to ensure options 
is correct when serializing.
   2. JsonFormatFactoryTest#testInvalidOptionForMapNullKeyMode ensure options 
validate correctly.
   3. JsonFormatFactoryTest#testLowerCaseOptionForMapNullKeyMode ensure options 
are case insensitive.
   4. Other Format validator tests.
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API, i.e., is any changed class annotated with 
`@Public(Evolving)`: (no)
     - The serializers: (no / don't know)
     - The runtime per-record code paths (performance sensitive): (no / don't 
know)
     - Anything that affects deployment or recovery: JobManager (and its 
components), Checkpointing, Kubernetes/Yarn/Mesos, ZooKeeper: (no / don't know)
     - The S3 file system connector: (no / don't know)
   
   ## Documentation
   
     - Does this pull request introduce a new feature? (no)
     - If yes, how is the feature documented? (not applicable / docs / JavaDocs 
/ not documented)
   


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

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


Reply via email to