Re: svn commit: r640357 - /ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml

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

Re: svn commit: r640357 - /ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml

David E Jones-2

I haven't looked into exactly what is behind this, but generally if  
there is an error then the OUT parameters are not validated.

OUT parameters should be designed for the "success", or rather non-
error, scenarios and it is expected that if there is an error then the  
expected output parameters will likely not be there.

-David


On Mar 24, 2008, at 3:50 AM, [hidden email] wrote:

> Author: hansbak
> Date: Mon Mar 24 02:50:23 2008
> New Revision: 640357
>
> URL: http://svn.apache.org/viewvc?rev=640357&view=rev
> Log:
> in case of error no id is returned so made the outgoing service  
> field optional
>
> Modified:
>    ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml
>
> Modified: ofbiz/trunk/applications/accounting/servicedef/
> services_ledger.xml
> URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml?rev=640357&r1=640356&r2=640357&view=diff
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- ofbiz/trunk/applications/accounting/servicedef/
> services_ledger.xml (original)
> +++ ofbiz/trunk/applications/accounting/servicedef/
> services_ledger.xml Mon Mar 24 02:50:23 2008
> @@ -259,7 +259,7 @@
>         <auto-attributes include="pk" mode="IN" optional="true"/>
>         <auto-attributes include="nonpk" mode="IN" optional="true"/>
>         <attribute name="acctgTransEntries" type="java.util.List"  
> mode="IN" optional="false"/>
> -        <attribute name="acctgTransId" type="String" mode="OUT"/>
> +        <attribute name="acctgTransId" type="String" mode="OUT"  
> optional="true"/><!-- no transaction is created when an error  
> occurred -->
>     </service>
>     <service name="calculateAcctgTransTrialBalance" default-entity-
> name="AcctgTrans" engine="simple"
>             location="org/ofbiz/accounting/ledger/
> AcctgTransServices.xml" invoke="calculateAcctgTransTrialBalance"  
> auth="true">
>
>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r640357 - /ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml

hans_bakker
Hi David,

the reason i changed it is, that i got an error message together with
the message of the missing OUT parameter. This was blocking me to use
the order creation function. This change fixed the problem and i was
able to create the order.

Hans


On Mon, 2008-03-24 at 07:29 -0600, David E Jones wrote:

> I haven't looked into exactly what is behind this, but generally if  
> there is an error then the OUT parameters are not validated.
>
> OUT parameters should be designed for the "success", or rather non-
> error, scenarios and it is expected that if there is an error then the  
> expected output parameters will likely not be there.
>
> -David
>
>
> On Mar 24, 2008, at 3:50 AM, [hidden email] wrote:
> > Author: hansbak
> > Date: Mon Mar 24 02:50:23 2008
> > New Revision: 640357
> >
> > URL: http://svn.apache.org/viewvc?rev=640357&view=rev
> > Log:
> > in case of error no id is returned so made the outgoing service  
> > field optional
> >
> > Modified:
> >    ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml
> >
> > Modified: ofbiz/trunk/applications/accounting/servicedef/
> > services_ledger.xml
> > URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml?rev=640357&r1=640356&r2=640357&view=diff
> > =
> > =
> > =
> > =
> > =
> > =
> > =
> > =
> > ======================================================================
> > --- ofbiz/trunk/applications/accounting/servicedef/
> > services_ledger.xml (original)
> > +++ ofbiz/trunk/applications/accounting/servicedef/
> > services_ledger.xml Mon Mar 24 02:50:23 2008
> > @@ -259,7 +259,7 @@
> >         <auto-attributes include="pk" mode="IN" optional="true"/>
> >         <auto-attributes include="nonpk" mode="IN" optional="true"/>
> >         <attribute name="acctgTransEntries" type="java.util.List"  
> > mode="IN" optional="false"/>
> > -        <attribute name="acctgTransId" type="String" mode="OUT"/>
> > +        <attribute name="acctgTransId" type="String" mode="OUT"  
> > optional="true"/><!-- no transaction is created when an error  
> > occurred -->
> >     </service>
> >     <service name="calculateAcctgTransTrialBalance" default-entity-
> > name="AcctgTrans" engine="simple"
> >             location="org/ofbiz/accounting/ledger/
> > AcctgTransServices.xml" invoke="calculateAcctgTransTrialBalance"  
> > auth="true">
> >
> >
>
>
--
AntWebsystems.com: Quality OFBiz services for competitive rates.....

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r640357 - /ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml

Scott Gray
Hi Hans

That's not a bugfix, that's just working around (and hiding) the actual bug.

If you don't want to fix the bug then it would be best to just comment out
the offending seca in your local copy until the bug gets fixed.

My 2 cents anyway

Regards
Scott

On 25/03/2008, Hans Bakker <[hidden email]> wrote:

