Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tracecompass-dev] Theia trace extension table sorting and sending preferences to server
  • From: Bernd Hufmann <bernd.hufmann@xxxxxxxxxxxx>
  • Date: Fri, 23 Dec 2022 17:03:00 +0000
  • Accept-language: en-CA, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=ericsson.com; dmarc=pass action=none header.from=ericsson.com; dkim=pass header.d=ericsson.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=cVjDuPyY1SORh/RePwRwXLiIznqVklZ1eUZBk77LZBo=; b=KpeyNfJfYxNZqq8KiyyRhvPCJ/fYxlpzM9HS+G5WlbvV1+JHHnhCZCxGLU7t7066bIB4qdJS/DoaLDWOM2JdyCJuP3lzeyed1xl7+IQtpcpqhCR03YJF0FvPLWQenGLXHvxL9BZG6/IuPGTeZZn5wpS0K0qEfo+JbNoFU/voeoEZb4FyMB+ky2DKNDAJfF6DTXJH42YWoXgaw5Rl7SuviMWMoQw0j1mm3HxVc/Epz4Irxr6ZYrhyzyy3nR+WP82II2wHGBbkabcQHJGWdnXPyFltiPKbISg147IUzJMo19Ectd0B0oZMRWSWtMCgJ8R9+niALDZU2Gz5zudugPUVqg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=R7I1mUhrrkCns74au/kBCc0v7j3uA130pVIDy80Dhmz4/Cl2kIdz7uEbflBXXsL+okZ9gjoYGpFOtKe/O/u0mnc4jkoHl9W6+vzh6x0shtSn8/38oQtG00Mk0UwzCe24ZqLj+wRWSQWLZVh0L6GT/o94yC2pZKEdglf7kJZdBxolsxGxRDs4mtFzdnyux4jYxwqwzjG0m9QdyUvkFr/S8j/nCLQJ5B/jtdz6Of9s0bPAphMvLyKV25uKoolojd2pATPs4qXbzFU+tXgKXmQE6rJvqLBq5KA3FBMqNr28N0A2pq2iIX2bzsY4ApSNVZpoIWA9IJ9K+ht/Ni4E+L0t2A==
  • Delivered-to: tracecompass-dev@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/tracecompass-dev/>
  • List-help: <mailto:tracecompass-dev-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/tracecompass-dev>, <mailto:tracecompass-dev-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/tracecompass-dev>, <mailto:tracecompass-dev-request@eclipse.org?subject=unsubscribe>
  • Msip_labels:
  • Thread-index: AdkOYo3yiPSae7QoRcikiYoSAAnY3QBbo0XwAAhrco8AKEOtAAGVrMm6
  • Thread-topic: Theia trace extension table sorting and sending preferences to server

Hi Alex

thank you for your patience waiting for the reply to your question:

> Another issue I would like to bring up is when the CPU Usage view starts, nothing is selected by default. I would like to have the capability to predefine some items to be selected upon view activation, so data is presented to the user with less delay.

This would be a useful addition and UX improvement that in XY charts default series are selected when opening the view. We have noticed that short-coming, but it hasn't been addressed so far. There was one attempt, but it would hardcode the Trace Compass data provider in the domain-agnostic front-end code [1].

The front-end doesn't have the domain specific knowledge to decide which series to select when opening the view. So, I see 2 approaches to address that.

1) There is an additional parameter in the row entry model that indicates if the entry is a "default" row. If it's set, the front-end can use it to pre-select the series and fetch xy data when analysis is complete. This would be a full-stack feature (incl. TSP).
2) There could be front-end preferences per view (data provider) to customize the view (using json). I haven't really thought that through. However, in future there could be other things like line styles that could be configured that overrides the default styles.

Both options are not mutual exclusive. Option 1) could be used by back-ends to propose the default selection. And option 2) could be used to override/customize the behaviour.

I like option 1) because the domain specific back-ends can propose default selections.

One more thing, the Trace Compass CPU usage data provider always provides the total CPU usage series. The drawback is that users cannot deselect it in the view. (I would like to change that)

I hope this reply helps you.

Best Regards
Bernd



