nemo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [incubator-nemo] wynot12 commented on a change in pull request #203: [NEMO-360] Implementing an 'XGBoostPolicy'
Date Wed, 20 Mar 2019 09:23:42 GMT
wynot12 commented on a change in pull request #203: [NEMO-360] Implementing an 'XGBoostPolicy'
URL: https://github.com/apache/incubator-nemo/pull/203#discussion_r267222941
 
 

 ##########
 File path: client/src/main/java/org/apache/nemo/client/JobLauncher.java
 ##########
 @@ -133,6 +136,11 @@ public static void setup(final String[] args) throws InjectionException,
ClassNo
       .registerHandler(ControlMessage.DriverToClientMessageType.ExecutionDone, event ->
jobDoneLatch.countDown())
       .registerHandler(ControlMessage.DriverToClientMessageType.DataCollected, message ->
COLLECTED_DATA.addAll(
         SerializationUtils.deserialize(Base64.getDecoder().decode(message.getDataCollected().getData()))))
+      .registerHandler(ControlMessage.DriverToClientMessageType.LaunchXGBoostScript, message
->
+        driverRPCServer.send(ControlMessage.ClientToDriverMessage.newBuilder()
+          .setType(ControlMessage.ClientToDriverMessageType.Notification)
+          .setMessage(MetricUtils.launchXGBoostScript(message.getDataCollected().getData()))
+          .build()))
 
 Review comment:
   The code calls `launchXGBoostScript` from network msg handler thread, blocking the thread.
   It's okay if the routine is short enough not to block network thread, otherwise it's good
to use another thread and send the result to driver asynchronously.
   As I think it belongs to the latter case.
   
   How do you think?

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


With regards,
Apache Git Services

Mime
View raw message