You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Paul Foxworthy (JIRA)" <ji...@apache.org> on 2012/10/04 09:17:07 UTC

[jira] [Created] (OFBIZ-5046) Recalculate Order causes NumberFormatException

Paul Foxworthy created OFBIZ-5046:
-------------------------------------

             Summary: Recalculate Order causes NumberFormatException
                 Key: OFBIZ-5046
                 URL: https://issues.apache.org/jira/browse/OFBIZ-5046
             Project: OFBiz
          Issue Type: Bug
          Components: order
    Affects Versions: SVN trunk
            Reporter: Paul Foxworthy
            Priority: Minor


On demo site, create a new order by using the URL

https://demo-trunk.ofbiz.apache.org/ordermgr/control/orderentry

Enter any Product ID, e.g. GZ-1000
Enter a Quntity, e.g. 1
Click on Add To Order

Now click on Recalculate Order on the title bar of the Create Order screenlet

Check the logs. On the demo site, you can do this with the URL

https://demo-trunk.ofbiz.apache.org/webtools/control/LogView

You will see:

Exception: java.lang.NumberFormatException Message: For input string: "i18n" ---- stack trace --------------------------------------------------------------- java.lang.NumberFormatException: For input string: "i18n" java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) java.lang.Integer.parseInt(Integer.java:449) java.lang.Integer.parseInt(Integer.java:499) org.ofbiz.order.shoppingcart.ShoppingCartHelper.modifyCart(ShoppingCartHelper.java:673)

The problem is the suffix _i18n on the input elements. The code in modifycart assumes the last thing in the parameter names is a sequence number.

The attached patch filters out _i18n parameters.

This problem is not as severe as OFBIZ-5045, because the exception is swallowed immediately and the cart is updated properly. Still, these exceptions slow down OFBiz and add noise to the logs.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (OFBIZ-5046) Recalculate Order causes NumberFormatException

Posted by "Paul Foxworthy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-5046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Foxworthy updated OFBIZ-5046:
----------------------------------

    Description: 
On demo site, create a new order by using the URL

https://demo-trunk.ofbiz.apache.org/ordermgr/control/orderentry

Enter any Product ID, e.g. GZ-1000
Enter a Quantity, e.g. 1
Click on Add To Order

Now click on Recalculate Order on the title bar of the Create Order screenlet

Check the logs. On the demo site, you can do this with the URL

https://demo-trunk.ofbiz.apache.org/webtools/control/LogView

You will see:

Exception: java.lang.NumberFormatException Message: For input string: "i18n" ---- stack trace --------------------------------------------------------------- java.lang.NumberFormatException: For input string: "i18n" java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) java.lang.Integer.parseInt(Integer.java:449) java.lang.Integer.parseInt(Integer.java:499) org.ofbiz.order.shoppingcart.ShoppingCartHelper.modifyCart(ShoppingCartHelper.java:673)

The problem is the suffix _i18n on the input elements. The code in modifycart assumes the last thing in the parameter names is a sequence number.

The attached patch filters out _i18n parameters.

This problem is not as severe as OFBIZ-5045, because the exception is swallowed immediately and the cart is updated properly. Still, these exceptions slow down OFBiz and add noise to the logs.

  was:
On demo site, create a new order by using the URL

https://demo-trunk.ofbiz.apache.org/ordermgr/control/orderentry

Enter any Product ID, e.g. GZ-1000
Enter a Quntity, e.g. 1
Click on Add To Order

Now click on Recalculate Order on the title bar of the Create Order screenlet

Check the logs. On the demo site, you can do this with the URL

https://demo-trunk.ofbiz.apache.org/webtools/control/LogView

You will see:

Exception: java.lang.NumberFormatException Message: For input string: "i18n" ---- stack trace --------------------------------------------------------------- java.lang.NumberFormatException: For input string: "i18n" java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) java.lang.Integer.parseInt(Integer.java:449) java.lang.Integer.parseInt(Integer.java:499) org.ofbiz.order.shoppingcart.ShoppingCartHelper.modifyCart(ShoppingCartHelper.java:673)

