Openbravo Issue Tracking System - Retail Modules
View Issue Details
0027676Retail ModulesWeb POSpublic2014-09-25 00:442014-09-30 18:20
mtaal 
mtaal 
normaltrivialhave not tried
closedfixed 
5
 
RR14Q4RR14Q4 
marvintm
No
0027676: Starting for the first time, visiting first webpos, error is shown in the console and the webpos UI won't load
See this stacktrace in the console. This is caused because when visiting first webpos there is no WebContent/js/gen directory.

    ... 51 more
Caused by: java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at freemarker.ext.beans.BeansWrapper.invokeMethod(BeansWrapper.java:840)
    at freemarker.ext.beans.BeanModel.invokeThroughDescriptor(BeanModel.java:276)
    at freemarker.ext.beans.BeanModel.get(BeanModel.java:183)
    ... 69 more
Caused by: java.lang.NullPointerException
    at org.openbravo.mobile.core.MobileStaticResourceComponent.generateStaticResources(MobileStaticResourceComponent.java:56)
    at org.openbravo.mobile.core.MobileStaticResourceComponent.getGeneratedJavascriptFilename(MobileStaticResourceComponent.java:96)
    at org.openbravo.mobile.core.MobileCoreApplicationCacheComponent.getGenFileName(MobileCoreApplicationCacheComponent.java:153)
    ... 76 more
Removed the web/js/gen folder (this is the initial state after a first install)
Start the application
Visit webpos:
http://localhost:8080/openbravo/web/org.openbravo.retail.posterminal/?terminal=VBS-1 [^]
No tags attached.
blocks feature request 0027329 new Retail Stabilization: Overhaul the loading process (since the url is entered until the webpos has loaded) 
Issue History
2014-09-25 00:44mtaalNew Issue
2014-09-25 00:44mtaalAssigned To => mtaal
2014-09-25 00:44mtaalTriggers an Emergency Pack => No
2014-09-25 00:48hgbotCheckin
2014-09-25 00:48hgbotNote Added: 0070339
2014-09-25 00:48hgbotStatusnew => resolved
2014-09-25 00:48hgbotResolutionopen => fixed
2014-09-25 00:48hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/1f92cef2ed291cbdeefa12e4629a0d70496cd604 [^]
2014-09-25 03:01hgbotCheckin
2014-09-25 03:01hgbotNote Added: 0070340
2014-09-25 03:01hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/1f92cef2ed291cbdeefa12e4629a0d70496cd604 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/be65de4e15863b2407b94245e15d51c57f4c818b [^]
2014-09-25 03:01hgbotCheckin
2014-09-25 03:01hgbotNote Added: 0070341
2014-09-25 03:01hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/be65de4e15863b2407b94245e15d51c57f4c818b [^] => http://code.openbravo.com/erp/devel/pi/rev/cf52e1e13e957c1fbe5c765909ec2e67f18ecd3b [^]
2014-09-25 04:27hgbotCheckin
2014-09-25 04:27hgbotNote Added: 0070344
2014-09-25 04:27hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/devel/pi/rev/cf52e1e13e957c1fbe5c765909ec2e67f18ecd3b [^] => http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/ed0a0448f2d7050526834d7284146c0687116484 [^]
2014-09-25 11:30hudsonbotCheckin
2014-09-25 11:30hudsonbotNote Added: 0070363
2014-09-25 21:34hgbotCheckin
2014-09-25 21:34hgbotNote Added: 0070411
2014-09-25 21:34hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/ed0a0448f2d7050526834d7284146c0687116484 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/0b38deb985912b819ba6f04c906259bb35fadbdb [^]
2014-09-25 23:02OrekariaRelationship addedblocks 0027329
2014-09-30 18:20marvintmReview Assigned To => marvintm
2014-09-30 18:20marvintmStatusresolved => closed
2014-09-30 18:20marvintmFixed in Version => RR14Q4

