Claims don't work with mysql

Bug #1288820 reported by Flavio Percoco on 2014-03-06
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
zaqar
Critical
Flavio Percoco

Bug Description

When using mysql, claims doesn't seem to work. It can be verified by running the claims example in marconi client. It works perfectly when using sqlite but not with mysql

Changed in marconi:
importance: Undecided → Critical
assignee: nobody → Flavio Percoco (flaper87)
milestone: none → icehouse-rc1

Fix proposed to branch: master
Review: https://review.openstack.org/78672

Changed in marconi:
status: New → In Progress

Fix proposed to branch: master
Review: https://review.openstack.org/78673

Reviewed: https://review.openstack.org/78672
Committed: https://git.openstack.org/cgit/openstack/marconi/commit/?id=477bc46bfe1d7e1c056a4bb4aaa72d452315c160
Submitter: Jenkins
Branch: master

commit 477bc46bfe1d7e1c056a4bb4aaa72d452315c160
Author: Flavio Percoco <email address hidden>
Date: Thu Mar 6 18:08:22 2014 +0100

    Set time_zone to UTC on MySQL

    MySQL uses UTC for all date fields but other operations like `now()` use
    the timezone of the server. This patch changes the timezone of the
    connection to UTC when the connection is first established.

    There's space for improvement here. For instance, we could try to avoid
    doing this for every new connection and let the operator configure it on
    the server side. We could also use `CONVERT_TZ` on every query using
    `now()`.

    Change-Id: I2e8415dbb9a6ce19d3a66f3226756094b3e0f6a4
    Partial-bug: #1288820

Changed in marconi:
status: In Progress → Fix Committed

Reviewed: https://review.openstack.org/78673
Committed: https://git.openstack.org/cgit/openstack/marconi/commit/?id=364945f9902302e23cb6164377f5a310a82a2839
Submitter: Jenkins
Branch: master

commit 364945f9902302e23cb6164377f5a310a82a2839
Author: Flavio Percoco <email address hidden>
Date: Thu Mar 6 18:10:54 2014 +0100

    Reuse the transaction before getting messages

    The message get helper for claims used its own connection and ran
    outside the transaction where the 'claiming' happened. This caused the
    get to fail at retrieving the messages because the query was being
    executed 'before' the transaction.

    This patch fixes the aforementioned issue and also ensures that records
    ids are 'int' before calling `message_encode`.

    Change-Id: I076ffc171adf02fdb15160b6c7b29646ee3fb280
    Closes-bug: #1288820

Thierry Carrez (ttx) on 2014-04-16
Changed in marconi:
status: Fix Committed → Fix Released
Thierry Carrez (ttx) on 2014-04-17
Changed in marconi:
milestone: icehouse-rc1 → 2014.1
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers