Dev - orderview error - r7059

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Dev - orderview error - r7059

Ray Barlow
Hi Si,

FYI I'm getting the error messages shown below in my log files since your recent changes to the order view page for extra inventory information.

This happens straight after checkout of the simple order for 1 GZ-1001 on a clean system and DB, as the log implies it's not the actual checkout process, but the email notification routine.

Ray


153861 (http-0.0.0.0-8080-Processor3) [     ControlServlet.java:258:DEBUG] [[[processorder] Done ren
dering page, Servlet Finished- total:8.682,since last([processorder] Se...):8.682]]
160030 (org.ofbiz.service.job.JobPoller@1eb1db2) [  ServiceDispatcher.java:169:INFO ] Registered dis
patcher: JobDispatcher
160030 (org.ofbiz.service.job.JobPoller@1eb1db2) [  GenericDispatcher.java:85 :INFO ] [LocalDispatch
er] : Created Dispatcher for: JobDispatcher
160551 (invoker-Thread-7) [PersistedServiceJob.java:146:INFO ] org.ofbiz.service.job.PersistedServic
eJob@180bfe1[10020] -- Next runtime: -1
[Error] :2:12: cvc-elt.1: Cannot find the declaration of element 'ofbiz-ser'.
160581 (invoker-Thread-7) [            UtilXml.java:242:DEBUG] XML Read 0.01s: Internal Content
161022 (invoker-Thread-7) [            UtilXml.java:242:DEBUG] XML Read 0.07s: file:/U:/Work/OFBiz/o
fbizclean/applications/ecommerce/widget/EmailOrderScreens.xml
161022 (invoker-Thread-7) [      ScreenFactory.java:127:INFO ] Got 6 screens in 0.07s from: file:/U:
/Work/OFBiz/ofbizclean/applications/ecommerce/widget/EmailOrderScreens.xml
161342 (invoker-Thread-7) [      FieldToResult.java:75 :WARN ] Field value not found with name perso
n.suffix in Map with name
161342 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.01,s
ince last(Begin):0.01]] - 'JobDispatcher / getPartyNameForDate'
162965 (invoker-Thread-7) [            UtilXml.java:242:DEBUG] XML Read 0.071s: file:/U:/Work/OFBiz/
ofbizclean/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml
163025 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.0,si
nce last(Begin):0.0]] - 'JobDispatcher / getAssociatedProducts'
163025 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.141,
since last(Begin):0.141]] - 'JobDispatcher / getInventoryAvailableByFacility'
163035 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.0,si
nce last(Begin):0.0]] - 'JobDispatcher / getAssociatedProducts'
163045 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.01,s
ince last(Begin):0.01]] - 'JobDispatcher / getInventoryAvailableByFacility'
163045 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.221,
since last(Begin):0.221]] - 'JobDispatcher / getProductInventorySummaryForItems'
163195 (invoker-Thread-7) [            BshUtil.java:185:WARN ]
---- exception report ----------------------------------------------------------
WARNING: no cause (from getCause) found for BSH EvalError: Sourced file: component://order/webapp/or
dermgr/WEB-INF/actions/order/orderview.bsh : Attempt to resolve method: getAttribute() on undefined
variable or class name: session : at Line: 255 : in file: component://order/webapp/ordermgr/WEB-INF/
actions/order/orderview.bsh : session .getAttribute ( "userLogin" )