Notes
(0070339)
hgbot   
2014-09-25 00:48   
Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 1f92cef2ed291cbdeefa12e4629a0d70496cd604
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Thu Sep 25 00:47:45 2014 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/1f92cef2ed291cbdeefa12e4629a0d70496cd604 [^]

Fixes issue 27676: Starting for the first time, visiting first webpos, error is shown in the console and the webpos UI won't load
Check if generate destination directory exists, if not create it

---
M src/org/openbravo/mobile/core/MobileStaticResourceComponent.java
---
(0070340)
hgbot   
2014-09-25 03:01   
Repository: erp/pmods/org.openbravo.mobile.core
Changeset: be65de4e15863b2407b94245e15d51c57f4c818b
Author: Rafa Alonso <rafael.alonso <at> openbravo.com>
Date: Thu Sep 25 02:58:01 2014 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/be65de4e15863b2407b94245e15d51c57f4c818b [^]

Fixes issue 27676: (mobile.core) The location for the generated javascript file is now the location where the ERP saves the file

The custom location for the generated file in mobile.core has been removed as we really used the
backend location and should be there where we look for the file, and:
- the check for the directory has been slightly changed
- and a weird hack to not fail the first WebPOS request has been added. The request failed if it was made in the next milliseconds after tomcat had finished loading (aka when the backend informs about how long it took to start up). Happened only once, and only if the user didn't wait for some seconds after the backend finished the starting up.

---
M src/org/openbravo/mobile/core/MobileStaticResourceComponent.java
---
(0070341)
hgbot   
2014-09-25 03:01   
Repository: erp/devel/pi
Changeset: cf52e1e13e957c1fbe5c765909ec2e67f18ecd3b
Author: Rafa Alonso <rafael.alonso <at> openbravo.com>
Date: Thu Sep 25 03:01:02 2014 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/cf52e1e13e957c1fbe5c765909ec2e67f18ecd3b [^]

Fixes issue 27676: (Openbravo) The 'GEN_TARGET_LOCATION' static is now a public value that can be accessed

This is necessary for satelite aplications to know where the javascript generated file was created

---
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/StaticResourceComponent.java
---
(0070344)
hgbot   
2014-09-25 04:27   
Repository: erp/pmods/org.openbravo.mobile.core
Changeset: ed0a0448f2d7050526834d7284146c0687116484
Author: Rafa Alonso <rafael.alonso <at> openbravo.com>
Date: Thu Sep 25 04:27:20 2014 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/ed0a0448f2d7050526834d7284146c0687116484 [^]

Fixes issue 27676: Private static methods go first

---
M src/org/openbravo/mobile/core/MobileStaticResourceComponent.java
---
(0070363)
hudsonbot   
2014-09-25 11:30   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/63604e8e17b7 [^]
Maturity status: Test
(0070411)
hgbot   
2014-09-25 21:34   
Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 0b38deb985912b819ba6f04c906259bb35fadbdb
Author: Rafa Alonso <rafael.alonso <at> openbravo.com>
Date: Thu Sep 25 21:31:51 2014 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/0b38deb985912b819ba6f04c906259bb35fadbdb [^]

Fixes issue 27676: The generation of a new javascript file has been improved
- the generated file is now only created when necessary not to update the timestamp and, thus, to invalidate the manifest
- if the tomcat is restarted, no new file is created
- an explicit flag has been added to force a new generation in the javascript content changes (useful while developing without any module 'in development'). When this flag is active, the application will behave identical to production, with the plus that the generated file will update when the javascript content changes. This flag is not defaulted to true because the generation of the file can take some time (depending on the server, from less than 1 second to a few seconds)
- the directory is cleaned of non useful copies, so only one mobile file should be present

To provoke the creation of a new javascript file, there are 3 options:
 a. delete the existing file or the 'gen' directory
 b. change the version of a module
 c. activate the flag (intended for development/test contexts)

---
M src/org/openbravo/mobile/core/MobileStaticResourceComponent.java
---