The problem is the suffix _i18n on the input elements. The code in modifycart assumes the last thing in the parameter names is a sequence number.

The attached patch filters out _i18n parameters.

This problem is not as severe as OFBIZ-5045, because the exception is swallowed immediately and the cart is updated properly. Still, these exceptions slow down OFBiz and add noise to the logs.

    
> Recalculate Order causes NumberFormatException
> ----------------------------------------------
>
>                 Key: OFBIZ-5046
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-5046
>             Project: OFBiz
>          Issue Type: Bug
>          Components: order
>    Affects Versions: SVN trunk
>            Reporter: Paul Foxworthy
>            Priority: Minor
>         Attachments: OFBIZ-5046_RecalculateOrderNumberFormatException
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> On demo site, create a new order by using the URL
> https://demo-trunk.ofbiz.apache.org/ordermgr/control/orderentry
> Enter any Product ID, e.g. GZ-1000
> Enter a Quantity, e.g. 1
> Click on Add To Order
> Now click on Recalculate Order on the title bar of the Create Order screenlet
> Check the logs. On the demo site, you can do this with the URL
> https://demo-trunk.ofbiz.apache.org/webtools/control/LogView
> You will see:
> Exception: java.lang.NumberFormatException Message: For input string: "i18n" ---- stack trace --------------------------------------------------------------- java.lang.NumberFormatException: For input string: "i18n" java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) java.lang.Integer.parseInt(Integer.java:449) java.lang.Integer.parseInt(Integer.java:499) org.ofbiz.order.shoppingcart.ShoppingCartHelper.modifyCart(ShoppingCartHelper.java:673)
> The problem is the suffix _i18n on the input elements. The code in modifycart assumes the last thing in the parameter names is a sequence number.
> The attached patch filters out _i18n parameters.
> This problem is not as severe as OFBIZ-5045, because the exception is swallowed immediately and the cart is updated properly. Still, these exceptions slow down OFBiz and add noise to the logs.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Closed] (OFBIZ-5046) Recalculate Order causes NumberFormatException

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-5046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacques Le Roux closed OFBIZ-5046.
----------------------------------

       Resolution: Fixed
    Fix Version/s: Release Branch 12.04
                   SVN trunk
                   Release Branch 11.04
                   Release Branch 10.04

Thanks Paul,

Your patch is in
trunk r1393948
R12.04 r1393952
R11.04 r1393967
R10.04 r1393972


                
> Recalculate Order causes NumberFormatException
> ----------------------------------------------
>
>                 Key: OFBIZ-5046
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-5046
>             Project: OFBiz
>          Issue Type: Bug
>          Components: order
>    Affects Versions: SVN trunk
>            Reporter: Paul Foxworthy
>            Assignee: Jacques Le Roux
>            Priority: Minor
>             Fix For: Release Branch 10.04, Release Branch 11.04, SVN trunk, Release Branch 12.04
>
>         Attachments: OFBIZ-5046_RecalculateOrderNumberFormatException
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> On demo site, create a new order by using the URL
> https://demo-trunk.ofbiz.apache.org/ordermgr/control/orderentry
> Enter any Product ID, e.g. GZ-1000
> Enter a Quantity, e.g. 1
> Click on Add To Order
> Now click on Recalculate Order on the title bar of the Create Order screenlet
> Check the logs. On the demo site, you can do this with the URL
> https://demo-trunk.ofbiz.apache.org/webtools/control/LogView
> You will see:
> Exception: java.lang.NumberFormatException Message: For input string: "i18n" ---- stack trace --------------------------------------------------------------- java.lang.NumberFormatException: For input string: "i18n" java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) java.lang.Integer.parseInt(Integer.java:449) java.lang.Integer.parseInt(Integer.java:499) org.ofbiz.order.shoppingcart.ShoppingCartHelper.modifyCart(ShoppingCartHelper.java:673)
> The problem is the suffix _i18n on the input elements. The code in modifycart assumes the last thing in the parameter names is a sequence number.
> The attached patch filters out _i18n parameters.
> This problem is not as severe as OFBIZ-5045, because the exception is swallowed immediately and the cart is updated properly. Still, these exceptions slow down OFBiz and add noise to the logs.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (OFBIZ-5046) Recalculate Order causes NumberFormatException

