【发布时间】:2015-04-02 21:04:43
【问题描述】:
我正在使用 Play framework 2.3 我有一个外部 Play 插件,它使用 spring 与使用 Spring-Ldap 的 LDAP 服务器通信。
目前我将配置文件放在 /conf 文件夹中,名为 ldap.properties。
在开发者模式下这很好用。 Spring 像这样加载它自己的上下文 ->
<context-source
url="${ldap.bind.url}"
base="${ldap.bind.base}"
username="${ldap.bind.username}"
password="${ldap.bind.password}" />
<bean id="placeholderConfig" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>classpath:ldap.properties</value>
</list>
</property>
<property name="ignoreUnresolvablePlaceholders" value="true"/>
</bean>
如您所知,我正在使用类路径中的 ldap.properties。
当我创建一个播放分发时,ldap.properties 文件被复制到主项目的 jar 文件中。
我需要将哪些参数传递给 Play 以忽略 JAR 中的 ldap.properties 文件并使用给定位置的实时服务器使用的参数?
【问题讨论】:
标签: playframework-2.0 playframework-2.3