>
> Hi David,
>
> the reason i changed it is, that i got an error message together with
> the message of the missing OUT parameter. This was blocking me to use
> the order creation function. This change fixed the problem and i was
> able to create the order.
>
> Hans
>
>
>
> On Mon, 2008-03-24 at 07:29 -0600, David E Jones wrote:
> > I haven't looked into exactly what is behind this, but generally if
> > there is an error then the OUT parameters are not validated.
> >
> > OUT parameters should be designed for the "success", or rather non-
> > error, scenarios and it is expected that if there is an error then the
> > expected output parameters will likely not be there.
> >
> > -David
> >
> >
> > On Mar 24, 2008, at 3:50 AM, [hidden email] wrote:
> > > Author: hansbak
> > > Date: Mon Mar 24 02:50:23 2008
> > > New Revision: 640357
> > >
> > > URL: http://svn.apache.org/viewvc?rev=640357&view=rev
> > > Log:
> > > in case of error no id is returned so made the outgoing service
> > > field optional
> > >
> > > Modified:
> > >    ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml
> > >
> > > Modified: ofbiz/trunk/applications/accounting/servicedef/
> > > services_ledger.xml
> > > URL:
> http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml?rev=640357&r1=640356&r2=640357&view=diff
> > > =
> > > =
> > > =
> > > =
> > > =
> > > =
> > > =
> > > =
> > > ======================================================================
> > > --- ofbiz/trunk/applications/accounting/servicedef/
> > > services_ledger.xml (original)
> > > +++ ofbiz/trunk/applications/accounting/servicedef/
> > > services_ledger.xml Mon Mar 24 02:50:23 2008
> > > @@ -259,7 +259,7 @@
> > >         <auto-attributes include="pk" mode="IN" optional="true"/>
> > >         <auto-attributes include="nonpk" mode="IN" optional="true"/>
> > >         <attribute name="acctgTransEntries" type="java.util.List"
> > > mode="IN" optional="false"/>
> > > -        <attribute name="acctgTransId" type="String" mode="OUT"/>
> > > +        <attribute name="acctgTransId" type="String" mode="OUT"
> > > optional="true"/><!-- no transaction is created when an error
> > > occurred -->
> > >     </service>
> > >     <service name="calculateAcctgTransTrialBalance" default-entity-
> > > name="AcctgTrans" engine="simple"
> > >             location="org/ofbiz/accounting/ledger/
> > > AcctgTransServices.xml" invoke="calculateAcctgTransTrialBalance"
> > > auth="true">
> > >
> > >
> >
> >
>
> --
> AntWebsystems.com: Quality OFBiz services for competitive rates.....
>
>
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r640357 - /ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml

Tim Ruppert
Yeah, I'd have to give a +1 to either fixing it right or not messing  
with it.  This does appear to be hiding the actual issue

On Mar 25, 2008, at 1:44 AM, Scott Gray wrote:

> Hi Hans
>
> That's not a bugfix, that's just working around (and hiding) the  
> actual bug.
>
> If you don't want to fix the bug then it would be best to just  
> comment out
> the offending seca in your local copy until the bug gets fixed.
>
> My 2 cents anyway
>
> Regards
> Scott
>
> On 25/03/2008, Hans Bakker <[hidden email]> wrote:
>>
>> Hi David,
>>
>> the reason i changed it is, that i got an error message together with
>> the message of the missing OUT parameter. This was blocking me to use
>> the order creation function. This change fixed the problem and i was
>> able to create the order.
>>
>> Hans
>>
>>
>>
>> On Mon, 2008-03-24 at 07:29 -0600, David E Jones wrote:
>>> I haven't looked into exactly what is behind this, but generally if
>>> there is an error then the OUT parameters are not validated.
>>>
>>> OUT parameters should be designed for the "success", or rather non-
>>> error, scenarios and it is expected that if there is an error then  
>>> the
>>> expected output parameters will likely not be there.
>>>
>>> -David
>>>
>>>
>>> On Mar 24, 2008, at 3:50 AM, [hidden email] wrote:
>>>> Author: hansbak
>>>> Date: Mon Mar 24 02:50:23 2008
>>>> New Revision: 640357
>>>>
>>>> URL: http://svn.apache.org/viewvc?rev=640357&view=rev
>>>> Log:
>>>> in case of error no id is returned so made the outgoing service
>>>> field optional
>>>>
>>>> Modified:
>>>>   ofbiz/trunk/applications/accounting/servicedef/
>>>> services_ledger.xml
>>>>
>>>> Modified: ofbiz/trunk/applications/accounting/servicedef/
>>>> services_ledger.xml
>>>> URL:
>> http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/services_ledger.xml?rev=640357&r1=640356&r2=640357&view=diff
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> ===================================================================
>>>> --- ofbiz/trunk/applications/accounting/servicedef/
>>>> services_ledger.xml (original)
>>>> +++ ofbiz/trunk/applications/accounting/servicedef/
>>>> services_ledger.xml Mon Mar 24 02:50:23 2008
>>>> @@ -259,7 +259,7 @@
>>>>        <auto-attributes include="pk" mode="IN" optional="true"/>
>>>>        <auto-attributes include="nonpk" mode="IN" optional="true"/>
>>>>        <attribute name="acctgTransEntries" type="java.util.List"
>>>> mode="IN" optional="false"/>
>>>> -        <attribute name="acctgTransId" type="String" mode="OUT"/>
>>>> +        <attribute name="acctgTransId" type="String" mode="OUT"
>>>> optional="true"/><!-- no transaction is created when an error
>>>> occurred -->
>>>>    </service>
>>>>    <service name="calculateAcctgTransTrialBalance" default-entity-
>>>> name="AcctgTrans" engine="simple"
>>>>            location="org/ofbiz/accounting/ledger/
>>>> AcctgTransServices.xml" invoke="calculateAcctgTransTrialBalance"
>>>> auth="true">
>>>>
>>>>
>>>
>>>
>>
>> --
>> AntWebsystems.com: Quality OFBiz services for competitive rates.....
>>
>>


smime.p7s (3K) Download Attachment