Exception: bsh.EvalError
Message: Sourced file: component://order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh : Attem
pt to resolve method: getAttribute() on undefined variable or class name: session
---- stack trace ---------------------------------------------------------------
Sourced file: component://order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh : Attempt to res
olve method: getAttribute() on undefined variable or class name: session : at Line: 255 : in file: c
omponent://order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh : session .getAttribute ( "user
Login" )
bsh.UtilEvalError.toEvalError(UtilEvalError.java:82)
bsh.UtilEvalError.toEvalError(UtilEvalError.java:87)
bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:79)
bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:69)
bsh.BSHArguments.getArguments(BSHArguments.java:47)
bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:51)
bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:69)
bsh.BSHAssignment.eval(BSHAssignment.java:58)
bsh.BSHBlock.eval(BSHBlock.java:79)
bsh.BSHBlock.eval(BSHBlock.java:44)
bsh.BSHForStatement.eval(BSHForStatement.java:120)
bsh.BSHBlock.eval(BSHBlock.java:79)
bsh.BSHBlock.eval(BSHBlock.java:44)
bsh.BSHIfStatement.eval(BSHIfStatement.java:48)
bsh.Interpreter.evalParsedScript(Interpreter.java:1104)
org.ofbiz.base.util.BshUtil.runBshAtLocation(BshUtil.java:169)
org.ofbiz.widget.screen.ModelScreenAction$Script.runAction(ModelScreenAction.java:392)
org.ofbiz.widget.screen.ModelScreenAction.runSubActions(ModelScreenAction.java:124)
org.ofbiz.widget.screen.ModelScreenWidget$Section.renderWidgetString(ModelScreenWidget.java:247)
org.ofbiz.widget.screen.ModelScreen.renderScreenString(ModelScreen.java:144)
org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:115)
org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:100)
org.ofbiz.content.email.EmailServices.sendMailFromScreen(EmailServices.java:347)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.ofbiz.service.engine.StandardJavaEngine.serviceInvoker(StandardJavaEngine.java:101)
org.ofbiz.service.engine.StandardJavaEngine.runSync(StandardJavaEngine.java:63)

 
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Dev - orderview error - r7059

Jacopo Cappellato
Ray,


could you please see if the attached patch will solve your problem?

Thanks,

Jacopo

Ray wrote:

