Linking Frontend monitoring from Factory monitoring
Now that the frontend is advertising its Web URL, we should propagate this information to the Factory monitoring.
#14 Updated by HyunWoo Kim almost 4 years ago
I implemented my current idea of how to achieve this goal.
It can be checked in my test factory node:
On the bottom right, you will find a new link.
If you follow this, you will be led to the frontend monitoring page
I need to polish this new code, i.e. I need to see if the new lines in glideFactory.py are in the best place, which might not be the case currently,
and so on..
#17 Updated by HyunWoo Kim over 3 years ago
Two weeks ago, I put a new code to achieve this goal.
Today, I realized that a WMS Collector usually has multiple glideclient classads from multiple frontends.
Thus, I modified my new code in glideFactory.py to extract all these frontends.
Now, I also need to modify the new HTML file that I created 2 weeks.
This is the hard part.
My intention is, have the HTML read a new text file, go over multiple lines, split each line to the frontend name and its monitoring url
and create a new link dynamically for each monitoring url/frontend pair.
#18 Updated by HyunWoo Kim over 3 years ago
This code seems to work
note that glideFactory.py is responsible for creating a text file(text.txt below) that contains a list of pair of frontend name and its monitoring url.
#19 Updated by HyunWoo Kim over 3 years ago
Today, I decided that the new logic I originally put in glideFactory.py can actually become a simple script and run via a cron.
(because this logic doesn't need to run inside the loop. it is sufficient to run it once a day)
Now, I am summarizing the new codes here:
1. factory/tools/propagate_frontend_monitoring.py (New file)
- runs condor_status command (via condorMonitor in glideinwms/lib.py) to extract the
values of WebMonitoringURL attribute in all glideclient classads
- and saves frontend_name and the monitoring url in a text file
2. accordingly a new cron script is created that goes into /var/spool/cron/ (New file)
3. creation/web_base/FrontendMonitorLink.html (New file)
- reads the text file that propagate_frontend_monitoring.py created
- and creates new links from the frontend name and monitoring url from that text file
4. creation/web_base/factory/index.html is modified to have a new box for
the new FrontendMonitorLink.html
5. glideinwms.spec file is modified to take care of the above new changes.
I will run a test rpm building in jenkins