[ 
https://issues.apache.org/jira/browse/NIFI-3728?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15982499#comment-15982499
 ] 

ASF GitHub Bot commented on NIFI-3728:
--------------------------------------

Github user ijokarumawak commented on a diff in the pull request:

    https://github.com/apache/nifi/pull/1690#discussion_r113114162
  
    --- Diff: 
nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java
 ---
    @@ -263,6 +263,17 @@
                 .addValidator(StandardValidators.BOOLEAN_VALIDATOR)
                 .build();
     
    +    public static final PropertyDescriptor INCLUDE_SCHEMA_CHANGES = new 
PropertyDescriptor.Builder()
    +            .name("capture-change-mysql-include-schema-changes")
    +            .displayName("Include Schema Change Events")
    +            .description("Specifies whether to emit events corresponding 
to a schema change event (ALTER TABLE, e.g.) in the binary log. Set to true if 
the schema change events are "
    +                    + "desired/necessary in the downstream flow, otherwise 
set to false, which suppresses generation of these events and can increase flow 
performance.")
    --- End diff --
    
    I personally think "Include DDL (Data Definition Language) Events" would be 
more preferable for this property name. Specifically `truncate` doesn't change 
schema. Users may assume wrongly that `truncate table` is not included.
    
    When we say DDL, it includes `truncate` 
[generally](https://en.wikipedia.org/wiki/Data_definition_language).


> CaptureChangeMySQL to capture truncate table statement
> ------------------------------------------------------
>
>                 Key: NIFI-3728
>                 URL: https://issues.apache.org/jira/browse/NIFI-3728
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Extensions
>    Affects Versions: 1.2.0
>            Reporter: Koji Kawamura
>            Assignee: Matt Burgess
>             Fix For: 1.2.0
>
>
> CaptureChangeMySQL has several specific queries to capture, such as 'alter 
> table', 'create table' and 'drop table' ... etc. However, it currently does 
> not capture 'truncate table' and it should be added.
> Also, this maybe an off topic but I think these [DDL | 
> https://en.wikipedia.org/wiki/Data_definition_language] statements can be 
> dangerous and some use-cases may require human intervention before executing 
> such, instead of fully automating with PutDatabaseRecord. It will be useful 
> if CaptureChangeMySQL has a 'Capture DDL statements' property.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to