Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ML] AIOps Log Rate Analysis: adds controls for controlling which columns will be visible #184262

Conversation

alvarezmelissa87
Copy link
Contributor

@alvarezmelissa87 alvarezmelissa87 commented May 24, 2024

Summary

Related meta issue: #182714

This PR adds controls to the AIOps results table to show/hide columns.

image

Checklist

Delete any items that are not applicable to this PR.

@alvarezmelissa87 alvarezmelissa87 added release_note:enhancement :ml Feature:ML/AIOps ML AIOps features: Change Point Detection, Log Pattern Analysis, Log Rate Analysis v8.15.0 labels May 24, 2024
@alvarezmelissa87 alvarezmelissa87 self-assigned this May 24, 2024
@alvarezmelissa87
Copy link
Contributor Author

@elasticmachine merge upstream

const disabledColumnFilterApplyButtonTooltipContent = i18n.translate(
'xpack.aiops.analysis.columnSelectorNotEnoughColumnsSelected',
{
defaultMessage: 'At least one column must be selected.',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the 'at least one' correct? It seems to require at least two columns.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch - fixed in 72f120e

@alvarezmelissa87 alvarezmelissa87 marked this pull request as ready for review June 5, 2024 22:12
@alvarezmelissa87 alvarezmelissa87 requested a review from a team as a code owner June 5, 2024 22:12
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

@alvarezmelissa87
Copy link
Contributor Author

@elasticmachine merge upstream

itemSearchAriaLabel={columnSearchAriaLabel}
initialSkippedItems={skippedColumns}
popoverButtonTitle={columnsButton}
selectedItemLimit={1}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm seeing a weird issue where if I open the popover, hit 'Deselect all', I then have to select 2 items (or sometimes more) to get the Apply button enabled:

Screenshot 2024-06-06 at 10 40 43

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch! Fixed this issue in 7f58298
It now takes into account the incoming skipped items 👍

@alvarezmelissa87
Copy link
Contributor Author

This is ready for a final look when you get a chance 🙏 cc @peteharverson, @qn895

'xpack.aiops.logRateAnalysis.resultsTable.logRateColumnTooltip',
{
defaultMessage:
'A visual representation of the impact of the field on the message rate difference',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Does this message need to end with a period?

const groupImpactMessage = i18n.translate(
'xpack.aiops.logRateAnalysis.resultsTableGroups.impactLabelColumnTooltip',
{
defaultMessage: 'The level of impact of the group on the message rate difference',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Does this message need to end with a period?

Copy link
Member

@qn895 qn895 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Latest changes LGTM

Copy link
Contributor

@peteharverson peteharverson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested latest changes and LGTM

@@ -157,6 +193,7 @@ export const LogRateAnalysisResults: FC<LogRateAnalysisResultsProps> = ({
);
const [shouldStart, setShouldStart] = useState(false);
const [toggleIdSelected, setToggleIdSelected] = useState(resultsGroupedOffId);
const [skippedColumns, setSkippedColumns] = useState<string[]>(['p-value']);
Copy link
Member

@jgowdyelastic jgowdyelastic Jun 7, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice if this could be ColumnNames[] rather than string. It'll probably mean changing all places where they are stored as a string array, but it'd be useful to use the types to enforce that only the correct values are used.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated in c1876b9

@alvarezmelissa87
Copy link
Contributor Author

@elasticmachine merge upstream

@alvarezmelissa87
Copy link
Contributor Author

@elasticmachine merge upstream

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
aiops 620 622 +2

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
aiops 549.3KB 549.9KB +589.0B
Unknown metric groups

ESLint disabled line counts

id before after diff
aiops 29 31 +2

Total ESLint disabled count

id before after diff
aiops 29 31 +2

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @alvarezmelissa87

@alvarezmelissa87 alvarezmelissa87 merged commit 2c76ad0 into elastic:main Jun 10, 2024
17 checks passed
@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label Jun 10, 2024
@alvarezmelissa87 alvarezmelissa87 deleted the ml-aiops-results-add-column-control branch June 10, 2024 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting Feature:ML/AIOps ML AIOps features: Change Point Detection, Log Pattern Analysis, Log Rate Analysis :ml release_note:enhancement v8.15.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants