Re: Problem with UUID

2011-04-09 Thread Олександр Силка
Thanks a lot Ed. I understand where was my problem. I thought that compareWith applied for a rows not for columns. 9 квітня 2011 р. 01:46 Ed Anuff написав: > I think the problem is this then: > > mutator.addInsertion(timeUUID, columnFamilyName, column); > > I'm not sure what you're doin

Re: Problem with UUID

2011-04-08 Thread Олександр Силка
Is that mean with this configuration i must use for column value only UUID ? I realy don't understand how it work. I little change my code: UUID timeUUID = DaoHelper.getTimeUUID(); HColumn column = HFactory.createColumn("name", "Alex", StringSerializer.get(), StringSerializer.get()); Mutator mut

Re: Problem with UUID

2011-04-08 Thread Ed Anuff
I think the problem is this then: mutator.addInsertion(timeUUID, columnFamilyName, column); I'm not sure what you're doing here, but you're using your timeUUID as the row key, not the column name. I don't see you actually assigning the column name so I don't know what you're putting in

Re: Problem with UUID

2011-04-08 Thread Олександр Силка
I try to use method getUniqueTimeUUIDinMillis from https://github.com/rantav/hector/blob/master/core/src/main/java/me/prettyprint/cassandra/utils/TimeUUIDUtils.java but i still get same result "InvalidRequestException(why:TimeUUID should be 16 or 0 bytes (3))"; 9 квітня 2011 р. 01:32 Олександр Сил

Re: Problem with UUID

2011-04-08 Thread Олександр Силка
Thanks that you try to help me, but i still get error message InvalidRequestException(why:TimeUUID should be 16 or 0 bytes (3)) This code UUID timeUUID = getTimeUUID(); doesn't solve my problem. 9 квітня 2011 р. 01:16 Ed Anuff написав: > Oops, I should have been more clear. You have this code:

Re: Problem with UUID

2011-04-08 Thread Ed Anuff
Oops, I should have been more clear. You have this code: UUID timeUUID = getTimeUUID().randomUUID(); what you need is this code: UUID timeUUID = getTimeUUID(); What I meant by not understanding the error message was that I thought the TimeUUIDType gave a different error message than the one yo

Re: Problem with UUID

2011-04-08 Thread Patrick Julien
I think this is what you're looking for http://wiki.apache.org/cassandra/FAQ#working_with_timeuuid_in_java 2011/4/8 Олександр Силка : > > Then how i can generate correct time UUID key in java ? > > 8 квітня 2011 р. 22:58 Ed Anuff написав: >> >> Hmm, if you're really doing this, you're not gettin

Re: Problem with UUID

2011-04-08 Thread Олександр Силка
Then how i can generate correct time UUID key in java ? 8 квітня 2011 р. 22:58 Ed Anuff написав: > Hmm, if you're really doing this, you're not getting a time uuid: > > UUID timeUUID = getTimeUUID().randomUUID(); > > That call to randomUUID() is invoking the static randomUUID() method > in java

Re: Problem with UUID

2011-04-08 Thread Ed Anuff
Hmm, if you're really doing this, you're not getting a time uuid: UUID timeUUID = getTimeUUID().randomUUID(); That call to randomUUID() is invoking the static randomUUID() method in java.util.UUID which is generating a non-time random uuid. I'm not sure why you're getting that error message tho