Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 200430 - Query synchronization doesn't work when server is using ISO-8859-1 + Portuguese
Summary: Query synchronization doesn't work when server is using ISO-8859-1 + Portuguese
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Mylyn (show other bugs)
Version: 2.0   Edit
Hardware: PC Linux
: P2 critical (vote)
Target Milestone: 2.1   Edit
Assignee: Steffen Pingel CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-08-17 16:32 EDT by Bruno Luiz Pereira da Silva CLA
Modified: 2007-09-20 16:43 EDT (History)
2 users (show)

See Also:


Attachments
Error message screen (77.12 KB, image/png)
2007-08-17 16:32 EDT, Bruno Luiz Pereira da Silva CLA
no flags Details
JIRA repository configuration screen (98.06 KB, image/png)
2007-08-17 16:33 EDT, Bruno Luiz Pereira da Silva CLA
no flags Details
JIRA standalone configuration screen (188.65 KB, image/png)
2007-08-18 12:01 EDT, Bruno Luiz Pereira da Silva CLA
no flags Details
Eclipse configuration details (220.46 KB, text/plain)
2007-08-18 12:03 EDT, Bruno Luiz Pereira da Silva CLA
no flags Details
Jira backup (6.13 KB, application/zip)
2007-08-18 13:50 EDT, Bruno Luiz Pereira da Silva CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Bruno Luiz Pereira da Silva CLA 2007-08-17 16:32:35 EDT
Created attachment 76335 [details]
Error message screen

Build ID: I20070625-1500

Steps To Reproduce:
1. Create new query in JIRA repository using form
2. Try to synchronize query

More information:
Plugin versions I'm using here (captured from Eclipse Configuration Details) are:

org.eclipse.mylyn_feature (2.0.0.v20070810-1700) "Mylyn"
org.eclipse.mylyn.bugzilla_feature (2.0.0.v20070810-1700) "Mylyn"
org.eclipse.mylyn.context_feature (2.0.0.v20070810-1700) "Mylyn"
org.eclipse.mylyn.ide_feature (2.0.0.v20070810-1700) "Mylyn"
org.eclipse.mylyn.java_feature (2.0.0.v20070810-1700) "Mylyn"
org.eclipse.mylyn.jira_feature (2.0.0.v20070810-1700) "Mylyn"
org.eclipse.mylyn.pde_feature (2.0.0.v20070810-1700) "Mylyn"

The problem I'm facing is getting queries to work. The error message I'm getting when i try to synchronize a query is:
"com.sun.org.apache.xerces.internal.impl.io.MalformedByteSequenceException:
Invalid byte 2 of 3-byte UTF-8 sequence"

I'm using Eclipse 3.3 on Linux with jdk1.6.0_01 on a 32-bit platform, and the JIRA version here is 3.9. I cannot synchronize queries created via Eclipse form and also filters created inside JIRA.
Comment 1 Bruno Luiz Pereira da Silva CLA 2007-08-17 16:33:22 EDT
Created attachment 76337 [details]
JIRA repository configuration screen
Comment 2 Eugene Kuleshov CLA 2007-08-17 18:38:49 EDT
Is your JIRA really using HTTP auth? Usually that is only needed when if on the web UI you get the popup dialog from the web browser asking for credentials. If not, you should NOT check HTTP auth in repository configuration.

BTW, also check Error Log view (Window / Show View / Error Log) for more details on the exception. In some cases it may be necessary to enable debug tracing as described at http://wiki.eclipse.org/Mylyn_FAQ#Reporting_issues
Comment 3 Bruno Luiz Pereira da Silva CLA 2007-08-18 10:31:20 EDT
Eugene, I installed JIRA standalone on my machine and did a lot of tests. I've also talked to my company's JIRA admin and I got our server configuration from him.

The problem is much more specific than i though. The synchronization fails only when the server is set to use ISO-8859-1 as the encoding AND Portuguese as the default language. I synchronize successfully when the server is using UTF-8 + English, UTF-8 + Portuguese or ISO-8859-1 + English.

However, when the server is using ISO-8859-1 + Portuguese, the synchronization always fails, no matter which encoding i choose to use in the plugin settings. I tried using many of the encodings avaiable in the plugin settings, and none worked with the server using ISO-8859-1 + Portuguese.

On monday i'll talk again with our JIRA admin and see if there's any chance we can change the server encoding to UTF-8. I hope it's possible, so that i can finally get to use the integration with JIRA again.