> Hi Si,
>
> FYI I'm getting the error messages shown below in my log files since your recent changes to the order view page for extra inventory information.
>
> This happens straight after checkout of the simple order for 1 GZ-1001 on a clean system and DB, as the log implies it's not the actual checkout process, but the email notification routine.
>
> Ray
>
>
> 153861 (http-0.0.0.0-8080-Processor3) [     ControlServlet.java:258:DEBUG] [[[processorder] Done ren
> dering page, Servlet Finished- total:8.682,since last([processorder] Se...):8.682]]
> 160030 (org.ofbiz.service.job.JobPoller@1eb1db2) [  ServiceDispatcher.java:169:INFO ] Registered dis
> patcher: JobDispatcher
> 160030 (org.ofbiz.service.job.JobPoller@1eb1db2) [  GenericDispatcher.java:85 :INFO ] [LocalDispatch
> er] : Created Dispatcher for: JobDispatcher
> 160551 (invoker-Thread-7) [PersistedServiceJob.java:146:INFO ] org.ofbiz.service.job.PersistedServic
> eJob@180bfe1[10020] -- Next runtime: -1
> [Error] :2:12: cvc-elt.1: Cannot find the declaration of element 'ofbiz-ser'.
> 160581 (invoker-Thread-7) [            UtilXml.java:242:DEBUG] XML Read 0.01s: Internal Content
> 161022 (invoker-Thread-7) [            UtilXml.java:242:DEBUG] XML Read 0.07s: file:/U:/Work/OFBiz/o
> fbizclean/applications/ecommerce/widget/EmailOrderScreens.xml
> 161022 (invoker-Thread-7) [      ScreenFactory.java:127:INFO ] Got 6 screens in 0.07s from: file:/U:
> /Work/OFBiz/ofbizclean/applications/ecommerce/widget/EmailOrderScreens.xml
> 161342 (invoker-Thread-7) [      FieldToResult.java:75 :WARN ] Field value not found with name perso
> n.suffix in Map with name
> 161342 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.01,s
> ince last(Begin):0.01]] - 'JobDispatcher / getPartyNameForDate'
> 162965 (invoker-Thread-7) [            UtilXml.java:242:DEBUG] XML Read 0.071s: file:/U:/Work/OFBiz/
> ofbizclean/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml
> 163025 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.0,si
> nce last(Begin):0.0]] - 'JobDispatcher / getAssociatedProducts'
> 163025 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.141,
> since last(Begin):0.141]] - 'JobDispatcher / getInventoryAvailableByFacility'
> 163035 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.0,si
> nce last(Begin):0.0]] - 'JobDispatcher / getAssociatedProducts'
> 163045 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.01,s
> ince last(Begin):0.01]] - 'JobDispatcher / getInventoryAvailableByFacility'
> 163045 (invoker-Thread-7) [  ServiceDispatcher.java:447:DEBUG] [[Sync service finished- total:0.221,
> since last(Begin):0.221]] - 'JobDispatcher / getProductInventorySummaryForItems'
> 163195 (invoker-Thread-7) [            BshUtil.java:185:WARN ]
> ---- exception report ----------------------------------------------------------
> WARNING: no cause (from getCause) found for BSH EvalError: Sourced file: component://order/webapp/or
> dermgr/WEB-INF/actions/order/orderview.bsh : Attempt to resolve method: getAttribute() on undefined
> variable or class name: session : at Line: 255 : in file: component://order/webapp/ordermgr/WEB-INF/
> actions/order/orderview.bsh : session .getAttribute ( "userLogin" )
>
> Exception: bsh.EvalError
> Message: Sourced file: component://order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh : Attem
> pt to resolve method: getAttribute() on undefined variable or class name: session
> ---- stack trace ---------------------------------------------------------------
> Sourced file: component://order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh : Attempt to res
> olve method: getAttribute() on undefined variable or class name: session : at Line: 255 : in file: c
> omponent://order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh : session .getAttribute ( "user
> Login" )
> bsh.UtilEvalError.toEvalError(UtilEvalError.java:82)
> bsh.UtilEvalError.toEvalError(UtilEvalError.java:87)
> bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:79)
> bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:69)
> bsh.BSHArguments.getArguments(BSHArguments.java:47)
> bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:51)
> bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:69)
> bsh.BSHAssignment.eval(BSHAssignment.java:58)
> bsh.BSHBlock.eval(BSHBlock.java:79)
> bsh.BSHBlock.eval(BSHBlock.java:44)
> bsh.BSHForStatement.eval(BSHForStatement.java:120)
> bsh.BSHBlock.eval(BSHBlock.java:79)
> bsh.BSHBlock.eval(BSHBlock.java:44)
> bsh.BSHIfStatement.eval(BSHIfStatement.java:48)
> bsh.Interpreter.evalParsedScript(Interpreter.java:1104)
> org.ofbiz.base.util.BshUtil.runBshAtLocation(BshUtil.java:169)
> org.ofbiz.widget.screen.ModelScreenAction$Script.runAction(ModelScreenAction.java:392)
> org.ofbiz.widget.screen.ModelScreenAction.runSubActions(ModelScreenAction.java:124)
> org.ofbiz.widget.screen.ModelScreenWidget$Section.renderWidgetString(ModelScreenWidget.java:247)
> org.ofbiz.widget.screen.ModelScreen.renderScreenString(ModelScreen.java:144)
> org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:115)
> org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:100)
> org.ofbiz.content.email.EmailServices.sendMailFromScreen(EmailServices.java:347)
> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> java.lang.reflect.Method.invoke(Method.java:324)
> org.ofbiz.service.engine.StandardJavaEngine.serviceInvoker(StandardJavaEngine.java:101)
> org.ofbiz.service.engine.StandardJavaEngine.runSync(StandardJavaEngine.java:63)
>
>  
> _______________________________________________
> Dev mailing list
> [hidden email]
> http://lists.ofbiz.org/mailman/listinfo/dev
>

