manifoldcf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Furkan KAMACI (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CONNECTORS-1304) ban usage of String.toUpperCase() without Locale
Date Mon, 15 Aug 2016 14:41:20 GMT

    [ https://issues.apache.org/jira/browse/CONNECTORS-1304?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15421072#comment-15421072
] 

Furkan KAMACI commented on CONNECTORS-1304:
-------------------------------------------

[~kwright@metacarta.com] 

(1) forbidden-apis should be run after the "build" target and it is similar to build. So,
I followed the convention of "build" task at parent build.xml. It points to framework/build.xml
via:

{code:xml}
<target name="build-framework" depends="setup-framework" if="downloaded">
  <ant dir="framework" target="build"/>
</target>
{code}

So, I've pointed to framework/build.xml to obey the convention.

(2) I agree with you. It can be removed any other place or can be placed at ~/.ant/lib. However
first option could be better and meaningful with creating rat task [~iorixxx] is suggested.
I've created a general task which is named as precommit to extend it. So, we can build rat
under a rat task and bind it to precommit without touching libraries of dist (at a separate
folder).

(3) It checks for the Java byte codes and skips unnecessary files. However, if you have some
concerns (i.e. performance) we can move them into individual build.xml files (I thought the
same when I implement that feature but also tought that it may not be easily manageable too).

> ban usage of String.toUpperCase() without Locale
> ------------------------------------------------
>
>                 Key: CONNECTORS-1304
>                 URL: https://issues.apache.org/jira/browse/CONNECTORS-1304
>             Project: ManifoldCF
>          Issue Type: Improvement
>          Components: SearchBlox connector
>    Affects Versions: ManifoldCF 2.4
>            Reporter: Ahmet Arslan
>            Assignee: Ahmet Arslan
>             Fix For: ManifoldCF 2.5
>
>
> When relied on the default Locale, toUpperCase() is not reliable. For example: In SearchBloxConnector.java,
"title_boost".toUpperCase() will yield {{TÄ°TLE_BOOST}} on Turkish Locale and won't match
{{TITLE_BOOST}}. We should prevent this in a more permanent way. I would like to integrate
Uwe's [forbidden apis|https://github.com/policeman-tools/forbidden-apis] when I have time.



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

Mime
View raw message