Please tell me if there's any chance to get the synchronization working using ISO-8859-1 + Portuguese, and of course, ask me everything else i can tell you in order to help.

Thanks a lot for all the attention and support.
Comment 4 Eugene Kuleshov CLA 2007-08-18 10:51:08 EDT
(In reply to comment #3)
> Eugene, I installed JIRA standalone on my machine and did a lot of tests. I've
> also talked to my company's JIRA admin and I got our server configuration from
> him.

That is sounds like a great progress.

> The problem is much more specific than i though. The synchronization fails only
> when the server is set to use ISO-8859-1 as the encoding AND Portuguese as the
> default language. I synchronize successfully when the server is using UTF-8 +
> English, UTF-8 + Portuguese or ISO-8859-1 + English.

That narrows it down... Do you still use http auth settings on repository configuration dialog?

> However, when the server is using ISO-8859-1 + Portuguese, the synchronization
> always fails, no matter which encoding i choose to use in the plugin settings. I
> tried using many of the encodings avaiable in the plugin settings, and none
> worked with the server using ISO-8859-1 + Portuguese.
> 
> On monday i'll talk again with our JIRA admin and see if there's any chance we
> can change the server encoding to UTF-8. I hope it's possible, so that i can
> finally get to use the integration with JIRA again.
> 
> Please tell me if there's any chance to get the synchronization working using
> ISO-8859-1 + Portuguese, and of course, ask me everything else i can tell you in
> order to help.

It sounds like a bug in the connector. Would it be possible to get your JIRA configuration that you've used to reproduce this issue locally, maybe you can email it to me? Also, can you please attach info about your Eclipse environment (Help / About Eclipse SDK / Configuration Details...).
Comment 5 Bruno Luiz Pereira da Silva CLA 2007-08-18 12:00:05 EDT
Eugene, regarding HTTP authentication, I'm not using it anymore, but as a matter of fact, i tried many times to synchronize queries with HTTP authentication ON and OFF, and haven't noticed any different results by using it ON or OFF. It seems like it doesn't make a difference. As it didn't make any difference, i'm currently leaving it OFF.

Regarding the server configuration, I'm attaching a screenshot of the server configuration on my local JIRA server at home. The JIRA version here at home is 3.10 and my local JIRA at work and the company's JIRA version is 3.9, but from my usual use of JIRA i haven't noticed any changes that could mean something to our problem.

As you requested, i'm also going to attach my Eclipse configuration details. The configuration I'm using at home is a bit different from the one at work, but both installations use Eclipse Europa, and both use the same versions of all Mylyn Plugins.

Again, thanks for the quick reply and warn me if i can provide more useful information.
Comment 6 Bruno Luiz Pereira da Silva CLA 2007-08-18 12:01:11 EDT
Created attachment 76369 [details]
JIRA standalone configuration screen
Comment 7 Bruno Luiz Pereira da Silva CLA 2007-08-18 12:03:55 EDT
Created attachment 76370 [details]
Eclipse configuration details
Comment 8 Eugene Kuleshov CLA 2007-08-18 13:08:43 EDT
(In reply to comment #5)
> Regarding the server configuration, I'm attaching a screenshot of the server
> configuration on my local JIRA server at home. The JIRA version here at home is
> 3.10 and my local JIRA at work and the company's JIRA version is 3.9, but from
> my usual use of JIRA i haven't noticed any changes that could mean something to
> our problem.

Can you please export your configuration using the "export" link on that admin screen?
Comment 9 Bruno Luiz Pereira da Silva CLA 2007-08-18 13:50:21 EDT
Created attachment 76372 [details]
Jira backup
Comment 10 Bruno Luiz Pereira da Silva CLA 2007-08-18 13:52:41 EDT
Eugene, i just attached a file containing the export from JIRA. I don't know if this export is exactly the one you wanted, because the generated XML contains data besides just configurations.

It was the only export link i found here, so if this file I attached does not contain what you need, please tell me how to get exactly what you want.

Regards,

Bruno
Comment 11 Eugene Kuleshov CLA 2007-08-18 17:04:12 EDT
Export with data is great, thanks. That should be enough for reproducing, though I will need a user and password for logging in. Can you email it to me? If you can't, then I will need to do some hacking to reset those passwords.
Comment 12 Eugene Kuleshov CLA 2007-08-18 21:06:28 EDT
I can't reproduce this with your data. I've tried on windows and linux. Though I only have java 5 on Linux instance and don't have WTP installed there. Also, my local encoding is not Portuguese either, but I see that your local OS/Java encoding is UTF-8, so it shouldn't be relevant.

Anyways, in both cases regardless from what encoding I am using, both ISO-8859-1 and UTF-8 on connector settings are working ok, so I can get query results just fine.

Can you set server encoding, then bring Eclipse down and then delete all files from <workspace>\.mylyn\offline\<your jira host>\* and <workspace>\.metadata\.plugins\org.eclipse.mylyn.jira.core\serverCache\repositoryConfigurations, then update server attributes (from the popup menu in Tasks Repositories view) and synchronize query again?

Also, I see you have MyEclipse installed. I am not sure if it has any impact or not, but it may worth to try without it using separate Eclipse instance.
Comment 13 Bruno Luiz Pereira da Silva CLA 2007-08-20 09:15:10 EDT
Eugene, as i said, my Eclipse installations at home and here are a bit different. While both installations are using Eclipse Europa, at home i'm using MyEclipse 6.0 over it and here i'm using the WTP 2.0 bundle.

I didn't have any different results between the 2 setups, so i guess it didn't make a difference.

I'll try doing the test you suggested later, changing the server encoding and then deleting the files from the workspace, and then i'll post here the results.

I might take a bit longer than Friday to answer, but i'll try to respond as quickly as i can.
Comment 14 Bruno Luiz Pereira da Silva CLA 2007-08-20 09:37:34 EDT
   Eugene, I've done the tests you suggested, changing the server encoding and the deleting the files from workspace, but i still get the same error. I'll talk to the JIRA admin here later, to see if it's possible to change our server encoding to UTF-8, because that would resolve my problem.

   The ISO-8859-1 + Portuguese seems to be a difficult setup to work with through the JIRA Connector, as i have done a huge set of tests and still haven't found a way to get around this issue. I'll do some other tests later, and then I'll comment here the results.

   Regards,

   Bruno
Comment 15 Steffen Pingel CLA 2007-09-18 13:43:40 EDT
Bruno, could you please try the latest dev build is available from the update site:

 http://www.eclipse.org/mylyn/downloads/builds.php
 
It contains a fix for non-UTF-8 character encodings. Please reopen this report if the problem persists.


*** This bug has been marked as a duplicate of bug 200904 ***
Comment 16 Steffen Pingel CLA 2007-09-18 14:41:56 EDT
Character encoding has been fixed for editing issues but not for the RSS feed. Reopening to investigate.
Comment 17 Steffen Pingel CLA 2007-09-18 15:09:28 EDT
The XML parser attempts to auto-detect the character encoding. Bruno, I assume in your case it was detected as UTF-8 while the actual encoding on the server is ISO-8859-1. I have committed a small fix that explicitly sets the character encoding for the XML parser.

Mik, could you please provide another dev build?
Comment 18 Mik Kersten CLA 2007-09-18 21:05:00 EDT
Another dev build will be available late tonight.
Comment 19 Mik Kersten CLA 2007-09-20 13:05:25 EDT
Steffen: so is this resolved as far as you know?  If so consider closing.

Bruno: the latest build (2.1.0.v20070920-1000) is uploading now and should be available within the hour.  It would be great if you could verify.
Comment 20 Bruno Luiz Pereira da Silva CLA 2007-09-20 16:17:43 EDT
Mik, I'm very very happy to tell you that i worked! Now my queries on the JIRA repository work just fine, and we'll be able to return using it again.

To all Mylyn developers, huge thanks for all the help and effort to solve this problem!
Comment 21 Steffen Pingel CLA 2007-09-20 16:26:48 EDT
Bruno, thanks for all the testing! Please file bug reports when you discover more problems related to character encoding (or any other bug of course). We have not been able to reproduce all cases on the test server and have only limited test coverage for that.
Comment 22 Danilo Esk CLA 2007-09-20 16:43:06 EDT
Had exactly the same problem (ISO-8859-1 + Portuguese).

I have not tried the latest build yet, but here we just solved that issue by
changing the server encoding to UTF-8.

That did not cause any problems: all portuguese special characters kept their
values. The only difference between the ISO and UTF Jira configuration (in
administration management) is the encoding used by the pages.

But thanks for the fix anyway.