You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2020/06/18 16:45:46 UTC

[GitHub] [arrow] lidavidm opened a new pull request #7481: ARROW-9175: [FlightRPC][C++] Expose peer to server

lidavidm opened a new pull request #7481:
URL: https://github.com/apache/arrow/pull/7481


   Being able to read and log the client IP/port is often useful when analyzing a request after-the-fact.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow] pitrou commented on a change in pull request #7481: ARROW-9175: [FlightRPC][C++] Expose peer to server

Posted by GitBox <gi...@apache.org>.
pitrou commented on a change in pull request #7481:
URL: https://github.com/apache/arrow/pull/7481#discussion_r442376353



##########
File path: python/pyarrow/_flight.pyx
##########
@@ -1413,6 +1413,10 @@ cdef class ServerCallContext:
         """
         return tobytes(self.context.peer_identity())
 
+    def peer(self):
+        """Get the address of the peer."""
+        return tobytes(self.context.peer())

Review comment:
       Why `tobytes`? I would expect `frombytes`, to get a proper string.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow] github-actions[bot] commented on pull request #7481: ARROW-9175: [FlightRPC][C++] Expose peer to server

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #7481:
URL: https://github.com/apache/arrow/pull/7481#issuecomment-646161768


   https://issues.apache.org/jira/browse/ARROW-9175


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow] wesm closed pull request #7481: ARROW-9175: [FlightRPC][C++] Expose peer to server

Posted by GitBox <gi...@apache.org>.
wesm closed pull request #7481:
URL: https://github.com/apache/arrow/pull/7481


   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow] lidavidm commented on pull request #7481: ARROW-9175: [FlightRPC][C++] Expose peer to server

Posted by GitBox <gi...@apache.org>.
lidavidm commented on pull request #7481:
URL: https://github.com/apache/arrow/pull/7481#issuecomment-646185813


   > This looks like a good idea. What kind of adresses does grpc give out?
   
   Looks like this:
   
   ```
   ipv6:[::1]:37626
   ```
   
   So probably most useful within a corporate network.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow] lidavidm commented on a change in pull request #7481: ARROW-9175: [FlightRPC][C++] Expose peer to server

Posted by GitBox <gi...@apache.org>.
lidavidm commented on a change in pull request #7481:
URL: https://github.com/apache/arrow/pull/7481#discussion_r442380286



##########
File path: python/pyarrow/_flight.pyx
##########
@@ -1413,6 +1413,10 @@ cdef class ServerCallContext:
         """
         return tobytes(self.context.peer_identity())
 
+    def peer(self):
+        """Get the address of the peer."""
+        return tobytes(self.context.peer())

Review comment:
       Good point - fixed.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org