You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by "Henning Schmiedehausen (JIRA)" <ji...@apache.org> on 2005/09/18 21:45:55 UTC

[jira] Commented: (TRB-5) TorqueSecurityService relies on a datasource named "default"

    [ http://issues.apache.org/jira/browse/TRB-5?page=comments#action_12329699 ] 

Henning Schmiedehausen commented on TRB-5:
------------------------------------------

Could you please try to verify this one more time? The following configuration works for me:

--- cut --- torque.properties --- cut ---
torque.dsfactory.secdemo.connection.driver =            org.postgresql.Driver
torque.dsfactory.secdemo.connection.url =               jdbc:postgresql://localhost/secdemo
torque.dsfactory.secdemo.connection.user =              postgres
torque.dsfactory.secdemo.connection.password =

torque.database.default =               secdemo

torque.database.secdemo.adapter =       postgresql
torque.dsfactory.secdemo.factory =      org.apache.torque.dsfactory.SharedPoolDataSourceFactory

--- cut --- torque.properties --- cut ---

--- cut --- TurbineResources.properties --- cut ---
services.SecurityService.classname=org.apache.turbine.services.security.torque.TorqueSecurityService
services.SecurityService.user.manager = org.apache.turbine.services.security.torque.TorqueUserManager
services.SecurityService.user.class =       org.apache.turbine.services.security.torque.TorqueUser
services.SecurityService.group.class =      org.apache.turbine.services.security.torque.TorqueGroup
services.SecurityService.permission.class = org.apache.turbine.services.security.torque.TorquePermission
services.SecurityService.role.class =       org.apache.turbine.services.security.torque.TorqueRole
--- cut --- TurbineResources.properties --- cut ---

You can test this by getting the secdemo application from http://henning.schmiedehausen.org/eyewiki/attach/TurbineSecurityExampleUsingMETA/secdemo-1.0-src.tar.gz
and removing the following lines from conf/turbine-om.properties:

services.SecurityService.torque.userPeer.class       = org.apache.turbine.app.secdemo.om.TurbineUserPeer
services.SecurityService.torque.groupPeer.class      = org.apache.turbine.app.secdemo.om.TurbineGroupPeer
services.SecurityService.torque.permissionPeer.class = org.apache.turbine.app.secdemo.om.TurbinePermissionPeer
services.SecurityService.torque.rolePeer.class       = org.apache.turbine.app.secdemo.om.TurbineRolePeer

Doing so will let the Security Service fall back to the internal, om generated classes. If I remove the line

torque.database.default =               secdemo

from the torque.properties, then it no longer works. So it seems to do the mapping correctly.

> TorqueSecurityService relies on a datasource named "default"
> ------------------------------------------------------------
>
>          Key: TRB-5
>          URL: http://issues.apache.org/jira/browse/TRB-5
>      Project: Turbine
>         Type: Bug
>   Components: Turbine 2.3
>  Environment: Turbine-2.3.2-rc2.-dev
>     Reporter: Thomas Vandahl
>     Assignee: Henning Schmiedehausen

>
> The OM-classes generated during the build process of Turbine need a hard-coded data source called "default".
> The previous version simply used the configured default DataSource as in
> torque.database.default=turbine

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org