You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yarn-issues@hadoop.apache.org by "kyungwan nam (JIRA)" <ji...@apache.org> on 2018/10/26 04:14:00 UTC

[jira] [Commented] (YARN-8694) app flex with relative changes does not work

    [ https://issues.apache.org/jira/browse/YARN-8694?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16664632#comment-16664632 ] 

kyungwan nam commented on YARN-8694:
------------------------------------

attaches a new patch 002.
It will get the service status from api server prior to requesting flex.
so, we can handle relative changes.

> app flex with relative changes does not work
> --------------------------------------------
>
>                 Key: YARN-8694
>                 URL: https://issues.apache.org/jira/browse/YARN-8694
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: yarn-native-services
>    Affects Versions: 3.1.1
>            Reporter: kyungwan nam
>            Priority: Major
>         Attachments: YARN-8694.001.patch, YARN-8694.002.patch
>
>
> I'd like to increase 2 containers as belows.
> {code:java}
> yarn app -flex my-sleeper -component sleeper +2{code}
> but, It did not work. it seems to request 2, not +2.
>  
> ApiServiceClient.actionFlex
> {code:java}
> @Override
> public int actionFlex(String appName, Map<String, String> componentCounts)
>     throws IOException, YarnException {
>   int result = EXIT_SUCCESS;
>   try {
>     Service service = new Service();
>     service.setName(appName);
>     service.setState(ServiceState.FLEX);
>     for (Map.Entry<String, String> entry : componentCounts.entrySet()) {
>       Component component = new Component();
>       component.setName(entry.getKey());
>       Long numberOfContainers = Long.parseLong(entry.getValue());
>       component.setNumberOfContainers(numberOfContainers);
>       service.addComponent(component);
>     }
>     String buffer = jsonSerDeser.toJson(service);
>     ClientResponse response = getApiClient(getServicePath(appName))
>         .put(ClientResponse.class, buffer);{code}
> It looks like there is no code, which handle “+”, “-“ in ApiServiceClient.actionFlex



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-issues-help@hadoop.apache.org