[PATCH][TEST] Plugin DataSource drivers
Reported by tkykmw | February 2nd, 2010 @ 09:03 PM | in 1.3.0
ConnectionManager currently does not handle any plugin
prefixes
when the $config contains driver parameter.
This patch fixes the problem and allows you to load drivers from plugins, like:
class DATABASE_CONFIG {
var $plugin_driver = array('datasource' => 'dbo',
'driver' => 'PluginName.DboDriver');
var $plugin_datasource_and_driver = array('datasource' => 'PluginName.FooSource',
'driver' => 'PluginName.FooDriver');
}
And you can create your own drivers for the plugin datasources within your app/models/datasources/.
class DATABASE_CONFIG {
// app/models/datasources/foo/foo_bar.php
var $local_driver = array('datasource' => 'PluginName.FooSource',
'driver' => 'bar');
}
Comments and changes to this ticket
-

tkykmw February 2nd, 2010 @ 09:04 PM
- no changes were found...
-

tkykmw February 2nd, 2010 @ 09:08 PM
- → Tag changed from 1.3, datasource, plugin to 1.3, connectionmanager, datasource, plugin, plugins
-

Mark Story February 4th, 2010 @ 08:24 PM
- → Tag changed from 1.3, connectionmanager, datasource, plugin, plugins to connectionmanager, datasource, plugin, plugins
- → Milestone set to 1.3.0
-

Mark Story February 15th, 2010 @ 09:43 PM
- → Assigned user set to Mark Story
-

CakePHP February 16th, 2010 @ 09:42 PM
- → State changed from new to resolved
(from [2279b1a736ca772622aa63f809b54b5368805857]) Adding patches, and tests from tkykmw. Add support for plugin datasource drivers. Fixes #297 http://github.com/cakephp/cakephp1x/commit/2279b1a736ca772622aa63f8...
-

Mark Story February 28th, 2010 @ 12:28 AM
- → Tag changed from connectionmanager, datasource, plugin, plugins to connectionmanager, datasource, plugins
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
Source available from github
Repository is at http://github.com/cakephp/cakephp
Creating a bug report
When creating a bug report, please include as much relevant information as possible. Please include code to reproduce the issue. Or even better, make a unit test. Either change an existing test or add a new test to show that the expected behavior is not occuring.
People watching this ticket
Attachments
Referenced by
-
#297 [PATCH][TEST] Plugin DataSource drivers
(from [2279b1a736ca772622aa63f809b54b5368805857])
Adding ...