[ 
https://issues.apache.org/jira/browse/AMBARI-19701?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Richard Zang updated AMBARI-19701:
----------------------------------
    Description: 

We need to identify if call is made when
* Cluster is being created (first call)
* Add service
* Just landing on a page and only need config attributes

Possible change to the json data send in POST - 
{code}
{
"recommend":"configurations",
 "user_context" : { "operation" : "ClusterCreate" } <== add this
"hosts"....
{code}

*Cluster create (first call):*
{code}"user_context": {"operation" : "ClusterCreate"}{code}
*Add service (first call):*
{code}"user_context": {"operation" : "AddService", "operation_details" : 
"HDFS,YARN"}{code}
*Landing on a config page:*
{code}"user_context": {"operation" : "RecommendAttribute"}{code}
*Config edit on a config page: (lower priority)*
{code}"user_context": {"operation" : "EditConfig"}{code}

  was:
Stack advisor is an inherently stateless code. This makes it difficult to know 
when the call is being made if you need to specialize the behavior of the stack 
advisor.

E.g.
* Use already set value or suggest (some code currently relies on if changed 
values list is empty)
** The assumption breaks down when call is made while landing on a page and 
when you do Add Service

For 2.5.0 we need minimal context to support RMP-8012 and simplifying some llap 
related calculations.

We need to identify if call is made when
* Cluster is being created (first call)
* Add service
* Just landing on a page and only need config attributes

Possible change to the json data send in POST - 
{code}
{
"recommend":"configurations",
 "user_context" : { "operation" : "ClusterCreate" } <== add this
"hosts"....
{code}

*Cluster create (first call):*
{code}"user_context": {"operation" : "ClusterCreate"}{code}
*Add service (first call):*
{code}"user_context": {"operation" : "AddService", "operation_details" : 
"HDFS,YARN"}{code}
*Landing on a config page:*
{code}"user_context": {"operation" : "RecommendAttribute"}{code}
*Config edit on a config page: (lower priority)*
{code}"user_context": {"operation" : "EditConfig"}{code}


> Provide minimal call context from UI when making stack advisor calls
> --------------------------------------------------------------------
>
>                 Key: AMBARI-19701
>                 URL: https://issues.apache.org/jira/browse/AMBARI-19701
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-web
>    Affects Versions: 2.5.0
>            Reporter: Richard Zang
>            Assignee: Richard Zang
>             Fix For: 2.5.0
>
>         Attachments: AMBARI-19701-branch-2.5.patch, AMBARI-19701_trunk.patch
>
>
> We need to identify if call is made when
> * Cluster is being created (first call)
> * Add service
> * Just landing on a page and only need config attributes
> Possible change to the json data send in POST - 
> {code}
> {
> "recommend":"configurations",
>  "user_context" : { "operation" : "ClusterCreate" } <== add this
> "hosts"....
> {code}
> *Cluster create (first call):*
> {code}"user_context": {"operation" : "ClusterCreate"}{code}
> *Add service (first call):*
> {code}"user_context": {"operation" : "AddService", "operation_details" : 
> "HDFS,YARN"}{code}
> *Landing on a config page:*
> {code}"user_context": {"operation" : "RecommendAttribute"}{code}
> *Config edit on a config page: (lower priority)*
> {code}"user_context": {"operation" : "EditConfig"}{code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to