Index: applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh
===================================================================
--- applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh (revision 7080)
+++ applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh (working copy)
@@ -252,7 +252,7 @@
     productionMap = new HashMap();
     for (iter = productIds.iterator(); iter.hasNext(); ) {
         productId = iter.next();
-        contextInput = UtilMisc.toMap("productId", productId, "userLogin", session.getAttribute("userLogin"));
+        contextInput = UtilMisc.toMap("productId", productId, "userLogin", userLogin);
         resultOutput = dispatcher.runSync("getProductManufacturingSummaryByFacility", contextInput);
         manufacturingInQuantitySummaryByFacility = resultOutput.get("summaryInByFacility");
         Double productionQuantity = (Double) manufacturingInQuantitySummaryByFacility.get("estimatedQuantityTotal");

 
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Dev - orderview error - r7059

Ray Barlow
Jacopo,

Not surprisingly it stops the null error on "session" and there are no
further error messages in the logs. I take it userLogin is defined
somewhere at a more global/higher level?

I'll test the resulting emails in the near future as this system is not
currently configured to send them anywhere.

Thanks,

Ray


Jacopo Cappellato wrote:

> Ray,
>
>
> could you please see if the attached patch will solve your problem?
>
> Thanks,
>
> Jacopo
>
> Ray wrote:
>
>> Hi Si,
>>
>> FYI I'm getting the error messages shown below in my log files since
>> your recent changes to the order view page for extra inventory
>> information.
>>
>> This happens straight after checkout of the simple order for 1
>> GZ-1001 on a clean system and DB, as the log implies it's not the
>> actual checkout process, but the email notification routine.
>>
>> Ray
>
>------------------------------------------------------------------------
>
>Index: applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh
>===================================================================
>--- applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh (revision 7080)
>+++ applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh (working copy)
>@@ -252,7 +252,7 @@
>     productionMap = new HashMap();
>     for (iter = productIds.iterator(); iter.hasNext(); ) {
>         productId = iter.next();
>-        contextInput = UtilMisc.toMap("productId", productId, "userLogin", session.getAttribute("userLogin"));
>+        contextInput = UtilMisc.toMap("productId", productId, "userLogin", userLogin);
>         resultOutput = dispatcher.runSync("getProductManufacturingSummaryByFacility", contextInput);
>         manufacturingInQuantitySummaryByFacility = resultOutput.get("summaryInByFacility");
>         Double productionQuantity = (Double) manufacturingInQuantitySummaryByFacility.get("estimatedQuantityTotal");
>  
>
>------------------------------------------------------------------------
>
>
>  
>
 
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Dev - orderview error - r7059

Jacopo Cappellato
Ray,

exactly: the screen widget framework sets the "userLogin" variable (and
many others as well) for us.

Have a nice day,

Jacopo

Ray wrote:

> Jacopo,
>
> Not surprisingly it stops the null error on "session" and there are no
> further error messages in the logs. I take it userLogin is defined
> somewhere at a more global/higher level?
>
> I'll test the resulting emails in the near future as this system is not
> currently configured to send them anywhere.
>
> Thanks,
>
> Ray
>
>
> Jacopo Cappellato wrote:
>
>> Ray,
>>
>>
>> could you please see if the attached patch will solve your problem?
>>
>> Thanks,
>>
>> Jacopo
>>
>> Ray wrote:
>>
>>> Hi Si,
>>>
>>> FYI I'm getting the error messages shown below in my log files since
>>> your recent changes to the order view page for extra inventory
>>> information.
>>>
>>> This happens straight after checkout of the simple order for 1
>>> GZ-1001 on a clean system and DB, as the log implies it's not the
>>> actual checkout process, but the email notification routine.
>>>
>>> Ray
>> ------------------------------------------------------------------------
>>
>> Index: applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh
>> ===================================================================
>> --- applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh (revision 7080)
>> +++ applications/order/webapp/ordermgr/WEB-INF/actions/order/orderview.bsh (working copy)
>> @@ -252,7 +252,7 @@
>>     productionMap = new HashMap();
>>     for (iter = productIds.iterator(); iter.hasNext(); ) {
>>         productId = iter.next();
>> -        contextInput = UtilMisc.toMap("productId", productId, "userLogin", session.getAttribute("userLogin"));
>> +        contextInput = UtilMisc.toMap("productId", productId, "userLogin", userLogin);
>>         resultOutput = dispatcher.runSync("getProductManufacturingSummaryByFacility", contextInput);
>>         manufacturingInQuantitySummaryByFacility = resultOutput.get("summaryInByFacility");
>>         Double productionQuantity = (Double) manufacturingInQuantitySummaryByFacility.get("estimatedQuantityTotal");
>>  
>>
>> ------------------------------------------------------------------------
>>
>>
>>  
>>
>  
> _______________________________________________
> Dev mailing list
> [hidden email]
> http://lists.ofbiz.org/mailman/listinfo/dev
>

 
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev