flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tillrohrmann <...@git.apache.org>
Subject [GitHub] flink pull request #3375: [FLINK-5845] [cep] Unify keyed and non-keyed opera...
Date Wed, 22 Feb 2017 13:39:11 GMT
Github user tillrohrmann commented on a diff in the pull request:

    --- Diff: flink-libraries/flink-cep/src/main/java/org/apache/flink/cep/operator/AbstractKeyedCEPPatternOperator.java
    @@ -100,27 +119,21 @@ public void open() throws Exception {
     		if (nfaOperatorState == null) {
     			nfaOperatorState = getPartitionedState(
    -					new ValueStateDescriptor<NFA<IN>>(
    -						new NFA.Serializer<IN>()));
    +				new ValueStateDescriptor<>(NFA_OPERATOR_STATE_NAME, new NFA.Serializer<IN>()));
     		TypeSerializer<StreamRecord<IN>> streamRecordSerializer =
    -				(TypeSerializer) new StreamElementSerializer<>(getInputSerializer());
    +			(TypeSerializer) new StreamElementSerializer<>(getInputSerializer());
     		if (priorityQueueOperatorState == null) {
     			priorityQueueOperatorState = getPartitionedState(
    -					new ValueStateDescriptor<>(
    -						new PriorityQueueSerializer<>(
    -								streamRecordSerializer,
    -								new PriorityQueueStreamRecordFactory<IN>())));
    +				new ValueStateDescriptor<>(PRIORITY_QUEUE_STATE_NAME,
    +					new PriorityQueueSerializer<>(streamRecordSerializer, new PriorityQueueStreamRecordFactory<IN>())));
    --- End diff --
    If doing reformatting changes then please try to not change a consistent style. When breaking
long parameter lists, imo, every parameter should be on a separate line and indented identically.
This is not the case with `PRIORITY_QUEUE_STATE_NAME`.

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.

View raw message