You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@olingo.apache.org by "Akitoshi Yoshida (JIRA)" <ji...@apache.org> on 2015/08/03 16:00:09 UTC

[jira] [Updated] (OLINGO-745) ODataRequestHandler.checkConditions performs an inefficient comparison

     [ https://issues.apache.org/jira/browse/OLINGO-745?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Akitoshi Yoshida updated OLINGO-745:
------------------------------------
    Attachment: 0001-OLINGO-745-ODataRequestHandler.checkConditions-perfo.patch

> ODataRequestHandler.checkConditions performs an inefficient comparison
> ----------------------------------------------------------------------
>
>                 Key: OLINGO-745
>                 URL: https://issues.apache.org/jira/browse/OLINGO-745
>             Project: Olingo
>          Issue Type: Improvement
>          Components: odata2-core
>    Affects Versions: V2 2.0.4
>            Reporter: Akitoshi Yoshida
>            Priority: Minor
>         Attachments: 0001-OLINGO-745-ODataRequestHandler.checkConditions-perfo.patch
>
>
> There is a comparison code in the above method that creates an array dynamically each time and checks the containment.
> Arrays.asList(UriType.URI2, UriType.URI6A, UriType.URI3, UriType.URI4, UriType.URI5, UriType.URI17)
>             .contains(uriInfo.getUriType())
> Creating an array list to do this comparison here is inefficient and it should be replaced with a simple == comparison. (an order of magnitude faster).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)