Posted by "Paul Foxworthy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-5046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Foxworthy updated OFBIZ-5046:
----------------------------------

    Attachment: OFBIZ-5046_RecalculateOrderNumberFormatException
    
> Recalculate Order causes NumberFormatException
> ----------------------------------------------
>
>                 Key: OFBIZ-5046
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-5046
>             Project: OFBiz
>          Issue Type: Bug
>          Components: order
>    Affects Versions: SVN trunk
>            Reporter: Paul Foxworthy
>            Priority: Minor
>         Attachments: OFBIZ-5046_RecalculateOrderNumberFormatException
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> On demo site, create a new order by using the URL
> https://demo-trunk.ofbiz.apache.org/ordermgr/control/orderentry
> Enter any Product ID, e.g. GZ-1000
> Enter a Quntity, e.g. 1
> Click on Add To Order
> Now click on Recalculate Order on the title bar of the Create Order screenlet
> Check the logs. On the demo site, you can do this with the URL
> https://demo-trunk.ofbiz.apache.org/webtools/control/LogView
> You will see:
> Exception: java.lang.NumberFormatException Message: For input string: "i18n" ---- stack trace --------------------------------------------------------------- java.lang.NumberFormatException: For input string: "i18n" java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) java.lang.Integer.parseInt(Integer.java:449) java.lang.Integer.parseInt(Integer.java:499) org.ofbiz.order.shoppingcart.ShoppingCartHelper.modifyCart(ShoppingCartHelper.java:673)
> The problem is the suffix _i18n on the input elements. The code in modifycart assumes the last thing in the parameter names is a sequence number.
> The attached patch filters out _i18n parameters.
> This problem is not as severe as OFBIZ-5045, because the exception is swallowed immediately and the cart is updated properly. Still, these exceptions slow down OFBiz and add noise to the logs.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Assigned] (OFBIZ-5046) Recalculate Order causes NumberFormatException

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-5046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacques Le Roux reassigned OFBIZ-5046:
--------------------------------------

    Assignee: Jacques Le Roux
    
> Recalculate Order causes NumberFormatException
> ----------------------------------------------
>
>                 Key: OFBIZ-5046
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-5046
>             Project: OFBiz
>          Issue Type: Bug
>          Components: order
>    Affects Versions: SVN trunk
>            Reporter: Paul Foxworthy
>            Assignee: Jacques Le Roux
>            Priority: Minor
>         Attachments: OFBIZ-5046_RecalculateOrderNumberFormatException
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> On demo site, create a new order by using the URL
> https://demo-trunk.ofbiz.apache.org/ordermgr/control/orderentry
> Enter any Product ID, e.g. GZ-1000
> Enter a Quantity, e.g. 1
> Click on Add To Order
> Now click on Recalculate Order on the title bar of the Create Order screenlet
> Check the logs. On the demo site, you can do this with the URL
> https://demo-trunk.ofbiz.apache.org/webtools/control/LogView
> You will see:
> Exception: java.lang.NumberFormatException Message: For input string: "i18n" ---- stack trace --------------------------------------------------------------- java.lang.NumberFormatException: For input string: "i18n" java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) java.lang.Integer.parseInt(Integer.java:449) java.lang.Integer.parseInt(Integer.java:499) org.ofbiz.order.shoppingcart.ShoppingCartHelper.modifyCart(ShoppingCartHelper.java:673)
> The problem is the suffix _i18n on the input elements. The code in modifycart assumes the last thing in the parameter names is a sequence number.
> The attached patch filters out _i18n parameters.
> This problem is not as severe as OFBIZ-5045, because the exception is swallowed immediately and the cart is updated properly. Still, these exceptions slow down OFBiz and add noise to the logs.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira