{"action":"created","issue":{"url":"https://api.github.com/repos/rackerlabs/craton/issues/43","repository_url":"https://api.github.com/repos/rackerlabs/craton","labels_url":"https://api.github.com/repos/rackerlabs/craton/issues/43/labels{/name}","comments_url":"https://api.github.com/repos/rackerlabs/craton/issues/43/comments","events_url":"https://api.github.com/repos/rackerlabs/craton/issues/43/events","html_url":"https://github.com/rackerlabs/craton/issues/43","id":153012495,"number":43,"title":"Models: UUID field should be string (36) since we are not using it as primarykey","user":{"login":"sulochan","id":683492,"avatar_url":"https://avatars.githubusercontent.com/u/683492?v=3","gravatar_id":"","url":"https://api.github.com/users/sulochan","html_url":"https://github.com/sulochan","followers_url":"https://api.github.com/users/sulochan/followers","following_url":"https://api.github.com/users/sulochan/following{/other_user}","gists_url":"https://api.github.com/users/sulochan/gists{/gist_id}","starred_url":"https://api.github.com/users/sulochan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sulochan/subscriptions","organizations_url":"https://api.github.com/users/sulochan/orgs","repos_url":"https://api.github.com/users/sulochan/repos","events_url":"https://api.github.com/users/sulochan/events{/privacy}","received_events_url":"https://api.github.com/users/sulochan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-05-04T13:30:30Z","updated_at":"2016-05-06T18:36:11Z","closed_at":null,"body":"So UUID filed currently is types.BINARY(16) which is the default for sqlalchemy, but we are not using UUID for primary anymore and should just save uuid's as string(36) rather ? sqlalchemy utils can also do char(32) but I think the preferred way should be to store with dash as string(36) ?\r\n\r\nJust opening this issue to see what others think about this ? I have mostly seen openstack projects go with string(36) but maybe some do use char(32) or binary ?"},"comment":{"url":"https://api.github.com/repos/rackerlabs/craton/issues/comments/217524311","html_url":"https://github.com/rackerlabs/craton/issues/43#issuecomment-217524311","issue_url":"https://api.github.com/repos/rackerlabs/craton/issues/43","id":217524311,"user":{"login":"jimbaker","id":160446,"avatar_url":"https://avatars.githubusercontent.com/u/160446?v=3","gravatar_id":"","url":"https://api.github.com/users/jimbaker","html_url":"https://github.com/jimbaker","followers_url":"https://api.github.com/users/jimbaker/followers","following_url":"https://api.github.com/users/jimbaker/following{/other_user}","gists_url":"https://api.github.com/users/jimbaker/gists{/gist_id}","starred_url":"https://api.github.com/users/jimbaker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jimbaker/subscriptions","organizations_url":"https://api.github.com/users/jimbaker/orgs","repos_url":"https://api.github.com/users/jimbaker/repos","events_url":"https://api.github.com/users/jimbaker/events{/privacy}","received_events_url":"https://api.github.com/users/jimbaker/received_events","type":"User","site_admin":false},"created_at":"2016-05-06T18:36:11Z","updated_at":"2016-05-06T18:36:11Z","body":"We are using SQLAlchemy-Utils and its collection of custom types. In particular, [UUIDType](https://sqlalchemy-utils.readthedocs.io/en/latest/data_types.html#module-sqlalchemy_utils.types.uuid ) works as follows:\n\n> Stores a UUID in the database natively when it can and falls back to a BINARY(16) or a CHAR(32) when it can’t."}}