Data conversion error in current master

88 views
Skip to first unread message

Dariusz Luksza

unread,
Dec 18, 2012, 4:45:22 AM12/18/12
to repo-discuss
With current master (v2.5.1-788-g09d2e60) I get strange 'Data
conversion error' messages. On my old test_site gerrit event won't
start because of:

Cannot parse "TIMESTAMP" constant "Y" [22007-168]

On complete new test_site gerrit boots up but I cannot create new
account because of:

Data conversion error converting "'N' (ACCOUNTS: MAXIMUM_PAGE_SIZE
SMALLINT DEFAULT 0 NOT NULL)"; SQL statement:
INSERT INTO accounts(contact_filed_on,copy_self_on_email,date_format,download_command,download_url,full_name,inactive,maximum_page_size,preferred_email,registered_on,reverse_patch_set_order,show_site_header,show_username_in_review_category,time_format,use_flash_clipboard,account_id)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
-- (?1, ?2, ?3, ?4, ?5, ?6, ?7, ?8, ?9, ?10, ?11, ?12, ?13, ?14, ?15,
?16) [22018-168]

Any ideas where the problem could be?

--
Best regards

GSM: +49 017 445 41235
Blog: http://luksza.org
LinkedIn: http://www.linkedin.com/in/dariuszluksza

Dariusz Luksza

unread,
Dec 18, 2012, 5:03:16 AM12/18/12
to Saša Živkov, repo-discuss
On Tue, Dec 18, 2012 at 10:59 AM, Saša Živkov <ziv...@gmail.com> wrote:
>> Data conversion error converting "'N' (ACCOUNTS: MAXIMUM_PAGE_SIZE
>> SMALLINT DEFAULT 0 NOT NULL)"; SQL statement:
>
> The "maximum_page_size" fiels is of type int.
> Looks like 'N' is being converted into an int and this is failing.

yes, but form where this 'N' comes from? and why it is tried to be
converted to int?

accounts(contact_filed_on,copy_self_on_email,date_format,download_command,download_url,full_name,inactive,maximum_page_size,preferred_email,registered_on,reverse_patch_set_order,show_site_header,show_username_in_review_category,time_format,use_flash_clipboard,account_id)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
>> -- (?1, ?2, ?3, ?4, ?5, ?6, ?7, ?8, ?9, ?10, ?11, ?12, ?13, ?14, ?15,
>> ?16) [22018-168]
>>
>> Any ideas where the problem could be?
>
> Do you find any stack traces in the error_log?

error_log is empty

Saša Živkov

unread,
Dec 18, 2012, 7:41:26 AM12/18/12
to Dariusz Luksza, repo-discuss
On Tue, Dec 18, 2012 at 11:03 AM, Dariusz Luksza <dariusz...@gmail.com> wrote:
On Tue, Dec 18, 2012 at 10:59 AM, Saša Živkov <ziv...@gmail.com> wrote:
>> Data conversion error converting "'N' (ACCOUNTS: MAXIMUM_PAGE_SIZE
>> SMALLINT DEFAULT 0 NOT NULL)"; SQL statement:
>
> The "maximum_page_size" fiels is of type int.
> Looks like 'N' is being converted into an int and this is failing.

yes, but form where this 'N' comes from? and why it is tried to be
converted to int?
 
This is why I asked for any traces in the error_log.
I just built the 9d2e60, created a new site and created a new user.
Everything worked fine. Used the H2 database and auth.type = DEVELOPMENT_BECOME_ANY_ACCOUNT

Which database and which auth.type did you use?

Dariusz Luksza

unread,
Dec 18, 2012, 8:04:18 AM12/18/12
to Saša Živkov, repo-discuss
On Tue, Dec 18, 2012 at 1:41 PM, Saša Živkov <ziv...@gmail.com> wrote:
> This is why I asked for any traces in the error_log.
> I just built the 9d2e60, created a new site and created a new user.
> Everything worked fine. Used the H2 database and auth.type =
> DEVELOPMENT_BECOME_ANY_ACCOUNT
>
> Which database and which auth.type did you use?

I'm using same conifguration with H2 and
DEVELOPMENT_BECOME_ANY_ACCOUNT. Will try run `mvn clean package` maybe
this will solve this problem.

Dariusz Luksza

