derrickaw commented on code in PR #38362:
URL: https://github.com/apache/beam/pull/38362#discussion_r3209133388


##########
sdks/python/apache_beam/yaml/integration_tests.py:
##########
@@ -20,19 +20,46 @@
 import contextlib
 import copy
 import glob
+import gzip
+import http.server
+import io
 import itertools
+import json
 import logging
 import os
 import random
 import secrets
 import sqlite3
 import string
+import struct
+import threading
 import unittest
 import uuid
 from datetime import datetime
 from datetime import timezone
 
 import mock
+
+from apache_beam.coders import Coder
+from apache_beam.coders.coder_impl import CoderImpl
+
+
+class BigEndianIntegerCoderImpl(CoderImpl):
+  def encode_to_stream(self, value, stream, nested):
+    stream.write(struct.pack('>i', value))
+
+  def decode_from_stream(self, stream, nested):
+    return struct.unpack('>i', stream.read(4))[0]
+
+
+class BigEndianIntegerCoder(Coder):
+  def get_impl(self):
+    return BigEndianIntegerCoderImpl()
+
+
+Coder.register_urn(

Review Comment:
   added a few notes, thanks



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to