Closed danielballan closed 9 years ago
attn @cowanml This should fix the problem with the default database being created.
I've confirmed this eliminates the 'test' db polution. thanks!
on a vaguely related note... I'd have a slightly warmer+fuzzy feeling if utils/testing.py had db_name = 'mds_disposable_test_db__{0}'.format(str(uuid.uuid1()))
or something instead of just the very generic, bare uuid4: db_name = str(uuid.uuid4())
From the docs, uuid4 is purely random, no time/host involved like for uuid1. The odds of inadvertently blowing away a db someone cares about before the heat death of the universe might by pretty slim in theory, but... I can all too easily imagine something screwy happening with random # seeding or something... makes my gut grumble slightly. Or maybe it's it's just dinner time? :)
-matt
It probably is just dinner time, but I am susceptible to such concerns. I also ended up with a large number of uuid named dbs on multiple machines from debugging testing/killing tests part of the way through so having a common prefix seems like a good idea to me.
On Wed, Apr 29, 2015 at 5:43 PM cowanml notifications@github.com wrote:
I've confirmed this eliminates the 'test' db polution. thanks!
on a vaguely related note... I'd have a slightly warmer+fuzzy feeling if utils/testing.py had db_name = 'mds_disposable_test_db__{0}'.format(str(uuid.uuid1()))
or something instead of just the very generic, bare uuid4: db_name = str(uuid.uuid4())
From the docs, uuid4 is purely random, no time/host involved like for uuid1. The odds of inadvertently blowing away a db someone cares about before the heat death of the universe might by pretty slim in theory, but... I can all too easily imagine something screwy happening with random # seeding or something... makes my gut grumble slightly. Or maybe it's it's just dinner time? :)
-matt
— Reply to this email directly or view it on GitHub https://github.com/NSLS-II/metadatastore/pull/135#issuecomment-97595795.
I do not understand why this was causing bleeding...