unread,
Dec 18, 2012, 8:35:02 AM12/18/12
to Saša Živkov, repo-discuss
On Tue, Dec 18, 2012 at 2:04 PM, Dariusz Luksza
<dariusz...@gmail.com> wrote:
> On Tue, Dec 18, 2012 at 1:41 PM, Saša Živkov <ziv...@gmail.com> wrote:
>> This is why I asked for any traces in the error_log.
>> I just built the 9d2e60, created a new site and created a new user.
>> Everything worked fine. Used the H2 database and auth.type =
>> DEVELOPMENT_BECOME_ANY_ACCOUNT
>>
>> Which database and which auth.type did you use?
>
> I'm using same conifguration with H2 and
> DEVELOPMENT_BECOME_ANY_ACCOUNT. Will try run `mvn clean package` maybe
> this will solve this problem.

Seams that this issue was caused by OpenJDK 7 on my Debian box, when I
switch to IcedTea6 everything works fine yet again. I didn't change
jvm version inside eclipse manually so it seams like an openjdk7
update in Debian cause this problem.

Shawn Pearce

unread,
Dec 18, 2012, 1:13:27 PM12/18/12
to Dariusz Luksza, Saša Živkov, repo-discuss
On Tue, Dec 18, 2012 at 5:35 AM, Dariusz Luksza
<dariusz...@gmail.com> wrote:
> On Tue, Dec 18, 2012 at 2:04 PM, Dariusz Luksza
> <dariusz...@gmail.com> wrote:
>> On Tue, Dec 18, 2012 at 1:41 PM, Saša Živkov <ziv...@gmail.com> wrote:
>>> This is why I asked for any traces in the error_log.
>>> I just built the 9d2e60, created a new site and created a new user.
>>> Everything worked fine. Used the H2 database and auth.type =
>>> DEVELOPMENT_BECOME_ANY_ACCOUNT
>>>
>>> Which database and which auth.type did you use?
>>
>> I'm using same conifguration with H2 and
>> DEVELOPMENT_BECOME_ANY_ACCOUNT. Will try run `mvn clean package` maybe
>> this will solve this problem.
>
> Seams that this issue was caused by OpenJDK 7 on my Debian box, when I
> switch to IcedTea6 everything works fine yet again. I didn't change
> jvm version inside eclipse manually so it seams like an openjdk7
> update in Debian cause this problem.

This might be a bug in gwtorm with OpenJDK 7. I know that in JDK 7
reflection APIs are returning methods in a different order than
before, and maybe fields too. What may be happening here is some
randomization in iteration order of a HashMap is causing an assumption
gwtorm had about consistent ordering to fail. For example it iterates
through once to build the list of columns, and then iterates again to
build the list of data bindings. If they iterate in a different order,
*boom*, we try to treat "N" as a Timestamp or something and there goes
the world.

Edwin Kempin

unread,
Dec 28, 2012, 10:07:01 AM12/28/12
to Shawn Pearce, Dariusz Luksza, Saša Živkov, repo-discuss
When using current master of gwtorm I'm getting the same error on Gerrit startup after upgrading the schema or initializing a new site :-(
I'm on Windows and still using Java 1.6. With Java 1.7

$ java -version
java version "1.6.0_37"
Java(TM) SE Runtime Environment (build 1.6.0_37-b06)
Java HotSpot(TM) Client VM (build 20.12-b01, mixed mode, sharing)

2012/12/18 Shawn Pearce <s...@google.com>

Dave Borowitz

unread,
Jan 28, 2013, 6:22:17 PM1/28/13
to Edwin Kempin, Shawn Pearce, Dariusz Luksza, Saša Živkov, repo-discuss
I'm seeing this as well with both my OpenJDK 6 and 7 JVMs. Digging into gwtorm now (hopefully I'll get somewhere without gouging my eyes out first :)

Edwin Kempin

unread,
Jan 31, 2013, 3:00:51 AM1/31/13
to Dave Borowitz, Shawn Pearce, Dariusz Luksza, Saša Živkov, repo-discuss


2013/1/29 Dave Borowitz <dbor...@google.com>

I'm seeing this as well with both my OpenJDK 6 and 7 JVMs. Digging into gwtorm now (hopefully I'll get somewhere without gouging my eyes out first :)
Just for the record. Dave fixed this issue by:
  https://gerrit-review.googlesource.com/41734

 
Reply all
Reply to author
Forward
0 new messages