Fork me on GitHub
#datomic
<
2015-06-22
>
alwaysbcoding03:06:13

If you have an attribute that is of type 'uuid' do you still need to declare that it is unique identity to use it as a lookup ref or is that done automatically because it's of type uuid?

robert-stuttaford07:06:09

you have to declare uniqueness yourself, @alwaysbcoding

bkamphaus13:06:09

@bhagany - that’s correct, overzealous documentation of db descriptors specifically. Wasn’t meant to limit args to dbs but of course the ‘Vector of maps’ language was incorrect and did just that. Fix to REST docs has now been made.

curtosis13:06:51

is there a library … or best practice … or recommended example 😉 for managing schemas? Something akin to rails db:create and db:migrate (but without necessarily implying that it be otherwise similar to rails).

stuartsierra14:06:17

@curtosis: Look for "Conformity" by Ryan Neufeld for one example.

stuartsierra14:06:20

Remember that schema is immutable like everything else in Datomic. You can always add new attributes, but it's very rare to replace or change them (once you have data in production).

tcrayford14:06:30

+1 on conformity. Yeller's been using it in prod for a year and then some, been very happy with it.

curtosis14:06:52

thanks! conformity seems pretty close to what I was looking for. (I also happen to think immutable schema is a pretty good thing.)

tcrayford14:06:16

the datomic way if you really want to mutate schema is to do it via backup/restore, but that's a whole bunch of work (intentionally so, I think)

curtosis14:06:33

yeah… changing attributes gets you into some bad places wrt temporal consistency.

bhagany14:06:28

@bkamphaus - great, thanks!