marcaurele commented on a change in pull request #837: CLOUDSTACK-8855 Improve
Error Message for Host Alert State and reconnect host API.
URL: https://github.com/apache/cloudstack/pull/837#discussion_r159381344
##########
File path:
engine/orchestration/src/com/cloud/agent/manager/ClusteredAgentManagerImpl.java
##########
@@ -357,19 +357,12 @@ public boolean executeUserRequest(final long hostId,
final Event event) throws A
}
@Override
- public boolean reconnect(final long hostId) {
- Boolean result;
- try {
- result = propagateAgentEvent(hostId, Event.ShutdownRequested);
- if (result != null) {
- return result;
- }
- } catch (final AgentUnavailableException e) {
- s_logger.debug("cannot propagate agent reconnect because agent is
not available", e);
- return false;
+ public void reconnect(final long hostId) throws CloudRuntimeException,
AgentUnavailableException {
+ Boolean result = propagateAgentEvent(hostId, Event.ShutdownRequested);
+ if (result!=null && !result) {
+ throw new CloudRuntimeException("Failed to propagating agent
change request event:" + Event.ShutdownRequested + " to host:" + hostId);
Review comment:
nitpick, grammar typo: `Failed to propagate agent change....`
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services