http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13758

            Bug ID: 13758
           Summary: KOHAVERSION should be statically set
 Change sponsored?: ---
           Product: Koha
           Version: master
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P5 - low
         Component: Architecture, internals, and plumbing
          Assignee: [email protected]
          Reporter: [email protected]
        QA Contact: [email protected]

Currently, C4::Context::KOHAVERSION calculates the version number by running
kohaversion.pl on a new Perl interpreter:

sub KOHAVERSION {
    my $cgidir = C4::Context->intranetdir;

    # Apparently the GIT code does not run out of a CGI-BIN subdirectory
    # but distribution code does?  (Stan, 1jan08)
    if(-d $cgidir . "/cgi-bin"){
        my $cgidir .= "/cgi-bin";
    }

    do $cgidir."/kohaversion.pl" || die "NO $cgidir/kohaversion.pl";
    return kohaversion();
}

There's no point on doing this, as it is a hardcoded value we write on each DB
update.

It adds several milliseconds of latency to each request as the version
comparisson is done on each request to detect needed DB updates.

It should be statically set as $VERSION is (hmpf) on C4::Context, and if for
some reason we want to keep kohaversion.pl we should definitely read
C4::Context::VERSION (or KOHAVERSION if we rename it).

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to