If a service is implemented as an interface, its settings for optional attributes are ignored!
---------------------------------------------------------------------------------------------- Key: OFBIZ-309 URL: http://issues.apache.org/jira/browse/OFBIZ-309 Project: OFBiz (The Open for Business Project) Issue Type: Bug Components: framework Affects Versions: SVN trunk Reporter: Leon Torres Priority: Critical This is bad: If a service has some attributes with optional="false" and is implemented with <implements service="">, the settings for optional are ignored and default to "true" instead. As an example, look up the service definition for upsRateEstimate in webtools and compare to the service that it implements, calcShipmentEstimateInterface. The interface defines a few optional fields as false, which show up correctly for calcShipmentEstimateInterface but are all set to true in upsRateEstimate. It used to work, something must have broken it. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
[ http://issues.apache.org/jira/browse/OFBIZ-309?page=comments#action_12451089 ]
Hederer Jean-Sébastien commented on OFBIZ-309: ---------------------------------------------- Leon, is the problem always on trunk? If yes, perhaps should you explain a little bit more the problem. I tried to look at code and didn't saw the problem. I think that as a critical bug we should try to solve it. > If a service is implemented as an interface, its settings for optional attributes are ignored! > ---------------------------------------------------------------------------------------------- > > Key: OFBIZ-309 > URL: http://issues.apache.org/jira/browse/OFBIZ-309 > Project: OFBiz (The Open for Business Project) > Issue Type: Bug > Components: framework > Affects Versions: SVN trunk > Reporter: Leon Torres > Priority: Critical > > This is bad: > If a service has some attributes with optional="false" and is implemented with <implements service="">, the settings for optional are ignored and default to "true" instead. > As an example, look up the service definition for upsRateEstimate in webtools and compare to the service that it implements, calcShipmentEstimateInterface. The interface defines a few optional fields as false, which show up correctly for calcShipmentEstimateInterface but are all set to true in upsRateEstimate. > It used to work, something must have broken it. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
In reply to this post by Nicolas Malin (Jira)
[ http://issues.apache.org/jira/browse/OFBIZ-309?page=comments#action_12455481 ]
Leon Torres commented on OFBIZ-309: ----------------------------------- Yes, it's still on trunk. Briefly, if you look at the reference for upsRateEstimate: https://localhost:8443/webtools/control/availableServices?sel_service_name=upsRateEstimate Notice how all the IN parameters are optional? That is wrong. If you look at the servicedef for upsRateEstimate, it implements calcShipEstimateInterface: https://localhost:8443/webtools/control/availableServices?sel_service_name=calcShipmentEstimateInterface In this service, the required fields are correctly identified. This isn't just a display bug, if you try using the service upsRateEstimate and leave out the required fields, such as shippingContactMechId, there will be bugs and data errors. The severity of this bug is critical because many services rely on the Service Engine to correctly validate required parameters. > If a service is implemented as an interface, its settings for optional attributes are ignored! > ---------------------------------------------------------------------------------------------- > > Key: OFBIZ-309 > URL: http://issues.apache.org/jira/browse/OFBIZ-309 > Project: OFBiz (The Open for Business Project) > Issue Type: Bug > Components: framework > Affects Versions: SVN trunk > Reporter: Leon Torres > Priority: Critical > > This is bad: > If a service has some attributes with optional="false" and is implemented with <implements service="">, the settings for optional are ignored and default to "true" instead. > As an example, look up the service definition for upsRateEstimate in webtools and compare to the service that it implements, calcShipmentEstimateInterface. The interface defines a few optional fields as false, which show up correctly for calcShipmentEstimateInterface but are all set to true in upsRateEstimate. > It used to work, something must have broken it. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
Free forum by Nabble | Edit this page |