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

Fix display bugs in the error message for the job viewer analytics. #1003

Merged
merged 1 commit into from
Aug 20, 2019

Conversation

jpwhite4
Copy link
Member

@jpwhite4 jpwhite4 commented Aug 8, 2019

The error messages in the job viewer chart analytics had two problems.

  1. there was no word wrapping enabled so the text would be truncated if the browser
    window was too small.

image

  1. the text was not updated on a resize event. An example of the text display after a window
    maximise is shown below.

image

This update fixes the word wrap and ensures that the text is re-rendered if the window is resized.

image

image

I did a quick test for memory leaks by adding the following to the JobPanel.

diff --git a/share/html/gui/js/modules/job_viewer/JobViewer.js b/share/html/gui/js/modules/job_viewer/JobViewer.js
index bc8fcf6..2af7106 100644
--- a/share/html/gui/js/modules/job_viewer/JobViewer.js
+++ b/share/html/gui/js/modules/job_viewer/JobViewer.js
@@ -798,6 +798,12 @@ XDMoD.Module.JobViewer = Ext.extend(XDMoD.PortalModule, {
                         var success = exists(data) && exists(data.success) && data.success;
                         if (success) {
                             parent.fireEvent('update_analytics', data.data, true);
+
+                            var task = new Ext.util.DelayedTask(function () {
+                                parent.fireEvent('update_analytics', data.data, true);
+                                task.delay(2000);
+                            });
+                            task.delay(2000);
                         }
                     },
                     failure: function (data) {

and then leaving it to run on Firefox Linux over lunch. The memory profiler in the dev tools showed that the memory usage on the page had not changed by much.

@jpwhite4 jpwhite4 added this to the 8.5.0 milestone Aug 8, 2019
@jpwhite4 jpwhite4 added bug Bugfixes Category:Job Viewer Job Viewer labels Aug 8, 2019
@jpwhite4 jpwhite4 merged commit fe4e677 into ubccr:xdmod8.5 Aug 20, 2019
@jpwhite4 jpwhite4 deleted the chart_error branch August 20, 2019 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bugfixes Category:Job Viewer Job Viewer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants