[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-13 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #22: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/22#issuecomment-438305725
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/45/
   Test PASSed.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3h 40m
>  Remaining Estimate: 20m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-13 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

tobias-istvan opened a new pull request #22: [AMBARI-24551] [Log Search UI] get 
rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/22
 
 
   # What changes were proposed in this pull request?
   
   Branch fix for #5 


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3h 40m
>  Remaining Estimate: 20m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-13 Thread Hudson (JIRA)


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

Hudson commented on AMBARI-24551:
-

SUCCESS: Integrated in Jenkins build Ambari-LogSearch-master-Commit #29 (See 
[https://builds.apache.org/job/Ambari-LogSearch-master-Commit/29/])
[AMBARI-24551] [Log Search UI] get rid of redundant requests after 
(tobias.istvan: 
[https://gitbox.apache.org/repos/asf?p=ambari-logsearch.git&a=commit&h=d09e5c320836b7b61edaa64c08ea1a7a75b3036d])
* (edit) ambari-logsearch-web/src/app/services/history-manager.service.ts
[AMBARI-24551] [Log Search UI] get rid of redundant requests after 
(tobias.istvan: 
[https://gitbox.apache.org/repos/asf?p=ambari-logsearch.git&a=commit&h=dcadc20a3d0479a8dd87b4f0e3a3787e12902695])
* (edit) 
ambari-logsearch-web/src/app/modules/shared/components/dropdown-list/dropdown-list.component.html
* (edit) ambari-logsearch-web/src/app/services/history-manager.service.ts
* (edit) ambari-logsearch-web/src/app/services/logs-container.service.ts
* (edit) ambari-logsearch-web/src/app/services/logs-filtering-utils.service.ts
[AMBARI-24551] [Log Search UI] get rid of redundant requests after 
(tobias.istvan: 
[https://gitbox.apache.org/repos/asf?p=ambari-logsearch.git&a=commit&h=30c315786837a9a89b164338c0ba4893d70bcd9a])
* (edit) 
ambari-logsearch-web/src/app/components/menu-button/menu-button.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/time-range-picker/time-range-picker.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/filter-button/filter-button.component.ts
* (edit) ambari-logsearch-web/src/app/services/filter-history.guard.ts
* (edit) 
ambari-logsearch-web/src/app/modules/shared/components/dropdown-button/dropdown-button.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/logs-container/logs-container.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/cluster-filter/cluster-filter.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/pagination-controls/pagination-controls.component.ts
* (edit) 
ambari-logsearch-web/src/app/modules/shared/components/filter-dropdown/filter-dropdown.component.ts
* (edit) 
ambari-logsearch-web/src/app/modules/shared/components/dropdown-list/dropdown-list.component.ts
* (edit) ambari-logsearch-web/src/app/services/history-manager.service.ts
* (edit) 
ambari-logsearch-web/src/app/components/search-box/search-box.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/log-index-filter/log-index-filter.component.ts
[AMBARI-24551] [Log Search UI] get rid of redundant requests after 
(tobias.istvan: 
[https://gitbox.apache.org/repos/asf?p=ambari-logsearch.git&a=commit&h=1990a758cdd883d677c7a18899e4eedcf527106b])
* (edit) ambari-logsearch-web/src/app/classes/models/store.ts
* (edit) 
ambari-logsearch-web/src/app/components/filter-history-manager/filter-history-manager.component.html
* (edit) ambari-logsearch-web/src/app/modules/app-load/app-load.module.ts
* (edit) ambari-logsearch-web/src/app/store/reducers/filter-history.reducers.ts
* (edit) ambari-logsearch-web/src/app/app-routing.module.ts
* (edit) ambari-logsearch-web/src/app/services/filter-history.guard.ts
* (edit) 
ambari-logsearch-web/src/app/components/login-form/login-form.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/action-menu/action-menu.component.ts
* (edit) 
ambari-logsearch-web/src/app/store/selectors/data-availability.selectors.ts
* (edit) ambari-logsearch-web/src/app/components/app.component.ts
* (edit) 
ambari-logsearch-web/src/app/store/selectors/filter-history.selectors.ts
* (edit) 
ambari-logsearch-web/src/app/components/action-menu/action-menu.component.html
* (edit) 
ambari-logsearch-web/src/app/components/filter-history-manager/filter-history-manager.component.ts
* (edit) 
ambari-logsearch-web/src/app/components/action-menu/action-menu.component.less
* (edit) ambari-logsearch-web/src/app/store/selectors/app-state.selectors.ts
* (edit) ambari-logsearch-web/src/app/app.module.ts
* (edit) ambari-logsearch-web/src/app/store/selectors/auth.selectors.ts
[AMBARI-24551] [Log Search UI] get rid of redundant requests after 
(tobias.istvan: 
[https://gitbox.apache.org/repos/asf?p=ambari-logsearch.git&a=commit&h=12fc1b7261d396c7d7c7774a9277c536c763e1c2])
* (edit) 
ambari-logsearch-web/src/app/components/filter-history-manager/filter-history-manager.component.ts
* (add) ambari-logsearch-web/src/app/services/filter-labels.service.ts
* (edit) 
ambari-logsearch-web/src/app/components/logs-container/logs-container.component.html
* (add) ambari-logsearch-web/src/app/store/selectors/components.selectors.ts
* (edit) 
ambari-logsearch-web/src/app/components/action-menu/action-menu.component.ts
* (edit) 
ambari-logsearch-web/src/app/store/selectors/filter-history.selectors.ts
* (edit) ambari-logsearch-web/src/app/store/selectors/app-state.selectors.ts
* (edit) ambari-logsearch-web/sr

[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-13 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-438263607
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/44/
   Test PASSed.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3h 40m
>  Remaining Estimate: 20m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-13 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

aBabiichuk commented on a change in pull request #5: [AMBARI-24551] [Log Search 
UI] get rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#discussion_r233022631
 
 

 ##
 File path: 
ambari-logsearch-web/src/app/components/action-menu/action-menu.component.ts
 ##
 @@ -74,27 +72,13 @@ export class ActionMenuComponent  implements OnInit, 
OnDestroy {
   }
 
   ngOnInit() {
-this.subscriptions.push(
-  this.selectedClusterName$.subscribe(
-(clusterName: string) => this.setModalSubmitDisabled(!(!!clusterName))
-  )
+this.selectedClusterName$.takeUntil(this.destroyed$).subscribe(
+  (clusterName: string) => this.setModalSubmitDisabled(!(!!clusterName))
 
 Review comment:
   Why not just `setModalSubmitDisabled(!clusterName)`?


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3h 40m
>  Remaining Estimate: 20m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-13 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

aBabiichuk commented on a change in pull request #5: [AMBARI-24551] [Log Search 
UI] get rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#discussion_r233011840
 
 

 ##
 File path: 
ambari-logsearch-web/src/app/components/filter-history-manager/filter-history-manager.component.ts
 ##
 @@ -0,0 +1,382 @@
+import { Component, OnInit, OnDestroy, Input } from '@angular/core';
+import { Subject } from 'rxjs/Subject';
+import { Observable } from 'rxjs/Observable';
+import { Store } from '@ngrx/store';
+import { AppStore } from '@app/classes/models/store';
+import {
+  selectActiveFilterHistoryChangesUndoItems,
+  selectActiveFilterHistoryChangesRedoItems,
+  selectActiveFilterHistoryChanges,
+  selectActiveFilterHistoryChangeIndex
+} from '@app/store/selectors/filter-history.selectors';
+import { FilterUrlParamChange } from 
'@app/classes/models/filter-url-param-change.interface';
+import { Router, UrlTree, UrlSegmentGroup } from '@angular/router';
+import {
+  LogsFilteringUtilsService,
+  defaultUrlParamsForFiltersByLogsType,
+  UrlParamDifferences,
+  UrlParamsDifferenceType
+} from '@app/services/logs-filtering-utils.service';
+import { selectActiveLogsType } from 
'@app/store/selectors/app-state.selectors';
+import { LogsType } from '@app/classes/string';
+import { TranslateService } from '@ngx-translate/core';
+import { selectComponentsLabels } from 
'@app/store/selectors/components.selectors';
+import { selectDefaultAuditLogsFields } from 
'@app/store/selectors/audit-logs-fields.selectors';
+import { selectServiceLogsFieldState } from 
'@app/store/selectors/service-logs-fields.selectors';
+import { BehaviorSubject } from 'rxjs/BehaviorSubject';
+import { ListItem } from '@app/classes/list-item';
+
+import * as moment from 'moment';
+import { SearchBoxParameter } from '@app/classes/filtering';
+import { LogField } from '@app/classes/object';
+
+export const urlParamsActionType = {
+  clusters: 'multiple',
+  timeRange: 'single',
+  components: 'multiple',
+  levels: 'multiple',
+  hosts: 'multiple',
+  sortingKey: 'single',
+  sortingType: 'single',
+  pageSize: 'single',
+  page: 'single',
+  query: 'query',
+  users: 'multiple'
+};
+
+@Component({
+  selector: 'filter-history-manager',
+  templateUrl: './filter-history-manager.component.html',
+  styleUrls: ['./filter-history-manager.component.less']
+})
+export class FilterHistoryManagerComponent implements OnInit, OnDestroy {
+
+  @Input()
+  labelSeparator = ' | ';
+
+  activeLogsType$: Observable = 
this.store.select(selectActiveLogsType);
+
+  componentsLabels$: Observable<{[key: string]: string}> = 
this.store.select(selectComponentsLabels);
+  componentsLabelsLocalCopy$: BehaviorSubject<{[key: string]: string}> = new 
BehaviorSubject({});
+
+  activeHistoryChangeIndex$: Observable = 
this.store.select(selectActiveFilterHistoryChangeIndex);
+
+  activeHistoryItems$: Observable = 
this.store.select(selectActiveFilterHistoryChanges);
+  hasActiveHistoryItems$: Observable = this.activeHistoryItems$
+.map(items => items && items.length > 0).startWith(false);
+  activeHistoryItemLabels$: Observable<{[key: string]: string}[]> = 
Observable.combineLatest(
+this.activeHistoryItems$,
+this.activeLogsType$,
+this.componentsLabels$ // this is just to recalculate the labels when the 
components arrived
+  ).map(result => this.mapHistoryItemsToHistoryItemLabels(result));
+  activeHistoryListItems$: Observable = Observable.combineLatest(
+this.activeHistoryItemLabels$.map((items) => 
this.mapHistoryItemLabelsToListItems(items, this.labelSeparator)),
+this.store.select(selectActiveFilterHistoryChangeIndex)
+  ).map(([listItems, changeIndex]: [ListItem[], number]): ListItem[] => 
listItems.map((item, index) => {
+item.cssClass = index === changeIndex ? 'active' : (index === 0 ? 
'initial' : '');
+return item;
+  }));
+
+  activeUndoHistoryItems$: Observable = 
this.store.select(selectActiveFilterHistoryChangesUndoItems);
+  hasActiveUndoHistoryItems$: Observable = 
this.activeUndoHistoryItems$
+.map(items => items && items.length > 0).startWith(false);
+  activeUndoHistoryListItems$: Observable = 
Observable.combineLatest(
+this.activeHistoryListItems$,
+this.store.select(selectActiveFilterHistoryChangeIndex)
+  ).map(([listItems, activeChangeIndex]: [ListItem[], number]): ListItem[] => 
listItems.slice(0, activeChangeIndex));
+
+  activeRedoHistoryItems$: Observable = 
this.store.select(selectActiveFilterHistoryChangesRedoItems);
+  hasActiveRedoHistoryItems$: Observable = 
this.activeRedoHistoryItems$
+.map(items => items && items.length > 0).startWith(false);
+  a

[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-12 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437946148
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/39/
   Test FAILed.
   Test FAILured.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-12 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437956174
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/41/
   Test PASSed.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-12 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437957577
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/42/
   Test PASSed.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-12 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

tobias-istvan commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437956593
 
 
   @aBabiichuk
   I completely refactored the history manager. The initial reason was to 
simplify the business logic around the history management, also make it more 
URL handling compatible since the history is connected to the linkable URL.
   
   I followed the previous approach which is use more action/effects/reducers 
over services in order to decouple the direct dependencies.
   
   The main reason of the redundant request was the wrong implementation of the 
`ControlValueAccessor` interface.
   
   I also added some UX improvements to indicate when a request is in progress 
in the background. There is a global notification and added some specific ones 
for log tables and graphs.


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-12 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437949057
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/40/
   Test FAILed.
   Test FAILured.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-12 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437945084
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/38/
   Test FAILed.
   Test FAILured.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-10 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437580496
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/35/
   Test FAILed.
   Test FAILured.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-09 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437424211
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/29/
   Test FAILed.
   Test FAILured.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-11-08 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-437017973
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/28/
   Test FAILed.
   Test FAILured.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-30 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-434385923
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/21/
   Test FAILed.
   Test FAILured.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-26 Thread JIRA


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

Olivér Szabó commented on AMBARI-24551:
---

as minor issue, moving it out to 2.8

> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.8.0
>
>   Original Estimate: 4h
>  Time Spent: 3.5h
>  Remaining Estimate: 0.5h
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-09 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

aBabiichuk commented on a change in pull request #5: [AMBARI-24551] [Log Search 
UI] get rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#discussion_r223692185
 
 

 ##
 File path: ambari-logsearch-web/src/app/services/history-manager.service.ts
 ##
 @@ -209,18 +190,14 @@ export class HistoryManagerService {
* @returns {ListItem[]}
*/
   get redoItems(): ListItem[] {
-const allItems = this.activeHistory.slice().reverse();
+const allItems = [...this.activeHistory].reverse();
 let startIndex = allItems.findIndex((item: ListItem): boolean => {
-return item.value.previousChangeId === this.currentHistoryItemId && 
!item.value.isUndoOrRedo;
-  }),
-  endIndex = allItems.slice(startIndex + 1).findIndex((item: ListItem): 
boolean => item.value.isUndoOrRedo);
+  return item.value.previousChangeId === this.currentHistoryItemId;
+});
 if (startIndex === -1) {
   startIndex = allItems.length;
 }
-if (endIndex === -1) {
 
 Review comment:
   This `isUndoOrRedo`/`endIndex` logic shouldn't be removed here. It's needed 
to handle the situation when after some undoing/redoing user goes on with 
non-historical filters changes, so there's nothing to redo. Sorry for my 
omission in previous comment.
   P.S. Getting rid of `hasNoPendingUndoOrRedo` looks OK to me.


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.7.2
>
>   Original Estimate: 4h
>  Time Spent: 2h 50m
>  Remaining Estimate: 1h 10m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-09 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

aBabiichuk commented on a change in pull request #5: [AMBARI-24551] [Log Search 
UI] get rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#discussion_r223692185
 
 

 ##
 File path: ambari-logsearch-web/src/app/services/history-manager.service.ts
 ##
 @@ -209,18 +190,14 @@ export class HistoryManagerService {
* @returns {ListItem[]}
*/
   get redoItems(): ListItem[] {
-const allItems = this.activeHistory.slice().reverse();
+const allItems = [...this.activeHistory].reverse();
 let startIndex = allItems.findIndex((item: ListItem): boolean => {
-return item.value.previousChangeId === this.currentHistoryItemId && 
!item.value.isUndoOrRedo;
-  }),
-  endIndex = allItems.slice(startIndex + 1).findIndex((item: ListItem): 
boolean => item.value.isUndoOrRedo);
+  return item.value.previousChangeId === this.currentHistoryItemId;
+});
 if (startIndex === -1) {
   startIndex = allItems.length;
 }
-if (endIndex === -1) {
 
 Review comment:
   This isUndoOrRedo/endIndex logic shouldn't be removed here. It's needed to 
handle the situation when after some undoing/redoing user goes on with 
non-historical filters changes, so there's nothing to redo. Sorry for my 
omission in previous comment.
   P.S. Getting rid of hasNoPendingUndoOrRedo looks OK to me.


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.7.2
>
>   Original Estimate: 4h
>  Time Spent: 2h 50m
>  Remaining Estimate: 1h 10m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-09 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-428178681
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/9/
   Test PASSed.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.7.2
>
>   Original Estimate: 4h
>  Time Spent: 2h 50m
>  Remaining Estimate: 1h 10m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-08 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

aBabiichuk commented on a change in pull request #5: [AMBARI-24551] [Log Search 
UI] get rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#discussion_r223407546
 
 

 ##
 File path: ambari-logsearch-web/src/app/services/history-manager.service.ts
 ##
 @@ -292,19 +292,12 @@ export class HistoryManagerService {
* @param {object} value
*/
   private handleUndoOrRedo(value: object): void {
-const filtersForm = this.logsContainerService.filtersForm;
 this.hasNoPendingUndoOrRedo = false;
 
 Review comment:
   Looks like `hasNoPendingUndoOrRedo` and `isUndoOrRedo` aren't needed any 
more, as well as `onFormValueChanges` which handles those values


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.7.2
>
>   Original Estimate: 4h
>  Time Spent: 2h 50m
>  Remaining Estimate: 1h 10m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-08 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

aBabiichuk commented on a change in pull request #5: [AMBARI-24551] [Log Search 
UI] get rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#discussion_r223407546
 
 

 ##
 File path: ambari-logsearch-web/src/app/services/history-manager.service.ts
 ##
 @@ -292,19 +292,12 @@ export class HistoryManagerService {
* @param {object} value
*/
   private handleUndoOrRedo(value: object): void {
-const filtersForm = this.logsContainerService.filtersForm;
 this.hasNoPendingUndoOrRedo = false;
 
 Review comment:
   Looks like `hasNoPendingUndoOrRedo` and `isUndoOrRedo` aren't needed any more


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.7.2
>
>   Original Estimate: 4h
>  Time Spent: 2h 50m
>  Remaining Estimate: 1h 10m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-08 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

asfgit commented on issue #5: [AMBARI-24551] [Log Search UI] get rid of 
redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5#issuecomment-427804837
 
 
   
   Refer to this link for build results (access rights to CI server needed): 
   https://builds.apache.org/job/Ambari-LogSearch-Github-PR-Builder/7/
   Test PASSed.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.7.2
>
>   Original Estimate: 4h
>  Time Spent: 2h 50m
>  Remaining Estimate: 1h 10m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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


[jira] [Commented] (AMBARI-24551) [Log Search UI] get rid of redundant requests after undoing or redoing several history steps

2018-10-08 Thread ASF GitHub Bot (JIRA)


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

ASF GitHub Bot commented on AMBARI-24551:
-

tobias-istvan opened a new pull request #5: [AMBARI-24551] [Log Search UI] get 
rid of redundant requests after undoing or redoing several history steps
URL: https://github.com/apache/ambari-logsearch/pull/5
 
 
   # What changes were proposed in this pull request?
   
   We can prevent extra calls by using the `LogsContainerService` 
`resetFiltersForms` method.
   
   ## How was this patch tested?
   
   It was tested manually checking the Network tab in dev tools and by running 
unit tests:
   ```
   PhantomJS 2.1.1 (Mac OS X 0.0.0): Executed 269 of 269 SUCCESS (9.276 secs / 
9.178 secs)
   ✨  Done in 35.58s.
   ```
   
   Please review [Ambari Contributing 
Guide](https://cwiki.apache.org/confluence/display/AMBARI/How+to+Contribute) 
before opening a pull request.
   


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:
us...@infra.apache.org


> [Log Search UI] get rid of redundant requests after undoing or redoing 
> several history steps
> 
>
> Key: AMBARI-24551
> URL: https://issues.apache.org/jira/browse/AMBARI-24551
> Project: Ambari
>  Issue Type: Bug
>  Components: ambari-logsearch, logsearch
>Affects Versions: 2.7.1
>Reporter: Istvan Tobias
>Assignee: Istvan Tobias
>Priority: Minor
>  Labels: pull-request-available
> Fix For: 2.7.2
>
>   Original Estimate: 4h
>  Time Spent: 2h 40m
>  Remaining Estimate: 1h 20m
>
> After undoing or redoing more than one history items several redundant API 
> requests are sent. This occurs because changes for several filter controls 
> are applied step-by-step, and each control change generates new request.



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