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

Data Source Selector is not working #163

Open
omse974 opened this issue Dec 5, 2024 · 4 comments
Open

Data Source Selector is not working #163

omse974 opened this issue Dec 5, 2024 · 4 comments

Comments

@omse974
Copy link

omse974 commented Dec 5, 2024

Describe the bug
In "Link Properties" window, the "Data Source Selector" field stay empty even with a fresh installation of Cacti 1.2.28.

Screenshots
weathermap_data_source_selector_bug

Expected behavior
No error appears in the log.
"Graph Selector" field working fine.

Plugin Weathermap:

Version: 1.3.1
Source: github
Identifer: https://github.com/Cacti/plugin_weathermap/commit/cd3037f9d5c3f7da738b424eba0eb19824317b5a

Desktop:

OS: Ubuntu 24.04.01 LTS
Browser : Firefox
Version : 132.0.2
@TheWitness
Copy link
Member

Open your browsers debug window and go to it's console. See if there are JavaScript error there.

@omse974
Copy link
Author

omse974 commented Dec 10, 2024

There are no errors in the browser debug window.

I see the JSON response with the "Graph Selector" request which is not empty.
data_source_selector_is_not_working-graphs
https://*******************/cacti/plugins/weathermap/weathermap-cacti-plugin-editor.php?mapname=simple.conf&action=graphs&term=&target=link_picker&graph_template_id=-1

But I see the JSON response with the "Data Source Selector" request which is empty.
data_source_selector_is_not_working-datasources
https://*******************/cacti/plugins/weathermap/weathermap-cacti-plugin-editor.php?mapname=simple.conf&action=datasources&term=&target=link_target_picker&graph_template_id=-1

@andyb2000
Copy link

Tracking the same problem.
Two things I've noticed, mysql/mariadb spikes huge CPU when the editor is loaded and the query for datasources is active (I've reduced the autocomplete_rows output to ensure the limit is a small number) so I think it's this query.
lib/editor.inc.php
display_datasources()

The query does return eventually (we have a lot of devices and graphs for interfaces) with valid data but the drop-down still doesn't populate.
(See attached image for output looking like it returned).
PXL_20250116_103646328.MP.jpg

I'll continue to try and debug what else is going on here as this is key to our weathermap use!

@TheWitness
Copy link
Member

Use the last known good tag, don't use develop right now due to a mishap on my part that I have not been able to resolve due to timing issues on my part. From your MariaDB/MySQL process list, see if you can find the queries that are bogging down the database and post them here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants