Conversation
`percli plugin generate --module.org=perses.dev --module.name=LogExplorer --plugin.display-name="Log Explorer" --plugin.type=Explore --plugin.name=LogExplorer ./logexplorer` Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
…aces) Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Implement createVolumeQuery with dynamic interval calculation for log volume histograms. Filter __name__ metadata field from series labels since each stats query produces a single metric name shared across all its series, making it redundant in legends. Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
Signed-off-by: Jeremy Rickards <jeremy.rickards@sap.com>
|
The go lint check seems erroneous: If a purely frontend plugin like this one has no Go SDK, it shouldn't fail. If the maintainers agree, I can also open a PR to skip the linting if no go files exist? |
@Nexucis -- UPDATE @rickardsjp |
What about #578? Then we don't need to maintain a list. |
|
so, re-reading the issue raised and the proposition from each party I would say there is two different issues here @shahrokni. The first one is: with the inclusion of the e2e tests package in the npm workspaces, we have now packages which are not plugins and that needs to be excluded from various scripts that are only running for the plugins. Then you also have the issue we have here when we are checking golang code per plugins. This was fine because we never had a plugins with frontend only features (so here explorer). In the past, the explorer was included with the datasource, so we never go the issue until now. On that matter, I think the fix proposed by @rickardsjp makes sense as indeed we don't want to support an exact list on what should be excluded for the go check. But @rickardsjp we still want to have this check if there is a schema. So instead of verifying if you have go files, I think you should more check if you have the schema folder. If you have schema folder, then we want to have the go-sdk folder. So if the go files are not present, we want the script to fail. Does it make sense for you @rickardsjp ? |
|
Makes sense. I've adapted #578 to check for schemas instead. |
Description
This PR adds a Log Explorer for the growing number of log query datasources. The LogExplorer consists of a MultiQueryEditor for building log queries, an automatically-generated volume histogram showing log volume over time, and a LogsTable displaying the log entries. The histogram requires the log data source plugins to implement an optional
createVolumeQueryinterface method. This is currently implemented for Loki and VictoriaLogs, but not yet for ClickHouse.Changes to other plugins
VictoriaLogs
createVolumeQuerymethod to its LogQueryPlugin interface| stats by (_time:<interval>, _stream) count() as volumequeries__name__metadata label from time series results for cleaner histogram legendsLoki
createVolumeQuerymethod to its LogQueryPlugin interfacesum by (level, detected_level) (count_over_time(...))queriesClickHouse
createVolumeQuerymethod to its LogQueryPlugin interfacenull(requires SQL query parsing for proper implementation)Testing this PR:
Because this PR changes multiple plugins at once, you will need to build the plugins using
percliand copy them to theplugin_archivedirectory of your perses server. I believe the standard plugin development server can only run one plugin at once. If you clone the victorialogs repo, you can start a sample instance withmake docker-vl-single-up. For Loki, you can use Grafana's instructions to set up a Loki datasource locally using docker compose. Remember to set theX-Scope-OrgIDheader totenant1in the Loki datasource in Perses.Screenshots
Checklist
[<catalog_entry>] <commit message>naming convention using one of thefollowing
catalog_entryvalues:FEATURE,ENHANCEMENT,BUGFIX,BREAKINGCHANGE,DOC,IGNORE.UI Changes