{"action":"created","comment":{"url":"https://api.github.com/repos/apache/reef/pulls/comments/66563113","id":66563113,"diff_hunk":"@@ -98,181 +128,461 @@ internal sealed class IMRUDriver<TMapInput, TMapOutput, TResult, TPartitionType>\n             [Parameter(typeof(MemoryPerMapper))] int memoryPerMapper,\n             [Parameter(typeof(MemoryForUpdateTask))] int memoryForUpdateTask,\n             [Parameter(typeof(AllowedFailedEvaluatorsFraction))] double failedEvaluatorsFraction,\n+            [Parameter(typeof(MaxRetryNumberInRecovery))] int maxRetryNumberInRecovery,\n             [Parameter(typeof(InvokeGC))] bool invokeGC,\n             IGroupCommDriver groupCommDriver)\n         {\n             _configurationManager = configurationManager;\n-            _evaluatorRequestor = evaluatorRequestor;\n             _groupCommDriver = groupCommDriver;\n-            _coresPerMapper = coresPerMapper;\n-            _coresForUpdateTask = coresForUpdateTask;\n-            _memoryPerMapper = memoryPerMapper;\n-            _memoryForUpdateTask = memoryForUpdateTask;\n             _perMapperConfigs = perMapperConfigs;\n             _totalMappers = dataSet.Count;\n-\n-            _allowedFailedEvaluators = (int)(failedEvaluatorsFraction * dataSet.Count);\n             _invokeGC = invokeGC;\n+            _maxRetryNumberForFaultTolerant = maxRetryNumberInRecovery;\n \n-            AddGroupCommunicationOperators();\n-            _groupCommTaskStarter = new TaskStarter(_groupCommDriver, _totalMappers + 1);\n-            _perMapperConfiguration = ConstructPerMapperConfigStack(_totalMappers);\n+            _contextManager = new ActiveContextManager(_totalMappers + 1);\n+            _contextManager.Subscribe(this);\n+\n+            var updateSpec = new EvaluatorSpecification(memoryForUpdateTask, coresForUpdateTask);\n+            var mapperSpec = new EvaluatorSpecification(memoryPerMapper, coresPerMapper);\n+            var allowedFailedEvaluators = (int)(failedEvaluatorsFraction * dataSet.Count);\n+            _evaluatorManager = new EvaluatorManager(_totalMappers + 1, allowedFailedEvaluators, evaluatorRequestor, updateSpec, mapperSpec);\n+\n+            _taskManager = new TaskManager(_totalMappers + 1, _groupCommDriver.MasterTaskId);\n+            _systemState = new SystemStateMachine();\n             _serviceAndContextConfigurationProvider =\n                 new ServiceAndContextConfigurationProvider<TMapInput, TMapOutput, TPartitionType>(dataSet);\n \n             var msg =\n-                string.Format(\"map task memory:{0}, update task memory:{1}, map task cores:{2}, update task cores:{3}\",\n-                    _memoryPerMapper,\n-                    _memoryForUpdateTask,\n-                    _coresPerMapper,\n-                    _coresForUpdateTask);\n+                string.Format(CultureInfo.InvariantCulture, \"map task memory:{0}, update task memory:{1}, map task cores:{2}, update task cores:{3}\",\n+                    memoryPerMapper,\n+                    memoryForUpdateTask,\n+                    coresPerMapper,\n+                    coresForUpdateTask);\n             Logger.Log(Level.Info, msg);\n         }\n \n+        #region IDriverStarted\n         /// <summary>\n-        /// Requests for evaluator for update task\n+        /// Requests evaluators when driver starts\n         /// </summary>\n         /// <param name=\"value\">Event fired when driver started</param>\n         public void OnNext(IDriverStarted value)\n         {\n-            RequestUpdateEvaluator();\n-            //// TODO[REEF-598]: Set a timeout for this request to be satisfied. If it is not within that time, exit the Driver.\n+            StartAction();\n         }\n+        #endregion IDriverStarted\n \n+        #region IAllocatedEvaluator\n         /// <summary>\n-        /// Specifies context and service configuration for evaluator depending\n-        /// on whether it is for Update function or for map function\n+        /// IAllocatedEvaluator handler. It will take the following action based on the system state:\n+        /// Case WaitingForEvaluator\n+        ///    Add Evaluator to the Evaluator Manager\n+        ///    submit Context and Services\n+        /// Case Fail\n+        ///    Do nothing. This is because the code that sets system Fail has executed FailedAction. It has shut down all the allocated evaluators/contexts. \n+        ///    If a new IAllocatedEvaluator comes after it, we should not submit anything so that the evaluator is returned.\n+        /// Other cases - not expected\n         /// </summary>\n         /// <param name=\"allocatedEvaluator\">The allocated evaluator</param>\n         public void OnNext(IAllocatedEvaluator allocatedEvaluator)\n         {\n-            var configs =\n-                _serviceAndContextConfigurationProvider.GetContextConfigurationForEvaluatorById(allocatedEvaluator.Id);\n-            allocatedEvaluator.SubmitContextAndService(configs.Context, configs.Service);\n+            Logger.Log(Level.Verbose, \"AllocatedEvaluator EvaluatorBatchId [{0}], memory [{1}], systemState {2}.\", allocatedEvaluator.EvaluatorBatchId, allocatedEvaluator.GetEvaluatorDescriptor().Memory, _systemState.CurrentState);\n+            lock (_lock)\n+            {\n+                switch (_systemState.CurrentState)\n+                {\n+                    case SystemState.WaitingForEvaluator:\n+                        _evaluatorManager.AddAllocatedEvaluator(allocatedEvaluator);\n+                        SubmitContextAndService(allocatedEvaluator);\n+                        break;\n+                    case SystemState.Fail:\n+                        Logger.Log(Level.Verbose, \"Receiving IAllocatedEvaluator event, but system is in FAIL state, ignore it.\");\n+                        break;\n+                    default:\n+                        UnexpectedState(allocatedEvaluator.Id, \"IAllocatedEvaluator\");\n+                        break;\n+                }\n+            }\n         }\n \n         /// <summary>\n-        /// Specifies the Map or Update task to run on the active context\n+        /// Gets context and service configuration for evaluator depending\n+        /// on whether it is for update/master function or for mapper function.\n+        /// Then submits Context and Service with the corresponding configuration\n         /// </summary>\n-        /// <param name=\"activeContext\"></param>\n-        public void OnNext(IActiveContext activeContext)\n+        /// <param name=\"allocatedEvaluator\"></param>\n+        private void SubmitContextAndService(IAllocatedEvaluator allocatedEvaluator)\n         {\n-            Logger.Log(Level.Verbose, string.Format(\"Received Active Context {0}\", activeContext.Id));\n-\n-            if (_serviceAndContextConfigurationProvider.IsMasterEvaluatorId(activeContext.EvaluatorId))\n+            ContextAndServiceConfiguration configs;\n+            if (_evaluatorManager.IsEvaluatorForMaster(allocatedEvaluator))\n             {\n-                Logger.Log(Level.Verbose, \"Submitting master task\");\n-                _commGroup.AddTask(IMRUConstants.UpdateTaskName);\n-                _groupCommTaskStarter.QueueTask(GetUpdateTaskConfiguration(), activeContext);\n-                RequestMapEvaluators(_totalMappers);\n+                configs =\n+                    _serviceAndContextConfigurationProvider\n+                        .GetContextConfigurationForMasterEvaluatorById(\n+                            allocatedEvaluator.Id);\n             }\n             else\n             {\n-                Logger.Log(Level.Verbose, \"Submitting map task\");\n-                _serviceAndContextConfigurationProvider.RecordActiveContextPerEvaluatorId(activeContext.EvaluatorId);\n-                string taskId = GetTaskIdByEvaluatorId(activeContext.EvaluatorId);\n-                _commGroup.AddTask(taskId);\n-                _groupCommTaskStarter.QueueTask(GetMapTaskConfiguration(activeContext, taskId), activeContext);\n-                Interlocked.Increment(ref _numberOfReadyTasks);\n-                Logger.Log(Level.Verbose, string.Format(\"{0} Tasks are ready for submission\", _numberOfReadyTasks));\n+                configs = _serviceAndContextConfigurationProvider\n+                    .GetDataLoadingConfigurationForEvaluatorById(\n+                        allocatedEvaluator.Id);\n             }\n+            allocatedEvaluator.SubmitContextAndService(configs.Context, configs.Service);\n         }\n+        #endregion IAllocatedEvaluator\n \n+        #region IActiveContext\n         /// <summary>\n-        /// Specifies what to do when the task is completed\n-        /// In this case just disposes off the task\n+        /// IActiveContext handler. It will take the following actions based on the system state:\n+        /// Case WaitingForEvaluator:\n+        ///    Adds Active Context to Active Context Manager\n+        /// Case Fail:\n+        ///    Closes the ActiveContext\n+        /// Other cases - not expected\n         /// </summary>\n-        /// <param name=\"completedTask\">The link to the completed task</param>\n-        public void OnNext(ICompletedTask completedTask)\n+        /// <param name=\"activeContext\"></param>\n+        public void OnNext(IActiveContext activeContext)\n         {\n-            lock (_completedTasks)\n+            Logger.Log(Level.Verbose, \"Received Active Context {0}, systemState {1}.\", activeContext.Id, _systemState.CurrentState);\n+            lock (_lock)\n             {\n-                Logger.Log(Level.Info,\n-                    string.Format(\"Received completed task message from task Id: {0}\", completedTask.Id));\n-                _completedTasks.Add(completedTask);\n-\n-                if (AreIMRUTasksCompleted())\n+                switch (_systemState.CurrentState)\n                 {\n-                    ShutDownAllEvaluators();\n+                    case SystemState.WaitingForEvaluator:\n+                        _contextManager.Add(activeContext);\n+                        break;\n+                    case SystemState.Fail:\n+                        Logger.Log(Level.Info, \"Received IActiveContext event, but system is in FAIL state. Closing the context.\");\n+                        activeContext.Dispose();\n+                        break;\n+                    default:\n+                        UnexpectedState(activeContext.Id, \"IActiveContext\");\n+                        break;\n                 }\n             }\n         }\n+        #endregion IActiveContext\n \n+        #region submit tasks\n         /// <summary>\n-        /// Specifies what to do when evaluator fails.\n-        /// If we get all completed tasks then ignore the failure\n-        /// Else request a new evaluator. If failure happens in middle of IMRU \n-        /// job we expect neighboring evaluators to fail while doing \n-        /// communication and will use FailedTask and FailedContext logic to \n-        /// order shutdown.\n+        /// Called from ActiveContextManager when all the expected active context are received.\n+        /// It changes the system state then calls SubmitTasks().\n         /// </summary>\n         /// <param name=\"value\"></param>\n-        public void OnNext(IFailedEvaluator value)\n+        public void OnNext(int value)\n         {\n-            if (AreIMRUTasksCompleted())\n+            Logger.Log(Level.Info, \"Received event from ActiveContextManager with NumberOfActiveContexts:\" + value);\n+            lock (_lock)\n             {\n-                Logger.Log(Level.Info,\n-                    string.Format(\"Evaluator with Id: {0} failed but IMRU task is completed. So ignoring.\", value.Id));\n-                return;\n+                // Change the system state to SubmittingTasks\n+                _systemState.MoveNext(SystemStateEvent.AllContextsAreReady);\n+                SubmitTasks();\n             }\n+        }\n \n-            Logger.Log(Level.Info,\n-                string.Format(\"Evaluator with Id: {0} failed with Exception: {1}\", value.Id, value.EvaluatorException));\n-            int currFailedEvaluators = Interlocked.Increment(ref _currentFailedEvaluators);\n-            if (currFailedEvaluators > _allowedFailedEvaluators)\n+        /// <summary>\n+        /// This method is responsible to prepare for the task submission then call SubmitTasks in TaskManager.\n+        /// It is called in both first time and recovery scenarios.\n+        /// Creates a new Communication Group and adds Group Communication Operators\n+        /// For each context, adds a task to the communication group.\n+        /// After all the tasks are added to the group, for each task, gets GroupCommTaskConfiguration from IGroupCommDriver \n+        /// and merges it with the task configuration.\n+        /// When all the tasks are added, calls TaskManager to SubmitTasks().\n+        /// </summary>\n+        private void SubmitTasks()\n+        {\n+            Logger.Log(Level.Info, \"SubmitTasks with system state :\" + _systemState.CurrentState);\n+            if (!_isFirstTry)\n             {\n-                Exceptions.Throw(new MaximumNumberOfEvaluatorFailuresExceededException(_allowedFailedEvaluators),\n-                    Logger);\n+                _taskManager.Reset();\n+                _groupCommDriver.RemoveCommunicationGroup(IMRUConstants.CommunicationGroupName);\n             }\n \n-            _serviceAndContextConfigurationProvider.RecordEvaluatorFailureById(value.Id);\n-            bool isMaster = _serviceAndContextConfigurationProvider.IsMasterEvaluatorId(value.Id);\n+            var commGroup = AddCommunicationGroupWithOperators();\n+            _perMapperConfigurationStack = ConstructPerMapperConfigStack(_totalMappers);\n \n-            // If failed evaluator is master then ask for master \n-            // evaluator else ask for mapper evaluator\n-            if (!isMaster)\n+            var taskIdAndContextMapping = new Dictionary<string, IActiveContext>();\n+            foreach (var activeContext in _contextManager.ActiveContexts)\n             {\n-                Logger.Log(Level.Info, string.Format(\"Requesting a replacement map Evaluator for {0}\", value.Id));\n-                RequestMapEvaluators(1);\n+                var taskId = _evaluatorManager.IsMasterEvaluatorId(activeContext.EvaluatorId) ?\n+                    _groupCommDriver.MasterTaskId :\n+                    GetMapperTaskIdByEvaluatorId(activeContext.EvaluatorId);\n+                commGroup.AddTask(taskId);\n+                taskIdAndContextMapping.Add(taskId, activeContext);\n             }\n-            else\n+\n+            foreach (var mapping in taskIdAndContextMapping)\n             {\n-                Logger.Log(Level.Info, string.Format(\"Requesting a replacement master Evaluator for {0}\", value.Id));\n-                RequestUpdateEvaluator();\n+                var taskConfig = _evaluatorManager.IsMasterEvaluatorId(mapping.Value.EvaluatorId) ?\n+                    GetMasterTaskConfiguration(mapping.Key) :\n+                    GetMapperTaskConfiguration(mapping.Value, mapping.Key);\n+                var groupCommTaskConfiguration = _groupCommDriver.GetGroupCommTaskConfiguration(mapping.Key);\n+                var mergedTaskConf = Configurations.Merge(taskConfig, groupCommTaskConfiguration);\n+                _taskManager.AddTask(mapping.Key, mergedTaskConf, mapping.Value);\n             }\n+            _taskManager.SubmitTasks();\n         }\n+        #endregion submit tasks\n \n+        #region IRunningTask\n         /// <summary>\n-        /// Specifies what to do if Failed Context is received.\n-        /// An exception is thrown if tasks are not completed.\n+        /// IRunningTask handler. The method is called when a task is running. The following action will be taken based on the system state:\n+        /// Case WaitingForEvaluator\n+        ///     Add it to RunningTasks and set task state to TaskRunning\n+        ///     When all the tasks are running, change system state to TasksRunning\n+        /// Case ShuttingDown/Fail\n+        ///     Call TaskManager to record RunningTask during SystemFailure\n+        /// Other cases - not expected \n         /// </summary>\n-        /// <param name=\"value\"></param>\n-        public void OnNext(IFailedContext value)\n+        /// <param name=\"runningTask\"></param>\n+        public void OnNext(IRunningTask runningTask)\n         {\n-            if (AreIMRUTasksCompleted())\n+            Logger.Log(Level.Info, \"Received IRunningTask {0} at SystemState {1} in retry # {2}.\", runningTask.Id, _systemState.CurrentState, _numberOfRetryForFaultTolerant);\n+            lock (_lock)\n             {\n-                Logger.Log(Level.Info,\n-                    string.Format(\"Context with Id: {0} failed but IMRU task is completed. So ignoring.\", value.Id));\n-                return;\n+                switch (_systemState.CurrentState)\n+                {\n+                    case SystemState.SubmittingTasks:\n+                        _taskManager.RecordRunningTask(runningTask);\n+                        if (_taskManager.AreAllTasksRunning())\n+                        {\n+                            _systemState.MoveNext(SystemStateEvent.AllTasksAreRunning);\n+                            Logger.Log(Level.Info, \"All tasks are running, SystemState {0}\", _systemState.CurrentState);\n+                        }\n+                        break;\n+                    case SystemState.ShuttingDown:\n+                    case SystemState.Fail:\n+                        _taskManager.RecordRunningTaskDuringSystemFailure(runningTask, TaskManager.CloseTaskByDriver);\n+                        break;\n+                    default:\n+                        UnexpectedState(runningTask.Id, \"IRunningTask\");\n+                        break;\n+                }\n             }\n-            Exceptions.Throw(new Exception(string.Format(\"Data Loading Context with Id: {0} failed\", value.Id)), Logger);\n         }\n+        #endregion IRunningTask\n \n+        #region ICompletedTask\n         /// <summary>\n-        /// Specifies what to do if a task fails.\n-        /// We throw the exception and fail IMRU unless IMRU job is already done.\n+        /// ICompletedTask handler. It is called when a task is completed. The following action will be taken based on the System State:\n+        /// Case TasksRunning\n+        ///     Updates task state to TaskCompleted\n+        ///     If all tasks are completed, sets system state to TasksCompleted and then go to Done action\n+        /// Case ShuttingDown\n+        ///     Updates task state to TaskCompleted\n+        ///     Try to recover\n+        /// Other cases - not expected \n         /// </summary>\n-        /// <param name=\"value\"></param>\n-        public void OnNext(IFailedTask value)\n+        /// <param name=\"completedTask\">The link to the completed task</param>\n+        public void OnNext(ICompletedTask completedTask)\n         {\n-            if (AreIMRUTasksCompleted())\n+            Logger.Log(Level.Info, \"Received ICompletedTask {0}, systemState {1} in retry # {2}.\", completedTask.Id, _systemState.CurrentState, _numberOfRetryForFaultTolerant);\n+\n+            lock (_lock)\n             {\n-                Logger.Log(Level.Info,\n-                    string.Format(\"Task with Id: {0} failed but IMRU task is completed. So ignoring.\", value.Id));\n-                return;\n+                switch (_systemState.CurrentState)\n+                {\n+                    case SystemState.TasksRunning:\n+                        _taskManager.RecordCompletedTask(completedTask);\n+                        if (_taskManager.AreAllTasksCompleted())\n+                        {\n+                            _systemState.MoveNext(SystemStateEvent.AllTasksAreCompleted);\n+                            Logger.Log(Level.Info, \"All tasks are completed, systemState {0}\", _systemState.CurrentState);\n+                            DoneAction();\n+                        }\n+                        break;\n+                    case SystemState.ShuttingDown:\n+                        // The task might be in running state or waiting for close, set it to complete anyway to make its state final\n+                        _taskManager.RecordCompletedTask(completedTask);\n+                        TryRecovery();\n+                        break;\n+                    default:\n+                        UnexpectedState(completedTask.Id, \"ICompletedTask\");\n+                        break;\n+                }\n+            }\n+        }\n+        #endregion ICompletedTask\n+\n+        #region IFailedEvaluator\n+        /// <summary>\n+        /// IFailedEvaluator handler. It specifies what to do when an evaluator fails.\n+        /// If we get all completed tasks then ignore the failure. Otherwise, take the following actions based on the system state: \n+        /// Case WaitingForEvaluator\n+        ///     This happens in the middle of submitting contexts. We just need to remove the failed evaluator \n+        ///     from EvaluatorManager and remove associated active context, if any, from ActiveContextManager\n+        ///     then checks if the system is recoverable. If yes, request another Evaluator \n+        ///     If not recoverable, set system state to Fail then execute Fail action\n+        /// Case SubmittingTasks/TasksRunning\n+        ///     This happens either in the middle of Task submitting or all the tasks are running\n+        ///     Changes the system state to ShuttingDown\n+        ///     Removes Evaluator and associated context from EvaluatorManager and ActiveContextManager\n+        ///     Removes associated task from running task if it was running and change the task state to TaskFailedByEvaluatorFailure\n+        ///     Closes all the other running tasks\n+        ///     Try to recover in case it is the last failure received\n+        /// Case ShuttingDown\n+        ///     This happens when we have received either FailedEvaluator or FailedTask, some tasks are running some are in closing.\n+        ///     Removes Evaluator and associated context from EvaluatorManager and ActiveContextManager\n+        ///     Removes associated task from running task if it was running, changes the task state to ClosedTask if it was waiting for close\n+        ///     otherwise changes the task state to FailedTaskEvaluatorError\n+        ///     Try to recover in case it is the last failure received\n+        /// Other cases - not expected \n+        /// </summary>\n+        /// <param name=\"failedEvaluator\"></param>\n+        public void OnNext(IFailedEvaluator failedEvaluator)\n+        {\n+            lock (_lock)\n+            {\n+                if (_taskManager.AreAllTasksCompleted())\n+                {\n+                    Logger.Log(Level.Verbose, \"Evaluator with Id: {0} failed but IMRU task is completed. So ignoring.\", failedEvaluator.Id);\n+                    return;\n+                }\n+                Logger.Log(Level.Info, \"Evaluator with Id: {0} failed with Exception: {1} in retry # {2}.\", failedEvaluator.Id, failedEvaluator.EvaluatorException, _numberOfRetryForFaultTolerant);\n+\n+                var isMaster = _evaluatorManager.IsMasterEvaluatorId(failedEvaluator.Id);\n+                _evaluatorManager.RecordFailedEvaluator(failedEvaluator.Id);\n+                _contextManager.RemoveFailedContextInFailedEvaluator(failedEvaluator);\n+\n+                switch (_systemState.CurrentState)\n+                {\n+                    case SystemState.WaitingForEvaluator:\n+                        if (IsRecoverable())\n+                        {\n+                            if (isMaster)\n+                            {\n+                                Logger.Log(Level.Info, \"Requesting a master Evaluator.\");\n+                                _evaluatorManager.RequestUpdateEvaluator();\n+                            }\n+                            else\n+                            {\n+                                _serviceAndContextConfigurationProvider.RemoveEvaluatorIdFromPartitionIdProvider(failedEvaluator.Id);\n+                                Logger.Log(Level.Info, \"Requesting mapper Evaluators.\");\n+                                _evaluatorManager.RequestMapEvaluators(1);\n+                            }\n+                        }\n+                        else\n+                        {\n+                            Logger.Log(Level.Warning, \"The system is not recoverable, change the state to Fail.\");\n+                            _systemState.MoveNext(SystemStateEvent.NotRecoverable);\n+                            FailAction();\n+                        }\n+                        break;\n+\n+                    case SystemState.SubmittingTasks:\n+                    case SystemState.TasksRunning:\n+                        // set system state to ShuttingDown\n+                        _systemState.MoveNext(SystemStateEvent.FailedNode);\n+                        _taskManager.RecordTaskFailWhenReceivingFailedEvaluator(failedEvaluator);\n+                        _taskManager.CloseAllRunningTasks(TaskManager.CloseTaskByDriver);\n+\n+                        // Push evaluator id back to PartitionIdProvider if it is not master\n+                        if (!isMaster)\n+                        {\n+                            _serviceAndContextConfigurationProvider.RemoveEvaluatorIdFromPartitionIdProvider(failedEvaluator.Id);\n+                        }\n+\n+                        TryRecovery();","path":"lang/cs/Org.Apache.REEF.IMRU/OnREEF/Driver/IMRUDriver.cs","position":571,"original_position":571,"commit_id":"ce32f76cd61c154d96a23e3c8e18e46efb301432","original_commit_id":"ce32f76cd61c154d96a23e3c8e18e46efb301432","user":{"login":"dkm2110","id":151031,"avatar_url":"https://avatars.githubusercontent.com/u/151031?v=3","gravatar_id":"","url":"https://api.github.com/users/dkm2110","html_url":"https://github.com/dkm2110","followers_url":"https://api.github.com/users/dkm2110/followers","following_url":"https://api.github.com/users/dkm2110/following{/other_user}","gists_url":"https://api.github.com/users/dkm2110/gists{/gist_id}","starred_url":"https://api.github.com/users/dkm2110/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dkm2110/subscriptions","organizations_url":"https://api.github.com/users/dkm2110/orgs","repos_url":"https://api.github.com/users/dkm2110/repos","events_url":"https://api.github.com/users/dkm2110/events{/privacy}","received_events_url":"https://api.github.com/users/dkm2110/received_events","type":"User","site_admin":false},"body":"This whole function is in lock and once you call StartAction() in TryRecovery() and request for more map evaluators, mapperCount there will always be one right? this is because no other IFaileEvaluator can be received in between because of lock.","created_at":"2016-06-10T05:24:32Z","updated_at":"2016-06-10T05:24:32Z","html_url":"https://github.com/apache/reef/pull/1033#discussion_r66563113","pull_request_url":"https://api.github.com/repos/apache/reef/pulls/1033","_links":{"self":{"href":"https://api.github.com/repos/apache/reef/pulls/comments/66563113"},"html":{"href":"https://github.com/apache/reef/pull/1033#discussion_r66563113"},"pull_request":{"href":"https://api.github.com/repos/apache/reef/pulls/1033"}}},"pull_request":{"url":"https://api.github.com/repos/apache/reef/pulls/1033","id":72822636,"html_url":"https://github.com/apache/reef/pull/1033","diff_url":"https://github.com/apache/reef/pull/1033.diff","patch_url":"https://github.com/apache/reef/pull/1033.patch","issue_url":"https://api.github.com/repos/apache/reef/issues/1033","number":1033,"state":"open","locked":false,"title":"[REEF-1251] IMRU Driver handlers for fault tolerant","user":{"login":"jwang98052","id":5666504,"avatar_url":"https://avatars.githubusercontent.com/u/5666504?v=3","gravatar_id":"","url":"https://api.github.com/users/jwang98052","html_url":"https://github.com/jwang98052","followers_url":"https://api.github.com/users/jwang98052/followers","following_url":"https://api.github.com/users/jwang98052/following{/other_user}","gists_url":"https://api.github.com/users/jwang98052/gists{/gist_id}","starred_url":"https://api.github.com/users/jwang98052/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jwang98052/subscriptions","organizations_url":"https://api.github.com/users/jwang98052/orgs","repos_url":"https://api.github.com/users/jwang98052/repos","events_url":"https://api.github.com/users/jwang98052/events{/privacy}","received_events_url":"https://api.github.com/users/jwang98052/received_events","type":"User","site_admin":false},"body":"* IMRU Driver handler re-write to support fault tolerant\r\n* ServiceAndContextConfigurationProvider refactor and clean up for the updated IMRU driver\r\n* IMRUClient update to use the updated IMRUDriver\r\n* Minor changes in ActiveContextManager\r\n* Test case will follow after REEF-1408 is merged.\r\n\r\nJIRA: [REEF-1251](https://issues.apache.org/jira/browse/REEF-1251)\r\nThis closes","created_at":"2016-06-07T06:36:31Z","updated_at":"2016-06-10T05:24:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0d300e973dca8f56fef440d73b8d3ab696b98b43","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/apache/reef/pulls/1033/commits","review_comments_url":"https://api.github.com/repos/apache/reef/pulls/1033/comments","review_comment_url":"https://api.github.com/repos/apache/reef/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/reef/issues/1033/comments","statuses_url":"https://api.github.com/repos/apache/reef/statuses/ce32f76cd61c154d96a23e3c8e18e46efb301432","head":{"label":"jwang98052:REEF-1251","ref":"REEF-1251","sha":"ce32f76cd61c154d96a23e3c8e18e46efb301432","user":{"login":"jwang98052","id":5666504,"avatar_url":"https://avatars.githubusercontent.com/u/5666504?v=3","gravatar_id":"","url":"https://api.github.com/users/jwang98052","html_url":"https://github.com/jwang98052","followers_url":"https://api.github.com/users/jwang98052/followers","following_url":"https://api.github.com/users/jwang98052/following{/other_user}","gists_url":"https://api.github.com/users/jwang98052/gists{/gist_id}","starred_url":"https://api.github.com/users/jwang98052/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jwang98052/subscriptions","organizations_url":"https://api.github.com/users/jwang98052/orgs","repos_url":"https://api.github.com/users/jwang98052/repos","events_url":"https://api.github.com/users/jwang98052/events{/privacy}","received_events_url":"https://api.github.com/users/jwang98052/received_events","type":"User","site_admin":false},"repo":{"id":25940156,"name":"reef","full_name":"jwang98052/reef","owner":{"login":"jwang98052","id":5666504,"avatar_url":"https://avatars.githubusercontent.com/u/5666504?v=3","gravatar_id":"","url":"https://api.github.com/users/jwang98052","html_url":"https://github.com/jwang98052","followers_url":"https://api.github.com/users/jwang98052/followers","following_url":"https://api.github.com/users/jwang98052/following{/other_user}","gists_url":"https://api.github.com/users/jwang98052/gists{/gist_id}","starred_url":"https://api.github.com/users/jwang98052/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jwang98052/subscriptions","organizations_url":"https://api.github.com/users/jwang98052/orgs","repos_url":"https://api.github.com/users/jwang98052/repos","events_url":"https://api.github.com/users/jwang98052/events{/privacy}","received_events_url":"https://api.github.com/users/jwang98052/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jwang98052/reef","description":"Mirror of Apache REEF (Incubating)","fork":true,"url":"https://api.github.com/repos/jwang98052/reef","forks_url":"https://api.github.com/repos/jwang98052/reef/forks","keys_url":"https://api.github.com/repos/jwang98052/reef/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jwang98052/reef/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jwang98052/reef/teams","hooks_url":"https://api.github.com/repos/jwang98052/reef/hooks","issue_events_url":"https://api.github.com/repos/jwang98052/reef/issues/events{/number}","events_url":"https://api.github.com/repos/jwang98052/reef/events","assignees_url":"https://api.github.com/repos/jwang98052/reef/assignees{/user}","branches_url":"https://api.github.com/repos/jwang98052/reef/branches{/branch}","tags_url":"https://api.github.com/repos/jwang98052/reef/tags","blobs_url":"https://api.github.com/repos/jwang98052/reef/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jwang98052/reef/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jwang98052/reef/git/refs{/sha}","trees_url":"https://api.github.com/repos/jwang98052/reef/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jwang98052/reef/statuses/{sha}","languages_url":"https://api.github.com/repos/jwang98052/reef/languages","stargazers_url":"https://api.github.com/repos/jwang98052/reef/stargazers","contributors_url":"https://api.github.com/repos/jwang98052/reef/contributors","subscribers_url":"https://api.github.com/repos/jwang98052/reef/subscribers","subscription_url":"https://api.github.com/repos/jwang98052/reef/subscription","commits_url":"https://api.github.com/repos/jwang98052/reef/commits{/sha}","git_commits_url":"https://api.github.com/repos/jwang98052/reef/git/commits{/sha}","comments_url":"https://api.github.com/repos/jwang98052/reef/comments{/number}","issue_comment_url":"https://api.github.com/repos/jwang98052/reef/issues/comments{/number}","contents_url":"https://api.github.com/repos/jwang98052/reef/contents/{+path}","compare_url":"https://api.github.com/repos/jwang98052/reef/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jwang98052/reef/merges","archive_url":"https://api.github.com/repos/jwang98052/reef/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jwang98052/reef/downloads","issues_url":"https://api.github.com/repos/jwang98052/reef/issues{/number}","pulls_url":"https://api.github.com/repos/jwang98052/reef/pulls{/number}","milestones_url":"https://api.github.com/repos/jwang98052/reef/milestones{/number}","notifications_url":"https://api.github.com/repos/jwang98052/reef/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jwang98052/reef/labels{/name}","releases_url":"https://api.github.com/repos/jwang98052/reef/releases{/id}","deployments_url":"https://api.github.com/repos/jwang98052/reef/deployments","created_at":"2014-10-29T20:32:40Z","updated_at":"2016-06-01T23:24:31Z","pushed_at":"2016-06-10T00:43:50Z","git_url":"git://github.com/jwang98052/reef.git","ssh_url":"git@github.com:jwang98052/reef.git","clone_url":"https://github.com/jwang98052/reef.git","svn_url":"https://github.com/jwang98052/reef","homepage":null,"size":37424,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"apache:master","ref":"master","sha":"798f2dbb075107330c8be575182a28d8fa19e89f","user":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":25623941,"name":"reef","full_name":"apache/reef","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/reef","description":"Mirror of Apache REEF","fork":false,"url":"https://api.github.com/repos/apache/reef","forks_url":"https://api.github.com/repos/apache/reef/forks","keys_url":"https://api.github.com/repos/apache/reef/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/reef/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/reef/teams","hooks_url":"https://api.github.com/repos/apache/reef/hooks","issue_events_url":"https://api.github.com/repos/apache/reef/issues/events{/number}","events_url":"https://api.github.com/repos/apache/reef/events","assignees_url":"https://api.github.com/repos/apache/reef/assignees{/user}","branches_url":"https://api.github.com/repos/apache/reef/branches{/branch}","tags_url":"https://api.github.com/repos/apache/reef/tags","blobs_url":"https://api.github.com/repos/apache/reef/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/reef/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/reef/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/reef/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/reef/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/reef/languages","stargazers_url":"https://api.github.com/repos/apache/reef/stargazers","contributors_url":"https://api.github.com/repos/apache/reef/contributors","subscribers_url":"https://api.github.com/repos/apache/reef/subscribers","subscription_url":"https://api.github.com/repos/apache/reef/subscription","commits_url":"https://api.github.com/repos/apache/reef/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/reef/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/reef/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/reef/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/reef/contents/{+path}","compare_url":"https://api.github.com/repos/apache/reef/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/reef/merges","archive_url":"https://api.github.com/repos/apache/reef/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/reef/downloads","issues_url":"https://api.github.com/repos/apache/reef/issues{/number}","pulls_url":"https://api.github.com/repos/apache/reef/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/reef/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/reef/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/reef/labels{/name}","releases_url":"https://api.github.com/repos/apache/reef/releases{/id}","deployments_url":"https://api.github.com/repos/apache/reef/deployments","created_at":"2014-10-23T07:00:10Z","updated_at":"2016-05-26T20:59:10Z","pushed_at":"2016-06-10T00:43:51Z","git_url":"git://github.com/apache/reef.git","ssh_url":"git@github.com:apache/reef.git","clone_url":"https://github.com/apache/reef.git","svn_url":"https://github.com/apache/reef","homepage":"","size":48547,"stargazers_count":51,"watchers_count":51,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":59,"mirror_url":"git://git.apache.org/reef.git","open_issues_count":6,"forks":59,"open_issues":6,"watchers":51,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/reef/pulls/1033"},"html":{"href":"https://github.com/apache/reef/pull/1033"},"issue":{"href":"https://api.github.com/repos/apache/reef/issues/1033"},"comments":{"href":"https://api.github.com/repos/apache/reef/issues/1033/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/reef/pulls/1033/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/reef/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/reef/pulls/1033/commits"},"statuses":{"href":"https://api.github.com/repos/apache/reef/statuses/ce32f76cd61c154d96a23e3c8e18e46efb301432"}}}}
{"actor":{"display_login":"dkm2110"}}