[keycloak-dev] Use UUID for IDs
Bill Burke
bburke at redhat.com
Tue Feb 11 09:03:58 EST 2014
IMO, should just reuse the static class we have now:
String IdGenerator.generateId();
and use UUID as the impl instead of creating a dependency on UUID
everywhere.
On 2/11/2014 9:01 AM, Bruno Oliveira wrote:
> Are you considering to use java.util.UUID behind the scenes for org.keycloak.UUID? Either way you could just stick to java.util.UUID, the probability of a collision is pretty low.
>
> --
> abstractj
>
> On February 7, 2014 at 1:41:37 PM, Stian Thorgersen (stian at redhat.com) wrote:
>>> I didn't mean use the UUID class as the id. I meant wrap the creation.
>> So instead of:
>>
>> new User(java.util.UUID.randomUUID().toString());
>>
>> we do:
>>
>> new User(org.keycloak.UUID.createUUID());
>
--
Bill Burke
JBoss, a division of Red Hat
http://bill.burkecentral.com
More information about the keycloak-dev
mailing list