You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by Jacques Le Roux <ja...@les7arts.com> on 2023/05/09 06:07:08 UTC

Improved: EntityUtil getProperty Methods dont use entity (OFBIZ-12815) PR#635

Hi,

Tobias Hahn has created the PR#635. It looks good to me, and I have suggested to deprecate the replaced methods.

Then I thought that we could maybe remove the old methods. As I said in a PR comment:

    <<I checked the usage in Java and Groovy code of the previous methods I talked about above. Most of them are not used at all OOTB.
    getPropertyAsBoolean and getPropertyAsBigDecimal are both used twice in Java, getPropertyAsInteger is used 21 times in Java and 6 in Groovy.

    It could be that OFBiz users are using them more. But it's really easy to replace them by UtilProperties ones or the new EntityUtilProperties ones.
    So maybe we could remove them all together OOTB.  And replace those used by calls to the new ones you introduce.>>

What do you think, should we only deprecate and wait? Note that this will only be done in trunk.

Thanks

Jacques


Re: Improved: EntityUtil getProperty Methods dont use entity (OFBIZ-12815) PR#635

Posted by Jacques Le Roux <ja...@les7arts.com>.
Hi Michael, All,

I agree that following the rules should be, they are there for a reason.

What about, in the same push, replacing the current few OOTB useless calls by the new ones while deprecating the useless methods?
Then

  * there are no users's migration side-effects.
  * We have already real functional methods used.
  * We have only to remove those useless methods from trunk/next release after creating 23.x branch.

Jacques

Le 10/05/2023 à 08:42, michael.brohl@ecomify.de a écrit :
> I‘d suggest to deprecate in trunk and therefore for the next release branch 23.x.
> After the release branch is created, remove from trunk/next release.
>
> Regards,
>
> Michael
>
>
>> Am 09.05.2023 um 19:19 schrieb Jacques Le Roux<ja...@les7arts.com>:
>>
>> Hi,
>>
>> Tobias Hahn has created the PR#635. It looks good to me, and I have suggested to deprecate the replaced methods.
>>
>> Then I thought that we could maybe remove the old methods. As I said in a PR comment:
>>
>>    <<I checked the usage in Java and Groovy code of the previous methods I talked about above. Most of them are not used at all OOTB.
>>    getPropertyAsBoolean and getPropertyAsBigDecimal are both used twice in Java, getPropertyAsInteger is used 21 times in Java and 6 in Groovy.
>>
>>    It could be that OFBiz users are using them more. But it's really easy to replace them by UtilProperties ones or the new EntityUtilProperties ones.
>>    So maybe we could remove them all together OOTB.  And replace those used by calls to the new ones you introduce.>>
>>
>> What do you think, should we only deprecate and wait? Note that this will only be done in trunk.
>>
>> Thanks
>>
>> Jacques
>>

Re: Improved: EntityUtil getProperty Methods dont use entity (OFBIZ-12815) PR#635

Posted by "michael.brohl@ecomify.de" <mi...@ecomify.de>.
I‘d suggest to deprecate in trunk and therefore for the next release branch 23.x.
After the release branch is created, remove from trunk/next release.

Regards,

Michael 


> Am 09.05.2023 um 19:19 schrieb Jacques Le Roux <ja...@les7arts.com>:
> 
> Hi,
> 
> Tobias Hahn has created the PR#635. It looks good to me, and I have suggested to deprecate the replaced methods.
> 
> Then I thought that we could maybe remove the old methods. As I said in a PR comment:
> 
>   <<I checked the usage in Java and Groovy code of the previous methods I talked about above. Most of them are not used at all OOTB.
>   getPropertyAsBoolean and getPropertyAsBigDecimal are both used twice in Java, getPropertyAsInteger is used 21 times in Java and 6 in Groovy.
> 
>   It could be that OFBiz users are using them more. But it's really easy to replace them by UtilProperties ones or the new EntityUtilProperties ones.
>   So maybe we could remove them all together OOTB.  And replace those used by calls to the new ones you introduce.>>
> 
> What do you think, should we only deprecate and wait? Note that this will only be done in trunk.
> 
> Thanks
> 
> Jacques
> 

Re: Improved: EntityUtil getProperty Methods dont use entity (OFBIZ-12815) PR#635

Posted by Jacques Le Roux <jl...@apache.org>.
This message did not pass with my own address, here is a copy with my Apache address

Le 09/05/2023 à 08:07, Jacques Le Roux a écrit :
>
> Hi,
>
> Tobias Hahn has created the PR#635. It looks good to me, and I have suggested to deprecate the replaced methods.
>
> Then I thought that we could maybe remove the old methods. As I said in a PR comment:
>
>     <<I checked the usage in Java and Groovy code of the previous methods I talked about above. Most of them are not used at all OOTB.
>     getPropertyAsBoolean and getPropertyAsBigDecimal are both used twice in Java, getPropertyAsInteger is used 21 times in Java and 6 in Groovy.
>
>     It could be that OFBiz users are using them more. But it's really easy to replace them by UtilProperties ones or the new EntityUtilProperties ones.
>     So maybe we could remove them all together OOTB.  And replace those used by calls to the new ones you introduce.>>
>
> What do you think, should we only deprecate and wait? Note that this will only be done in trunk.
>
> Thanks
>
> Jacques
>
>