flink-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ches...@apache.org
Subject [4/5] flink git commit: [FLINK-6822] Activate checkstyle for runtime/plugable
Date Sat, 08 Jul 2017 13:48:29 GMT
[FLINK-6822] Activate checkstyle for runtime/plugable

This closes #4064.


Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/98eb2cff
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/98eb2cff
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/98eb2cff

Branch: refs/heads/master
Commit: 98eb2cff32c84b9a4f5c3136652040438f4cdd5d
Parents: 73ab317
Author: zentol <chesnay@apache.org>
Authored: Sat Jun 3 08:26:34 2017 +0200
Committer: zentol <chesnay@apache.org>
Committed: Sat Jul 8 09:00:23 2017 +0200

----------------------------------------------------------------------
 flink-runtime/pom.xml                             |  1 -
 .../runtime/plugable/DeserializationDelegate.java |  9 ++++++++-
 .../NonReusingDeserializationDelegate.java        |  8 ++++----
 .../plugable/ReusingDeserializationDelegate.java  | 14 +++++++-------
 .../runtime/plugable/SerializationDelegate.java   | 18 ++++++++----------
 5 files changed, 27 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/98eb2cff/flink-runtime/pom.xml
----------------------------------------------------------------------
diff --git a/flink-runtime/pom.xml b/flink-runtime/pom.xml
index dbec662..8ae424c 100644
--- a/flink-runtime/pom.xml
+++ b/flink-runtime/pom.xml
@@ -444,7 +444,6 @@ under the License.
 						**/runtime/messages/**,
 						**/runtime/minicluster/**,
 						**/runtime/operators/**,
-						**/runtime/plugable/**,
 						**/runtime/query/**,
 						**/runtime/registration/**,
 						**/runtime/resourcemanager/**,

http://git-wip-us.apache.org/repos/asf/flink/blob/98eb2cff/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/DeserializationDelegate.java
----------------------------------------------------------------------
diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/DeserializationDelegate.java
b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/DeserializationDelegate.java
index fe941a4..3494276 100644
--- a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/DeserializationDelegate.java
+++ b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/DeserializationDelegate.java
@@ -15,12 +15,19 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
+
 package org.apache.flink.runtime.plugable;
 
 import org.apache.flink.core.io.IOReadableWritable;
 
+/**
+ * The deserialization delegate is used during deserialization to read an arbitrary element
as if it implements
+ * {@link IOReadableWritable}, with the help of a type serializer.
+ *
+ * @param <T> The type to be represented as an IOReadableWritable.
+ */
 public interface DeserializationDelegate<T> extends IOReadableWritable {
-	
+
 	void setInstance(T instance);
 
 	T getInstance();

http://git-wip-us.apache.org/repos/asf/flink/blob/98eb2cff/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/NonReusingDeserializationDelegate.java
----------------------------------------------------------------------
diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/NonReusingDeserializationDelegate.java
b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/NonReusingDeserializationDelegate.java
index 859f354..820bc6c 100644
--- a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/NonReusingDeserializationDelegate.java
+++ b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/NonReusingDeserializationDelegate.java
@@ -16,7 +16,6 @@
  * limitations under the License.
  */
 
-
 package org.apache.flink.runtime.plugable;
 
 import org.apache.flink.api.common.typeutils.TypeSerializer;
@@ -25,18 +24,19 @@ import org.apache.flink.core.memory.DataOutputView;
 
 import java.io.IOException;
 
-
+/**
+ * A {@link DeserializationDelegate} that always creates a new instance upon deserialization.
+ */
 public class NonReusingDeserializationDelegate<T> implements DeserializationDelegate<T>
{
 
 	private T instance;
 
 	private final TypeSerializer<T> serializer;
 
-
 	public NonReusingDeserializationDelegate(TypeSerializer<T> serializer) {
 		this.serializer = serializer;
 	}
-	
+
 	public void setInstance(T instance) {
 		this.instance = instance;
 	}

http://git-wip-us.apache.org/repos/asf/flink/blob/98eb2cff/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/ReusingDeserializationDelegate.java
----------------------------------------------------------------------
diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/ReusingDeserializationDelegate.java
b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/ReusingDeserializationDelegate.java
index f3c254b..ffdea7c 100644
--- a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/ReusingDeserializationDelegate.java
+++ b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/ReusingDeserializationDelegate.java
@@ -16,27 +16,27 @@
  * limitations under the License.
  */
 
-
 package org.apache.flink.runtime.plugable;
 
-import java.io.IOException;
-
 import org.apache.flink.api.common.typeutils.TypeSerializer;
 import org.apache.flink.core.memory.DataInputView;
 import org.apache.flink.core.memory.DataOutputView;
 
+import java.io.IOException;
 
+/**
+ * A {@link DeserializationDelegate} that reuses an existing instance upon deserialization.
+ */
 public class ReusingDeserializationDelegate<T> implements DeserializationDelegate<T>
{
-	
+
 	private T instance;
-	
+
 	private final TypeSerializer<T> serializer;
-	
 
 	public ReusingDeserializationDelegate(TypeSerializer<T> serializer) {
 		this.serializer = serializer;
 	}
-	
+
 	@Override
 	public void setInstance(T instance) {
 		this.instance = instance;

http://git-wip-us.apache.org/repos/asf/flink/blob/98eb2cff/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/SerializationDelegate.java
----------------------------------------------------------------------
diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/SerializationDelegate.java
b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/SerializationDelegate.java
index 91b6dd9..c0a14c2 100644
--- a/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/SerializationDelegate.java
+++ b/flink-runtime/src/main/java/org/apache/flink/runtime/plugable/SerializationDelegate.java
@@ -16,41 +16,39 @@
  * limitations under the License.
  */
 
-
 package org.apache.flink.runtime.plugable;
 
-import java.io.IOException;
-
 import org.apache.flink.api.common.typeutils.TypeSerializer;
 import org.apache.flink.core.io.IOReadableWritable;
 import org.apache.flink.core.memory.DataInputView;
 import org.apache.flink.core.memory.DataOutputView;
 
+import java.io.IOException;
+
 /**
  * The serialization delegate exposes an arbitrary element as a {@link IOReadableWritable}
for
  * serialization, with the help of a type serializer.
- * 
+ *
  * @param <T> The type to be represented as an IOReadableWritable.
  */
 public class SerializationDelegate<T> implements IOReadableWritable {
-	
+
 	private T instance;
-	
+
 	private final TypeSerializer<T> serializer;
-	
 
 	public SerializationDelegate(TypeSerializer<T> serializer) {
 		this.serializer = serializer;
 	}
-	
+
 	public void setInstance(T instance) {
 		this.instance = instance;
 	}
-	
+
 	public T getInstance() {
 		return this.instance;
 	}
-	
+
 	@Override
 	public void write(DataOutputView out) throws IOException {
 		this.serializer.serialize(this.instance, out);


Mime
View raw message