Repository: reef
Updated Branches:
  refs/heads/master 7cc271780 -> 57e9f4db7


[REEF-1570] In-line AvroUtils and remove Avro dependency from O.A.R.Utilities

This moves AvroUtils from O.A.R.Utilities and in-lines its usage into 
O.A.R.Naming.Utilities
and O.A.R.Examples.MachineLearning.KMeans.codecs. Also, the Avro dependency from
O.A.R.Utilities is removed while an Avro dependency has been added to 
O.A.R.Examples.
The current usages have been tagged with a TemporaryFixAttribute so that we can 
fix it
appropriately when we are ready to do so.

JIRA:
    [REEF-1570](https://issues.apache.org/jira/browse/REEF-1570)

Pull Request:
    Closes #1127


Project: http://git-wip-us.apache.org/repos/asf/reef/repo
Commit: http://git-wip-us.apache.org/repos/asf/reef/commit/57e9f4db
Tree: http://git-wip-us.apache.org/repos/asf/reef/tree/57e9f4db
Diff: http://git-wip-us.apache.org/repos/asf/reef/diff/57e9f4db

Branch: refs/heads/master
Commit: 57e9f4db77052622746abf6adadbce4f47459bcc
Parents: 7cc2717
Author: Shravan Narayanamurthy <shra...@apache.org>
Authored: Tue Sep 20 19:11:40 2016 -0700
Committer: Markus Weimer <wei...@apache.org>
Committed: Wed Sep 21 14:44:10 2016 -0700

----------------------------------------------------------------------
 .../MachineLearning/KMeans/codecs/AvroUtils.cs  | 61 ++++++++++++++++++++
 .../KMeans/codecs/CentroidsCodec.cs             |  1 -
 .../KMeans/codecs/DataVectorCodec.cs            |  1 -
 .../Org.Apache.REEF.Examples.csproj             | 14 ++++-
 .../cs/Org.Apache.REEF.Examples/packages.config |  4 +-
 .../Naming/Codec/NamingLookupRequestCodec.cs    |  2 +-
 .../Naming/Codec/NamingLookupResponseCodec.cs   |  2 +-
 .../Naming/Codec/NamingRegisterRequestCodec.cs  |  2 +-
 .../Codec/NamingUnregisterRequestCodec.cs       |  2 +-
 .../Org.Apache.REEF.Network.csproj              |  1 +
 .../Utilities/AvroUtils.cs                      | 61 ++++++++++++++++++++
 .../Attributes/TemporaryFixAttribute.cs         | 31 ++++++++++
 lang/cs/Org.Apache.REEF.Utilities/AvroUtils.cs  | 56 ------------------
 .../Org.Apache.Reef.Utilities.csproj            |  5 +-
 .../Org.Apache.REEF.Utilities/packages.config   |  3 +-
 15 files changed, 176 insertions(+), 70 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/AvroUtils.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/AvroUtils.cs 
b/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/AvroUtils.cs
new file mode 100644
index 0000000..be94c77
--- /dev/null
+++ 
b/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/AvroUtils.cs
@@ -0,0 +1,61 @@
+// 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.
+
+using System.IO;
+using Microsoft.Hadoop.Avro;
+using Org.Apache.REEF.Utilities.Attributes;
+
+/// <summary>
+/// This copy of AvroUtils should belong to O.A.R.Utilities
+/// As per the discussion on https://issues.apache.org/jira/browse/REEF-1570
+/// we are in-lining this here temporarily
+/// </summary>
+namespace Org.Apache.REEF.Examples.MachineLearning.KMeans.codecs
+{
+    [Private, TemporaryFix]
+    public static class AvroUtils
+    {
+        /// <summary>
+        /// Convert an object to byte array using Avro serialization
+        /// </summary>
+        /// <param name="obj">The object to serialize</param>
+        /// <returns>The serialized object in a byte array</returns>
+        public static byte[] AvroSerialize<T>(T obj)
+        {
+            IAvroSerializer<T> serializer = AvroSerializer.Create<T>();
+            using (MemoryStream stream = new MemoryStream())
+            {
+                serializer.Serialize(stream, obj);
+                return stream.GetBuffer();
+            }
+        }
+
+        /// <summary>
+        /// Converts a byte array to an object using Avro deserialization.
+        /// </summary>
+        /// <param name="data">The byte array to deserialize</param>
+        /// <returns>The deserialized object</returns>
+        public static T AvroDeserialize<T>(byte[] data)
+        {
+            IAvroSerializer<T> deserializer = AvroSerializer.Create<T>();
+            using (MemoryStream stream = new MemoryStream(data))
+            {
+                return deserializer.Deserialize(stream);
+            }
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/CentroidsCodec.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/CentroidsCodec.cs
 
b/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/CentroidsCodec.cs
index ffb9b11..849fdbb 100644
--- 
a/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/CentroidsCodec.cs
+++ 
b/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/CentroidsCodec.cs
@@ -17,7 +17,6 @@
 
 using Org.Apache.REEF.Examples.MachineLearning.KMeans.Contracts;
 using Org.Apache.REEF.Tang.Annotations;
-using Org.Apache.REEF.Utilities;
 using Org.Apache.REEF.Wake.Remote;
 
 namespace Org.Apache.REEF.Examples.MachineLearning.KMeans.codecs

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/DataVectorCodec.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/DataVectorCodec.cs
 
b/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/DataVectorCodec.cs
index d30a414..35f633d 100644
--- 
a/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/DataVectorCodec.cs
+++ 
b/lang/cs/Org.Apache.REEF.Examples/MachineLearning/KMeans/codecs/DataVectorCodec.cs
@@ -17,7 +17,6 @@
 
 using Org.Apache.REEF.Examples.MachineLearning.KMeans.Contracts;
 using Org.Apache.REEF.Tang.Annotations;
-using Org.Apache.REEF.Utilities;
 using Org.Apache.REEF.Wake.Remote;
 
 namespace Org.Apache.REEF.Examples.MachineLearning.KMeans.codecs

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Examples/Org.Apache.REEF.Examples.csproj
----------------------------------------------------------------------
diff --git a/lang/cs/Org.Apache.REEF.Examples/Org.Apache.REEF.Examples.csproj 
b/lang/cs/Org.Apache.REEF.Examples/Org.Apache.REEF.Examples.csproj
index 70e7f96..0f812e7 100644
--- a/lang/cs/Org.Apache.REEF.Examples/Org.Apache.REEF.Examples.csproj
+++ b/lang/cs/Org.Apache.REEF.Examples/Org.Apache.REEF.Examples.csproj
@@ -30,6 +30,14 @@ under the License.
   </PropertyGroup>
   <Import Project="$(SolutionDir)\build.props" />
   <ItemGroup>
+    <Reference Include="Microsoft.Hadoop.Avro">
+      
<HintPath>$(PackagesDir)\Microsoft.Hadoop.Avro.$(AvroVersion)\lib\net45\Microsoft.Hadoop.Avro.dll</HintPath>
+      <Private>True</Private>
+    </Reference>
+    <Reference Include="Newtonsoft.Json">
+      
<HintPath>$(PackagesDir)\Newtonsoft.Json.$(NewtonsoftJsonVersion)\lib\net45\Newtonsoft.Json.dll</HintPath>
+      <Private>True</Private>
+    </Reference>
     <Reference Include="System" />
     <Reference Include="System.Core" />
     <Reference Include="System.Runtime.Serialization" />
@@ -38,6 +46,7 @@ under the License.
     <Compile Include="DriverRestart\HelloRestartDriver.cs" />
     <Compile Include="DriverRestart\HelloRestartTask.cs" />
     <Compile Include="MachineLearning\KMeans\Centroids.cs" />
+    <Compile Include="MachineLearning\KMeans\codecs\AvroUtils.cs" />
     <Compile Include="MachineLearning\KMeans\codecs\CentroidsCodec.cs" />
     <Compile Include="MachineLearning\KMeans\codecs\DataVectorCodec.cs" />
     <Compile Include="MachineLearning\KMeans\codecs\ProcessedResultsCodec.cs" 
/>
@@ -90,7 +99,10 @@ under the License.
       <Name>Org.Apache.REEF.Wake</Name>
     </ProjectReference>
   </ItemGroup>
+  <ItemGroup>
+    <None Include="packages.config" />
+  </ItemGroup>
   <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
   <Import Project="$(SolutionDir)\.nuget\NuGet.targets" 
Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" />
   <Import 
Project="$(PackagesDir)\StyleCop.MSBuild.$(StyleCopVersion)\build\StyleCop.MSBuild.Targets"
 
Condition="Exists('$(PackagesDir)\StyleCop.MSBuild.$(StyleCopVersion)\build\StyleCop.MSBuild.Targets')"
 />
-</Project>
+</Project>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Examples/packages.config
----------------------------------------------------------------------
diff --git a/lang/cs/Org.Apache.REEF.Examples/packages.config 
b/lang/cs/Org.Apache.REEF.Examples/packages.config
index d952982..e8e2a6d 100644
--- a/lang/cs/Org.Apache.REEF.Examples/packages.config
+++ b/lang/cs/Org.Apache.REEF.Examples/packages.config
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
+<?xml version="1.0" encoding="utf-8"?>
 <!--
 Licensed to the Apache Software Foundation (ASF) under one
 or more contributor license agreements.  See the NOTICE file
@@ -18,5 +18,7 @@ specific language governing permissions and limitations
 under the License.
 -->
 <packages>
+  <package id="Microsoft.Hadoop.Avro" version="1.5.6" targetFramework="net45" 
/>
+  <package id="Newtonsoft.Json" version="8.0.3" targetFramework="net45" />
   <package id="StyleCop.MSBuild" version="4.7.49.1" targetFramework="net45" 
developmentDependency="true" />
 </packages>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupRequestCodec.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupRequestCodec.cs 
b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupRequestCodec.cs
index e82c0f1..ab11322 100644
--- a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupRequestCodec.cs
+++ b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupRequestCodec.cs
@@ -17,7 +17,7 @@
 
 using Org.Apache.REEF.Network.Naming.Contracts;
 using Org.Apache.REEF.Network.Naming.Events;
-using Org.Apache.REEF.Utilities;
+using Org.Apache.REEF.Network.Utilities;
 using Org.Apache.REEF.Wake.Remote;
 
 namespace Org.Apache.REEF.Network.Naming.Codec

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupResponseCodec.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupResponseCodec.cs 
b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupResponseCodec.cs
index 7c7bbe4..55aba26 100644
--- a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupResponseCodec.cs
+++ b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingLookupResponseCodec.cs
@@ -20,8 +20,8 @@ using System.Linq;
 using Org.Apache.REEF.Common.Io;
 using Org.Apache.REEF.Network.Naming.Contracts;
 using Org.Apache.REEF.Network.Naming.Events;
-using Org.Apache.REEF.Utilities;
 using Org.Apache.REEF.Wake.Remote;
+using Org.Apache.REEF.Network.Utilities;
 
 namespace Org.Apache.REEF.Network.Naming.Codec
 {

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingRegisterRequestCodec.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingRegisterRequestCodec.cs 
b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingRegisterRequestCodec.cs
index 2dc7afe..a495acd 100644
--- a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingRegisterRequestCodec.cs
+++ b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingRegisterRequestCodec.cs
@@ -18,7 +18,7 @@
 using Org.Apache.REEF.Common.Io;
 using Org.Apache.REEF.Network.Naming.Contracts;
 using Org.Apache.REEF.Network.Naming.Events;
-using Org.Apache.REEF.Utilities;
+using Org.Apache.REEF.Network.Utilities;
 using Org.Apache.REEF.Wake.Remote;
 
 namespace Org.Apache.REEF.Network.Naming.Codec

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingUnregisterRequestCodec.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingUnregisterRequestCodec.cs 
b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingUnregisterRequestCodec.cs
index 57b68b7..2155ce6 100644
--- 
a/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingUnregisterRequestCodec.cs
+++ 
b/lang/cs/Org.Apache.REEF.Network/Naming/Codec/NamingUnregisterRequestCodec.cs
@@ -17,7 +17,7 @@
 
 using Org.Apache.REEF.Network.Naming.Contracts;
 using Org.Apache.REEF.Network.Naming.Events;
-using Org.Apache.REEF.Utilities;
+using Org.Apache.REEF.Network.Utilities;
 using Org.Apache.REEF.Wake.Remote;
 
 namespace Org.Apache.REEF.Network.Naming.Codec

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Network/Org.Apache.REEF.Network.csproj
----------------------------------------------------------------------
diff --git a/lang/cs/Org.Apache.REEF.Network/Org.Apache.REEF.Network.csproj 
b/lang/cs/Org.Apache.REEF.Network/Org.Apache.REEF.Network.csproj
index c53027d..41a6328 100644
--- a/lang/cs/Org.Apache.REEF.Network/Org.Apache.REEF.Network.csproj
+++ b/lang/cs/Org.Apache.REEF.Network/Org.Apache.REEF.Network.csproj
@@ -158,6 +158,7 @@ under the License.
     <Compile Include="Properties\AssemblyInfo.cs" />
     <Compile Include="TcpClientConfigurationModule.cs" />
     <Compile Include="TcpClientConfigurationProvider.cs" />
+    <Compile Include="Utilities\AvroUtils.cs" />
     <Compile Include="Utilities\BlockingCollectionExtensions.cs" />
     <Compile Include="Utilities\Utils.cs" />
   </ItemGroup>

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Network/Utilities/AvroUtils.cs
----------------------------------------------------------------------
diff --git a/lang/cs/Org.Apache.REEF.Network/Utilities/AvroUtils.cs 
b/lang/cs/Org.Apache.REEF.Network/Utilities/AvroUtils.cs
new file mode 100644
index 0000000..2b63c07
--- /dev/null
+++ b/lang/cs/Org.Apache.REEF.Network/Utilities/AvroUtils.cs
@@ -0,0 +1,61 @@
+// 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.
+
+using System.IO;
+using Microsoft.Hadoop.Avro;
+using Org.Apache.REEF.Utilities.Attributes;
+
+/// <summary>
+/// This copy of AvroUtils should belong to O.A.R.Utilities
+/// As per the discussion on https://issues.apache.org/jira/browse/REEF-1570
+/// we are in-lining this here temporarily
+/// </summary>
+namespace Org.Apache.REEF.Network.Utilities
+{
+    [Private, TemporaryFix]
+    public static class AvroUtils
+    {
+        /// <summary>
+        /// Convert an object to byte array using Avro serialization
+        /// </summary>
+        /// <param name="obj">The object to serialize</param>
+        /// <returns>The serialized object in a byte array</returns>
+        public static byte[] AvroSerialize<T>(T obj)
+        {
+            IAvroSerializer<T> serializer = AvroSerializer.Create<T>();
+            using (MemoryStream stream = new MemoryStream())
+            {
+                serializer.Serialize(stream, obj);
+                return stream.GetBuffer();
+            }
+        }
+
+        /// <summary>
+        /// Converts a byte array to an object using Avro deserialization.
+        /// </summary>
+        /// <param name="data">The byte array to deserialize</param>
+        /// <returns>The deserialized object</returns>
+        public static T AvroDeserialize<T>(byte[] data)
+        {
+            IAvroSerializer<T> deserializer = AvroSerializer.Create<T>();
+            using (MemoryStream stream = new MemoryStream(data))
+            {
+                return deserializer.Deserialize(stream);
+            }
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Utilities/Attributes/TemporaryFixAttribute.cs
----------------------------------------------------------------------
diff --git 
a/lang/cs/Org.Apache.REEF.Utilities/Attributes/TemporaryFixAttribute.cs 
b/lang/cs/Org.Apache.REEF.Utilities/Attributes/TemporaryFixAttribute.cs
new file mode 100644
index 0000000..57e5806
--- /dev/null
+++ b/lang/cs/Org.Apache.REEF.Utilities/Attributes/TemporaryFixAttribute.cs
@@ -0,0 +1,31 @@
+// 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.
+
+using System;
+
+namespace Org.Apache.REEF.Utilities.Attributes
+{
+    /// <summary>
+    /// Attribute target is a temporary fix and will
+    /// be refactored suitably without a deprecation phase.
+    /// </summary>
+    [AttributeUsage(AttributeTargets.All)]
+    public sealed class TemporaryFixAttribute : Attribute
+    {
+        // Intentionally empty.
+    }
+}

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Utilities/AvroUtils.cs
----------------------------------------------------------------------
diff --git a/lang/cs/Org.Apache.REEF.Utilities/AvroUtils.cs 
b/lang/cs/Org.Apache.REEF.Utilities/AvroUtils.cs
deleted file mode 100644
index 8c950c0..0000000
--- a/lang/cs/Org.Apache.REEF.Utilities/AvroUtils.cs
+++ /dev/null
@@ -1,56 +0,0 @@
-// 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.
-
-using System.IO;
-using Microsoft.Hadoop.Avro;
-using Org.Apache.REEF.Utilities.Attributes;
-
-namespace Org.Apache.REEF.Utilities
-{
-    [Private]
-    public static class AvroUtils
-    {
-        /// <summary>
-        /// Convert an object to byte array using Avro serialization
-        /// </summary>
-        /// <param name="obj">The object to serialize</param>
-        /// <returns>The serialized object in a byte array</returns>
-        public static byte[] AvroSerialize<T>(T obj)
-        {
-            IAvroSerializer<T> serializer = AvroSerializer.Create<T>();
-            using (MemoryStream stream = new MemoryStream())
-            {
-                serializer.Serialize(stream, obj);
-                return stream.GetBuffer();
-            }
-        }
-
-        /// <summary>
-        /// Converts a byte array to an object using Avro deserialization.
-        /// </summary>
-        /// <param name="data">The byte array to deserialize</param>
-        /// <returns>The deserialized object</returns>
-        public static T AvroDeserialize<T>(byte[] data)
-        {
-            IAvroSerializer<T> deserializer = AvroSerializer.Create<T>();
-            using (MemoryStream stream = new MemoryStream(data))
-            {
-                return deserializer.Deserialize(stream);
-            }
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Utilities/Org.Apache.Reef.Utilities.csproj
----------------------------------------------------------------------
diff --git a/lang/cs/Org.Apache.REEF.Utilities/Org.Apache.Reef.Utilities.csproj 
b/lang/cs/Org.Apache.REEF.Utilities/Org.Apache.Reef.Utilities.csproj
index 7e0e214..0fd1c26 100644
--- a/lang/cs/Org.Apache.REEF.Utilities/Org.Apache.Reef.Utilities.csproj
+++ b/lang/cs/Org.Apache.REEF.Utilities/Org.Apache.Reef.Utilities.csproj
@@ -30,9 +30,6 @@ under the License.
   </PropertyGroup>
   <Import Project="$(SolutionDir)\build.props" />
   <ItemGroup>
-    <Reference Include="Microsoft.Hadoop.Avro">
-      
<HintPath>$(PackagesDir)\Microsoft.Hadoop.Avro.$(AvroVersion)\lib\net45\Microsoft.Hadoop.Avro.dll</HintPath>
-    </Reference>
     <Reference Include="System" />
     <Reference Include="System.Core" />
     <Reference Include="System.Xml" />
@@ -46,12 +43,12 @@ under the License.
     <Compile Include="Attributes\EvaluatorSideAttribute.cs" />
     <Compile Include="Attributes\InteropAttribute.cs" />
     <Compile Include="Attributes\NotThreadSafeAttribute.cs" />
+    <Compile Include="Attributes\TemporaryFixAttribute.cs" />
     <Compile Include="Attributes\PrivateAttribute.cs" />
     <Compile Include="Attributes\TaskSideAttribute.cs" />
     <Compile Include="Attributes\TestingAttribute.cs" />
     <Compile Include="Attributes\ThreadSafeAttribute.cs" />
     <Compile Include="Attributes\UnstableAttribute.cs" />
-    <Compile Include="AvroUtils.cs" />
     <Compile Include="ByteUtilities.cs" />
     <Compile Include="Collections\PriorityQueue.cs" />
     <Compile Include="Collections\ReadOnlySet.cs" />

http://git-wip-us.apache.org/repos/asf/reef/blob/57e9f4db/lang/cs/Org.Apache.REEF.Utilities/packages.config
----------------------------------------------------------------------
diff --git a/lang/cs/Org.Apache.REEF.Utilities/packages.config 
b/lang/cs/Org.Apache.REEF.Utilities/packages.config
index 497b801..2b61ca3 100644
--- a/lang/cs/Org.Apache.REEF.Utilities/packages.config
+++ b/lang/cs/Org.Apache.REEF.Utilities/packages.config
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
+<?xml version="1.0" encoding="utf-8"?>
 <!--
 Licensed to the Apache Software Foundation (ASF) under one
 or more contributor license agreements.  See the NOTICE file
@@ -18,7 +18,6 @@ specific language governing permissions and limitations
 under the License.
 -->
 <packages>
-  <package id="Microsoft.Hadoop.Avro" version="1.5.6" targetFramework="net45" 
/>
   <package id="Newtonsoft.Json" version="8.0.3" targetFramework="net45" />
   <package id="StyleCop.MSBuild" version="4.7.49.1" targetFramework="net45" 
developmentDependency="true" />
 </packages>
\ No newline at end of file

Reply via email to