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

ASF GitHub Bot commented on NUTCH-2254:
---------------------------------------

GitHub user sebastian-nagel opened a pull request:

    https://github.com/apache/nutch/pull/107

    NUTCH-2254 Indexer: character set issue with -addBinaryContent and -base64

    - generate base64 encoded string directly from content bytes
       (based on patch provided by Federico Bonelli)
    - add JUnit test indexing base64-encoded binary content
       with UTF-8, ISO-8859-1 and ISO-8859-2 character sets

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/sebastian-nagel/nutch NUTCH-2254

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/nutch/pull/107.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #107
    
----
commit 92516a97e10596d0564582d52f4f693b4fd407db
Author: Sebastian Nagel <[email protected]>
Date:   2016-04-25T12:40:44Z

    NUTCH-2254 Indexer: character set issue with -addBinaryContent and -base64
     - generate base64 encoded string directly from content bytes
       (patch provided by Federico Bonelli)
     - add JUnit test to test indexing base64 encoded binary content
       with UTF-8, ISO-8859-1 and ISO-8859-2 character sets

----


> Charset issues when using -addBinaryContent and -base64 options
> ---------------------------------------------------------------
>
>                 Key: NUTCH-2254
>                 URL: https://issues.apache.org/jira/browse/NUTCH-2254
>             Project: Nutch
>          Issue Type: Bug
>          Components: indexer
>    Affects Versions: 1.11
>            Reporter: Federico Bonelli
>            Priority: Minor
>         Attachments: base64-nutch.patch
>
>
> The bug is reproducible with these steps:
> # find a site with cp1252 encoded pages like "http://www.ilsole24ore.com/"; 
> and characters with accents (byte representation >127, like [àèéìòù])
> # start a crawl on that site indexing on Solr with options -addBinaryContent 
> -base64
> # find a document inside the newly indexed Solr collection with those 
> accented characters
> # get the base64 binary representation for said html page and decode it back 
> to raw binary, save it
> The file obtained will have invalid characters, which are neither UTF-8 nor 
> cp1252.



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

Reply via email to