From a7b90230ef6cad0deb3f4b095781f5af5e751680 Mon Sep 17 00:00:00 2001 From: jto Date: Wed, 16 Oct 2024 21:01:37 +0200 Subject: [PATCH] [Flink] licence --- .../beam/runners/flink/adapter/FlinkKey.java | 17 +++++++++++++ .../runners/flink/adapter/FlinkKeyTest.java | 25 ++++++++++++++----- 2 files changed, 36 insertions(+), 6 deletions(-) diff --git a/runners/flink/src/main/java/org/apache/beam/runners/flink/adapter/FlinkKey.java b/runners/flink/src/main/java/org/apache/beam/runners/flink/adapter/FlinkKey.java index 637b4cb3696e..cf3871f68a1c 100644 --- a/runners/flink/src/main/java/org/apache/beam/runners/flink/adapter/FlinkKey.java +++ b/runners/flink/src/main/java/org/apache/beam/runners/flink/adapter/FlinkKey.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.apache.beam.runners.flink.adapter; import org.apache.beam.runners.flink.translation.types.CoderTypeSerializer; diff --git a/runners/flink/src/test/java/org/apache/beam/runners/flink/adapter/FlinkKeyTest.java b/runners/flink/src/test/java/org/apache/beam/runners/flink/adapter/FlinkKeyTest.java index 97f9228c8499..b0fadc0c07eb 100644 --- a/runners/flink/src/test/java/org/apache/beam/runners/flink/adapter/FlinkKeyTest.java +++ b/runners/flink/src/test/java/org/apache/beam/runners/flink/adapter/FlinkKeyTest.java @@ -1,26 +1,39 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.apache.beam.runners.flink.adapter; -import com.google.common.collect.Range; import org.apache.beam.sdk.coders.VarIntCoder; import org.apache.flink.api.common.typeinfo.TypeInformation; -import org.apache.flink.api.common.typeutils.TypeSerializer; import org.apache.flink.api.java.tuple.Tuple2; import org.apache.flink.api.java.typeutils.GenericTypeInfo; import org.apache.flink.api.java.typeutils.TypeExtractor; import org.apache.flink.api.java.typeutils.ValueTypeInfo; import org.apache.flink.util.MathUtils; -import org.hamcrest.Matchers; -import org.hamcrest.core.IsEqual; import org.hamcrest.core.IsInstanceOf; import org.junit.Test; + import java.nio.ByteBuffer; import java.nio.charset.StandardCharsets; import java.util.Set; import java.util.stream.Collectors; import java.util.stream.IntStream; -import java.util.stream.Stream; -import static org.hamcrest.MatcherAssert.*; +import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.equalTo; import static org.hamcrest.Matchers.greaterThan; import static org.hamcrest.Matchers.not;