1 package DBIx::Class::DeploymentHandler::VersionStorage::Deprecated::VersionResultSet;
3 # ABSTRACT: (DEPRECATED) Predefined searches to find what you want from the version storage
8 use parent 'DBIx::Class::ResultSet';
11 use Time::HiRes 'gettimeofday';
13 sub version_storage_is_installed {
15 try { $self->next; 1 } catch { undef }
18 sub database_version {
20 $self->search(undef, {
21 order_by => { -desc => 'installed' },
23 })->get_column('version')->next;
26 # this is why it's deprecated guys... Serially.
31 my @tm = gettimeofday();
32 my @dt = gmtime ($tm[0]);
36 installed => sprintf("v%04d%02d%02d_%02d%02d%02d.%03.0f",
43 $tm[1] / 1000, # convert to millisecs, format as up/down rounded int above
50 # vim: ts=2 sw=2 expandtab
56 This component has been suplanted by
57 L<DBIx::Class::DeploymentHandler::VersionStorage::Standard::VersionResultSet>.
58 In the next major version (1) we will begin issuing a warning on it's use.
59 In the major version after that (2) we will remove it entirely.
61 =method version_storage_is_installed
63 True if (!!!) the version storage has been installed
65 =method database_version
67 The version of the database
71 Overridden to default C<installed> to the current time. (take a look, it's yucky)