Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id C0244200B76 for ; Tue, 16 Aug 2016 00:23:22 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id BEA4B160AB8; Mon, 15 Aug 2016 22:23:22 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 0F793160AA7 for ; Tue, 16 Aug 2016 00:23:21 +0200 (CEST) Received: (qmail 30626 invoked by uid 500); 15 Aug 2016 22:23:21 -0000 Mailing-List: contact dev-help@reef.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@reef.apache.org Delivered-To: mailing list dev@reef.apache.org Received: (qmail 30614 invoked by uid 99); 15 Aug 2016 22:23:21 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Aug 2016 22:23:21 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 6E2962C0032 for ; Mon, 15 Aug 2016 22:23:20 +0000 (UTC) Date: Mon, 15 Aug 2016 22:23:20 +0000 (UTC) From: "Boris Shulman (JIRA)" To: dev@reef.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (REEF-1529) Fixing reef-webserver for multi runtime MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 15 Aug 2016 22:23:22 -0000 [ https://issues.apache.org/jira/browse/REEF-1529?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15421788#comment-15421788 ] Boris Shulman commented on REEF-1529: ------------------------------------- [~juliaw] Do we have a more elegant way to test if an interface has any implementation then trying to get an instance of it and catch exception? > Fixing reef-webserver for multi runtime > --------------------------------------- > > Key: REEF-1529 > URL: https://issues.apache.org/jira/browse/REEF-1529 > Project: REEF > Issue Type: Improvement > Reporter: Boris Shulman > Assignee: Boris Shulman > > reef-webserver functionality is broken for multiruntime on yarn. The problem is that the http-server does not exist in the injector that is used for the actual runtime implementation. > The proposed solution is to check if http server is binded in the original injector and copy it to the aftual runitme injector: > Add in RuntimesHost.initializeInjector method: > org.apache.reef.webserver.HttpServer httpServer = null; > try{ > httpServer = this.originalInjector.getInstance(org.apache.reef > .webserver > .HttpServer.class); > } catch(org.apache.reef.tang.exceptions.InjectionException e) { > } > if(httpServer != null){ > runtimeInjector.bindVolatileInstance( > org.apache.reef.webserver.HttpServer.class, > httpServer); > } > In addition I need to pass the right TrackingURLProvider to the actual runtime. I propose to change the default implementation to the HttpTrackingURLProvider and remove the current DefaultTrackingURLProvider empty implementation. In addition I will need to add default emptyimplementation for HttpServer in order to be able to instantiate the TrackingURLProvider implementation when no httpserver is bound. -- This message was sent by Atlassian JIRA (v6.3.4#6332)