From: tracecompass-dev <tracecompass-dev-bounces@xxxxxxxxxxx> on behalf of Alex Doan <vadoan@xxxxxxxxxxxxxx>
Sent: December 15, 2022 9:52 AM
To: tracecompass developer discussions <tracecompass-dev@xxxxxxxxxxx>
Subject: Re: [tracecompass-dev] Theia trace extension table sorting and sending preferences to server
 

Hi,

 

Thank you for your reply, I have been able to add another sorting algorithm to support my use case. Your help was tremendous.

 

Another issue I would like to bring up is when the CPU Usage view starts, nothing is selected by default. I would like to have the capability to predefine some items to be selected upon view activation, so data is presented to the user with less delay.

 

Any suggestion or advice would be appreciated.

 

Regards,

 

Alex

 

 

From: tracecompass-dev <tracecompass-dev-bounces@xxxxxxxxxxx> On Behalf Of Bernd Hufmann via tracecompass-dev
Sent: Wednesday, December 14, 2022 15:06
To: tracecompass developer discussions <tracecompass-dev@xxxxxxxxxxx>
Cc: Bernd Hufmann <bernd.hufmann@xxxxxxxxxxxx>
Subject: Re: [tracecompass-dev] Theia trace extension table sorting and sending preferences to server

 

CAUTION - This email is from an external source. Please be cautious with links and attachments. (go/taginfo)

 

Hi Alex

 

Thanks for the interest in the Theia trace extension. Please see below for my answers.

 

BR

Bernd

 


From: tracecompass-dev <tracecompass-dev-bounces@xxxxxxxxxxx> on behalf of Alex Doan <vadoan@xxxxxxxxxxxxxx>
Sent: December 14, 2022 10:32 AM
To: tracecompass developer discussions <
tracecompass-dev@xxxxxxxxxxx>
Subject: [tracecompass-dev] FW: Theia trace extension table sorting and sending preferences to server

 

Hi,

 

I’ve noticed that the default sorting alphabetically by displayed string in some tables could be insufficient. For example:

As the usage time has been formatted to be more humanly readable than only displaying in nanoseconds, the sorting became nonsensical. I would like to add the capability to sort not using the displayed string, but hidden value (for example, time in nanoseconds only).

[Bernd] Right now the TSP only defines string for each label. So, the back-end can provided pre-formatted label text. This is because the back-end has the domain specific knowledge on about the data and can format it accordingly. However, this is an issue for sorting as you noticed. Sorting a column by string which, for example, represents a number gives unwanted sorting. What we have implemented in the front-end for sorting, is to convert common, known formatted strings to a number and perform the sorting on the converted number. For example, formatted durations (e.g. 10 ns, 100 ys, 1 s) is supported.

 

Looking at your duration column, I noticed that the formatting is not supported (1 ms133 us). So, sorting uses string comparison. See method parseValue() in https://github.com/eclipse-cdt-cloud/theia-trace-extension/blob/master/packages/react-components/src/components/utils/filter-tree/sort.tsx. Maybe as first step update this method to support the new formatting.

 

Alternatively, the TSP could be augmented to add the possibility to describe the columns data type and pass the raw data and the front-end would have to take care of the formatting. This would be a nice addition, but longer-term solution.

 

Also, I’ve noticed the need to communicate preferences/settings from the client to the server (for example, a Theia setting to switch between grouping by processes or by threads, and the server needs to be aware of this setting to set up state provider accordingly).

[Bernd] The data provider would need to know about the different groupings and based either query parameters to fetchTree() or configuration/settings return the tree model. Right now, there is such no API defined in the TSP. The data provider might need to advertise to the front-end what extra query parameters it supports. We started an ADR about a similar topic where a data provider advertises to the client additional query paremters and actions. I think your use case could be covered as well in this ADR. Please have look and I invite you to participate in the design discussion/review. We are still in an early stage of the design:

https://github.com/eclipse-cdt-cloud/theia-trace-extension/pull/852.

 

The following PR is a proof-of-concept that apply this new API. This PR helps to understand what we'd like to achieve:

https://github.com/eclipse-cdt-cloud/theia-trace-extension/pull/882

 

 

Please let me know if you have any question, request, concern or advice about these features that I hope to contribute.

[Bernd] Try to modify the parseValue() of the sort.tsx file and see if you add support for your label format.

 

Regards,

 

Alex


This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful.


This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful.

Back to the top