File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -18,18 +18,18 @@ export default function alertingPlugin(
1818) {
1919 const ca = components . clientAction . factory ;
2020
21- Client . prototype . alerting = components . clientAction . namespaceFactory ( ) ;
22- const alerting = Client . prototype . alerting . prototype ;
21+ Client . prototype . adAlerting = components . clientAction . namespaceFactory ( ) ;
22+ const adAlerting = Client . prototype . adAlerting . prototype ;
2323
24- alerting . searchMonitors = ca ( {
24+ adAlerting . searchMonitors = ca ( {
2525 url : {
2626 fmt : `${ API . ALERTING_BASE } /_search` ,
2727 } ,
2828 needBody : true ,
2929 method : 'POST' ,
3030 } ) ;
3131
32- alerting . searchAlerts = ca ( {
32+ adAlerting . searchAlerts = ca ( {
3333 url : {
3434 fmt : `${ API . ALERTING_BASE } /alerts?size=${ MAX_ALERTS } &monitorId=<%=monitorId%>&sortString=start_time&sortOrder=desc&searchString=start_time:[<%=startTime%>%20TO%20<%=endTime%>]` ,
3535 req : {
Original file line number Diff line number Diff line change @@ -92,7 +92,7 @@ export default class AlertingService {
9292 ) ;
9393
9494 const response : SearchResponse < Monitor > = await callWithRequest (
95- 'alerting .searchMonitors' ,
95+ 'adAlerting .searchMonitors' ,
9696 { body : requestBody }
9797 ) ;
9898 const totalMonitors = get ( response , 'hits.total.value' , 0 ) ;
@@ -155,7 +155,7 @@ export default class AlertingService {
155155 ) ;
156156
157157 const response = callWithRequest (
158- 'alerting .searchAlerts' , {
158+ 'adAlerting .searchAlerts' , {
159159 monitorId : monitorId ,
160160 startTime : startTime ,
161161 endTime : endTime ,
You can’t perform that action at this time.
0 commit comments