Repository navigation
[ML] Data frames: Analytics jobs list. - #42598
Conversation
💚 Build Succeeded |
|
Pinging @elastic/ml-ui |
💔 Build Failed |
💚 Build Succeeded |
| <p> | ||
| {i18n.translate('xpack.ml.dataframe.analyticsList.startModalBody', { | ||
| defaultMessage: | ||
| 'A data frame analytics job will increase search and indexing load in your cluster. Please stop the analytics job if excessive load is experienced. Are you sure you want to start this analytics job?', |
There was a problem hiding this comment.
Is this warning on starting an analytics job needed? We don't show one when starting an anomaly detection job for example.
There was a problem hiding this comment.
The behaviour is the same as with transforms. I will revisit in a follow up after some further discussions, no definitive decision yet. Updated #42516 accordingly.
| ); | ||
| } | ||
|
|
||
| function stringMatch(str: string | undefined, substr: string) { |
There was a problem hiding this comment.
Looks like this function has been created and used in a couple of other places already - transform_list.tsx and jobs_list/components/utils.js - might be worth moving to a common place.
There was a problem hiding this comment.
Added a note to the project to do this in a follow up (once we have a decision where transforms/analytics code will live eventually), I intentionally didn't do any code deduplication in this PR.
|
|
||
| // This component extends EuiInMemoryTable with some | ||
| // fixes and TS specs until the changes become available upstream. | ||
|
|
There was a problem hiding this comment.
Will these additions be a problem once they do become available in the EUI component itself?
There was a problem hiding this comment.
If time permits I'll do a EUI PR with these updates then updating this can go hand in hand.
alvarezmelissa87
left a comment
There was a problem hiding this comment.
Left a couple of small comments but overall LGTM ⚡️
| REFRESH_ANALYTICS_LIST_STATE.IDLE | ||
| ); | ||
|
|
||
| export const useRefreshAnalyticsList = ( |
There was a problem hiding this comment.
this is a nicely structured hook. i wonder if it could be used in a more general way for managing things that load.
also, could isLoading be moved to be something returned from the hook, like refresh is? i guess you'd then need something watching isLoading on the other end.
There was a problem hiding this comment.
thanks! Yes I think isLoading could be moved inside the custom hook, don't remember exactly why I did it this way, maybe I had issues with updates. Just checked because someone mentioned it a while ago, APM has a generic version useFetcher() similar to this, we could have a look if we wanted to reuse it https://github.com/elastic/kibana/blob/master/x-pack/legacy/plugins/apm/public/hooks/useFetcher.tsx
| item: DataFrameAnalyticsListRow; | ||
| } | ||
|
|
||
| export const DeleteAction: SFC<DeleteActionProps> = ({ item }) => { |
There was a problem hiding this comment.
we probably should be using FC for all new code
There was a problem hiding this comment.
Changed for all analytics code in aec4524.
💔 Build Failed |
💔 Build Failed |
💔 Build Failed |
💚 Build Succeeded |
Introduces the data frame analytics jobs list.
Introduces the data frame analytics jobs list.
Summary
Part of #42516.
Introduces the data frame analytics jobs list.
Features
Notes
Checklist
Use
strikethroughsto remove checklist items you don't feel are applicable to this PR.Documentation was added for features that require explanation or tutorialsFor maintainers