Bugzilla – Attachment 28968 Details for
Bug 11891
Make Koha::Schema use C4::Context->dbh
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11891: (follow-up) remove custom storage class
Bug-11891-follow-up-remove-custom-storage-class.patch (text/plain), 2.17 KB, created by
Chris Cormack
on 2014-06-18 23:29:18 UTC
(
hide
)
Description:
Bug 11891: (follow-up) remove custom storage class
Filename:
MIME Type:
Creator:
Chris Cormack
Created:
2014-06-18 23:29:18 UTC
Size:
2.17 KB
patch
obsolete
>From efcd073ac150b38cd820eadbf9e8fb02385af5ca Mon Sep 17 00:00:00 2001 >From: Galen Charlton <gmc@esilibrary.com> >Date: Wed, 18 Jun 2014 22:25:22 +0000 >Subject: [PATCH] Bug 11891: (follow-up) remove custom storage class > >For now, just rely on the normal DBIx::Class cleanup handler; >otherwise, the following warning is displayed in logs: > > (in cleanup) Can't locate object method "_preserve_foreign_dbh" via package "Koha::Storage" at .../Koha/Storage.pm > >Using the default DBIC storage class also means that we >don't have to manually do things like set the SQL limit dialect; >meaning that we don't get the following warning message: > > DBIx::Class::ResultSet::find(): Your storage class (Koha::Storage) does > not set sql_limit_dialect and you have not supplied an explicit > limit_dialect in your connection_info. DBIC will attempt to use the > GenericSubQ dialect, which works on most databases but can be (and > often is) painfully slow. Please file an RT ticket against > 'Koha::Storage' . at /home/gmc/koha/C4/Members.pm line 840 > >Test plan: same as main patch > >Signed-off-by: Galen Charlton <gmc@esilibrary.com> >Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> >--- > Koha/Schema.pm | 2 +- > Koha/Storage.pm | 16 ---------------- > 2 files changed, 1 insertion(+), 17 deletions(-) > delete mode 100644 Koha/Storage.pm > >diff --git a/Koha/Schema.pm b/Koha/Schema.pm >index 111855c..cffc631 100644 >--- a/Koha/Schema.pm >+++ b/Koha/Schema.pm >@@ -15,6 +15,6 @@ __PACKAGE__->load_namespaces; > # Created by DBIx::Class::Schema::Loader v0.07025 @ 2013-10-14 20:56:21 > # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:oDUxXckmfk6H9YCjW8PZTw > >-__PACKAGE__->storage_type('Koha::Storage'); > >+# You can replace this text with custom content, and it will be preserved on regeneration > 1; >diff --git a/Koha/Storage.pm b/Koha/Storage.pm >deleted file mode 100644 >index 599b6a1..0000000 >--- a/Koha/Storage.pm >+++ /dev/null >@@ -1,16 +0,0 @@ >-use utf8; >-package Koha::Storage; >- >-use strict; >-use warnings; >- >-use base 'DBIx::Class::Storage::DBI'; >-sub DESTROY { >- my $self = shift; >- >- # destroy just the object if not native to this process/thread >- $self->_preserve_foreign_dbh; >- >- $self->_dbh(undef); >-} >-1; >-- >2.0.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 11891
:
25828
|
25829
|
28962
|
28963
|
28964
|
28965
|
28966
|
28967
| 28968 |
28969