You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openwhisk.apache.org by gi...@git.apache.org on 2017/09/03 01:02:58 UTC

[GitHub] tysonnorris commented on a change in pull request #2689: WIP on dynamic invoker id assignment

tysonnorris commented on a change in pull request #2689: WIP on dynamic invoker id assignment
URL: https://github.com/apache/incubator-openwhisk/pull/2689#discussion_r136706191
 
 

 ##########
 File path: core/invoker/src/main/scala/whisk/core/invoker/Invoker.scala
 ##########
 @@ -89,6 +91,41 @@ object Invoker {
 
         val msgProvider = SpiLoader.get[MessagingProvider]()
         val producer = msgProvider.getProducer(config, ec)
+
+        val invokerOrdinal =
+          if (args.length == 0) {
+            val registrationUUID = UUID()
+            producer.send("invokerReg", InvokerIdRequestMessage(registrationUUID.asString)).andThen {
+              case Success(_) => {
+                logger.info(this, s"sent invokerReg message with UUID ${registrationUUID.asString}")
+              }
+              case Failure(t) => {
+                logger.error(this, s"failed to send invokerReg message: $t")
+                abort()
+              }
+            }
+            val topic = s"invokerReg-${registrationUUID.asString}"
 
 Review comment:
   requires a new topic per restart of the same invoker?
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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