Bug #12002
closedJS error when starting Rudder 4.3 with jetty 9
Description
At first login, I get the following error in the dashboard
TypeError: decomposedValues[i] is undefined rudder-datatable.js:1590:5
and graphs are very slow to show up
Update: the problem is somehow linked to Jetty version: Rudder 4.3 with Jetty 8 works fine, and Rudder 4.1 with Jetty 9 has the problem.
We keep target = 4.3 because we don't have jetty 9 before.
Updated by François ARMAND over 6 years ago
- Subject changed from JS error when starting Rudder 4.3 to JS error when starting Rudder 4.3
In my cases, the graphe don't show at all, and all the JS is broken. My errors are different, to:
TypeError: angular.module(...).unsafePerformSync is not a function [Learn More] angular-translate.min.js:6:19057 <anonymous> http://localhost:8082/rudder-web/cache-4.3.0~alpha1-SNAPSHOT/javascript/angular/angular-translate.min.js:6:19057 <anonymous> http://localhost:8082/rudder-web/cache-4.3.0~alpha1-SNAPSHOT/javascript/angular/angular-translate.min.js:6:132 <anonymous> http://localhost:8082/rudder-web/cache-4.3.0~alpha1-SNAPSHOT/javascript/angular/angular-translate.min.js:6:2 TypeError: angular.module(...).unsafePerformSync is not a function [Learn More] angular-filemanager.min.js:3:1657 <anonymous> http://localhost:8082/rudder-web/cache-4.3.0~alpha1-SNAPSHOT/javascript/angular/angular-filemanager.min.js:3:1657 Loading failed for the <script> with source “http://localhost:8082/rudder-web/lift/page/F471683393803U4BS1U.js”. [Learn More]
It feels like some things are not ready or correctly loaded, which it turns broke all the JS.
Updated by François ARMAND over 6 years ago
A simple reload of the page make things work again.
Updated by Nicolas CHARLES over 6 years ago
the error about unsafePerformSync is on every page
see https://www.rudder-project.org/redmine/issues/11991
Updated by Nicolas CHARLES over 6 years ago
- Related to Bug #11991: Javascript error on every pages, preventing usage of file explorer added
Updated by Benoît PECCATTE over 6 years ago
- Severity set to Minor - inconvenience | misleading | easy workaround
- User visibility set to Getting started - demo | first install | level 1 Techniques
- Priority changed from 0 to 50
Updated by Nicolas CHARLES over 6 years ago
Error now is
Content Security Policy: La directive « frame-src » est obsolète. Veuillez utiliser la directive « child-src » à la place. Échec du chargement pour l’élément <script> dont la source est « https://192.168.44.2/rudder/lift/page/F256739716637QEWLDN.js ». index.html:627 Erreur dans les liens source : request failed with status 404 URL de la ressource : https://192.168.44.2/rudder/cache-4.3.0~alpha1-SNAPSHOT/javascript/angular/angular.min.js URL du lien source : angular.min.js.map
Updated by Vincent MEMBRÉ over 6 years ago
Last error has no impact, it's only when you open a js console, and it does not find .map file for angular.min.js file (a map files allow to deminify a file on demand)
Erreur dans les liens source : request failed with status 404 URL de la ressource : https://192.168.44.2/rudder/cache-4.3.0~alpha1-SNAPSHOT/javascript/angular/angular.min.js URL du lien source : angular.min.js.map
I need to looke depper in the first line about the frame-src/child-src
Updated by Vincent MEMBRÉ over 6 years ago
- Target version changed from 4.3.0~beta1 to 4.3.0~rc1
Updated by Vincent MEMBRÉ over 6 years ago
- Target version changed from 4.3.0~rc1 to 4.3.0~rc2
Updated by François ARMAND over 6 years ago
- Translation missing: en.field_tag_list set to Blocking 4.3
We can't make a release with errors. It would lead to a lot of false positive when we find other errors.
Updated by Benoît PECCATTE over 6 years ago
- Has duplicate Bug #12159: In 4.3, right after logging in, the dashboard remains empty, with a JS error added
Updated by Nicolas CHARLES over 6 years ago
Apache logs at login are
192.168.42.1 - - [20/Mar/2018:12:59:37 -0500] "POST /rudder/j_spring_security_check HTTP/1.1" 302 - "https://192.168.42.2/rudder/" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko/20100101 Firefox/58.0" 192.168.42.1 - - [20/Mar/2018:12:59:38 -0500] "GET /rudder/secure/index.html HTTP/1.1" 200 6901 "https://192.168.42.2/rudder/" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko/20100101 Firefox/58.0" 192.168.42.1 - - [20/Mar/2018:12:59:38 -0500] "GET /rudder/lift/page/F229878065677F1DCXM.js HTTP/1.1" 404 17711 "https://192.168.42.2/rudder/secure/index.html" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko/20100101 Firefox/58.0" 192.168.42.1 - - [20/Mar/2018:12:58:40 -0500] "GET /rudder/lift/comet/54829882895/F229878025479Z03TWD/F229878025492TXRMZI?F2298780254933GF1EH=229878025496&F229878025497IP2KCX=229878033300&_=1521541447761 HTTP/1.1" 502 1277 "https://192.168.42.2/rudder/secure/utilities/techniqueEditor" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.109 Safari/537.36" 192.168.42.1 - - [20/Mar/2018:12:59:41 -0500] "GET /rudder/lift/page/F229878065677F1DCXM.js HTTP/1.1" 404 17711 "https://192.168.42.2/rudder/secure/index.html" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko/20100101 Firefox/58.0"
Updated by Nicolas CHARLES over 6 years ago
- Status changed from New to In progress
- Assignee changed from Vincent MEMBRÉ to Nicolas CHARLES
- Priority changed from 50 to 49
I'm taking over this issue
My finding, the JS lift/page/F1122152738108JPO4HU.js is not found
references are in
<body data-lift-session-id="F1122152738107BYHAPJ" data-lift-gc="F1122152738108JPO4HU" class="skin-yellow sidebar-mini">
and at the bottom of the code
<script type="text/javascript" src="/rudder-web/lift/page/F1122152738108JPO4HU.js"></script>
Updated by Nicolas CHARLES over 6 years ago
Trying with LiftRules.enableLiftGC = false in class Boot, it didn't change anything
It works with Jetty 6 & 7, but not 9
Updated by Nicolas CHARLES over 6 years ago
Adding in HomePage.scala
LiftRules.enableLiftGC = false LiftRules.autoIncludeComet = _ => false
disables the data-lift-gc tag; however it still fails, so it's unrelated to gc
Updated by Nicolas CHARLES over 6 years ago
the failing JS contains the Lift configuration part:
var lift_settings = {}; window.lift.extend(lift_settings,window.liftJQuery); window.lift.extend(lift_settings,{"liftPath": "/rudder-web/lift", "ajaxRetryCount": 1, "ajaxPostTimeout": 30000, "gcPollingInterval": 75000, "gcFailureRetryTimeout": 15000, "cometGetTimeout": 140000, "cometFailureRetryTimeout": 10000, "cometServer": null, "logError": function(msg) {lift.defaultLogError(msg);}, "ajaxOnFailure": function() {alert("The server cannot be contacted at this time");}, "ajaxOnStart": function() {jQuery('#'+"ajax-loader").show();}, "ajaxOnEnd": function() {jQuery('#'+"ajax-loader").hide();}}); window.lift.init(lift_settings); var destroy_F896022439538OB51J3 = function() {} var destroy_F896022439541S1NB1T = function() {} jQuery(document).ready(function() {lift.registerComets({"F896022439538OB51J3": 896022439539, "F896022439541S1NB1T": 896022439542},true);});
Updated by François ARMAND over 6 years ago
- Subject changed from JS error when starting Rudder 4.3 to JS error when starting Rudder 4.3 with jetty 9
- Description updated (diff)
Updated by François ARMAND over 6 years ago
The problem is with the existing sessions created by jetty in login page. If I delete the session cookie before hiting submit, then the JS is correctly loaded.
There is a thread on Liftweb google talking about that here: https://groups.google.com/forum/#!topic/liftweb/lcn6U6_Igxk
Updated by Nicolas CHARLES over 6 years ago
- Assignee changed from Nicolas CHARLES to François ARMAND
Updated by François ARMAND over 6 years ago
This is a Liftweb bug, reported here: https://github.com/lift/framework/issues/1947. Waiting for a workaround :(
Updated by François ARMAND over 6 years ago
- Status changed from In progress to Pending technical review
- Assignee changed from François ARMAND to Vincent MEMBRÉ
- Pull Request set to https://github.com/Normation/rudder/pull/1876
Updated by François ARMAND over 6 years ago
- Assignee changed from Vincent MEMBRÉ to Nicolas CHARLES
Updated by François ARMAND over 6 years ago
Between, we can workaround the problem by forcing spring security to not use "HttpServletRequest.changeSessionId". We would be able to migrate back towards the more efficient solution when when want.
Updated by François ARMAND over 6 years ago
- Status changed from Pending technical review to Pending release
Applied in changeset rudder|0d28c8f157d8679046579f7f80bd9b7068458586.
Updated by Vincent MEMBRÉ over 6 years ago
- Status changed from Pending release to Released
This bug has been fixed in Rudder 4.3.0~rc2 which was released today.
- 4.3.0~rc2: Announce Changelog
- Download: https://www.rudder-project.org/site/get-rudder/downloads/