Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@
# EHCache configuration for clustered mode
# @param use_jndi_ds
# If true, the database will be configured as JNDI datasource in server.xml and then referenced in dbconfig.xml
# @param use_ucp
# If true, the database will be configured with oracles ucp connection driver
# @param jndi_ds_name
# Configures the JNDI datasource name
# @param db
Expand Down Expand Up @@ -310,6 +312,7 @@
Optional[Stdlib::Port] $ehcache_object_port = undef,
# Database Settings
Boolean $use_jndi_ds = false,
Boolean $use_ucp = false,
String[1] $jndi_ds_name = 'JiraDS',
Enum['postgresql','mysql','sqlserver','oracle','h2'] $db = 'postgresql',
String $dbuser = 'jiraadm',
Expand Down Expand Up @@ -517,7 +520,7 @@
true => { password => $plugin_data['password'] }
}
$_plugin_archive = {
$target => $_target_defaults + $_username + $_password
$target => $_target_defaults + $_username + $_password,
}
create_resources(archive, $_plugin_archive)
}
Expand Down
13 changes: 13 additions & 0 deletions templates/server.xml.epp
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,18 @@
factory="org.objectweb.jotm.UserTransactionFactory" jotm.timeout="60"/>
<% if $jira::use_jndi_ds { %>
<!-- If you're using JIRA 6.4 or below; change maxTotal to maxActive -->
<% if $jira::use_ucp { -%>
<Resource name="jdbc/<%= $jira::jndi_ds_name %>" auth="Container" type="oracle.ucp.jdbc.PoolDataSource"
factory="oracle.ucp.jdbc.PoolDataSourceImpl"
connectionFactoryClassName="oracle.jdbc.pool.OracleDataSource"
url="<%= $jira::config::dburl %>"
user="<%= $jira::dbuser %>"
password="<%= $jira::dbpassword %>"
maxTotal="<%= $jira::config::pool_max_size %>"
maxIdle="<%= $jira::config::pool_max_idle %>"
validationQuery="select 1"
/>
<% } else { -%>
<Resource name="jdbc/<%= $jira::jndi_ds_name %>" auth="Container" type="javax.sql.DataSource"
driverClassName="<%= $jira::config::dbdriver %>"
url="<%= $jira::config::dburl %>"
Expand All @@ -126,6 +138,7 @@
maxIdle="<%= $jira::config::pool_max_idle %>"
validationQuery="select 1"
/>
<% } -%>
<% } -%>
<Manager pathname=""/>
<JarScanner scanManifest="false"/>
Expand Down