多个正则支持逗号分隔
This commit is contained in:
@@ -342,8 +342,8 @@ serviceid1_name1 serviceid1_name2 serviceid2_name1 serviceid2_name2
|
|||||||
path: servlet的ContextPath前缀 默认为空
|
path: servlet的ContextPath前缀 默认为空
|
||||||
autoload="true" 默认值. 自动加载classpath下所有的Servlet类
|
autoload="true" 默认值. 自动加载classpath下所有的Servlet类
|
||||||
autoload="false" 需要显著的指定Service类
|
autoload="false" 需要显著的指定Service类
|
||||||
includes: 当autoload="true", 拉取类名与includes中的正则表达式匹配的类, 多个正则表达式用分号;隔开
|
includes: 当autoload="true", 拉取类名与includes中的正则表达式匹配的类, 多个正则表达式用分号;或者逗号,隔开
|
||||||
excludes: 当autoload="true", 排除类名与excludes中的正则表达式匹配的类, 多个正则表达式用分号;隔开
|
excludes: 当autoload="true", 排除类名与excludes中的正则表达式匹配的类, 多个正则表达式用分号;或者逗号,隔开
|
||||||
-->
|
-->
|
||||||
<servlets path="/pipes" autoload="true" includes="" excludes="">
|
<servlets path="/pipes" autoload="true" includes="" excludes="">
|
||||||
<!--
|
<!--
|
||||||
|
|||||||
@@ -108,8 +108,10 @@ public final class ClassFilter<T> {
|
|||||||
Set<String> includeValues,
|
Set<String> includeValues,
|
||||||
Set<String> excludeValues) {
|
Set<String> excludeValues) {
|
||||||
ClassFilter filter = new ClassFilter(classLoader, null, null, excludeSuperClasses);
|
ClassFilter filter = new ClassFilter(classLoader, null, null, excludeSuperClasses);
|
||||||
filter.setIncludePatterns(includeRegxs == null ? null : includeRegxs.split(";"));
|
filter.setIncludePatterns(
|
||||||
filter.setExcludePatterns(excludeRegxs == null ? null : excludeRegxs.split(";"));
|
includeRegxs == null ? null : includeRegxs.replace(',', ';').split(";"));
|
||||||
|
filter.setExcludePatterns(
|
||||||
|
excludeRegxs == null ? null : excludeRegxs.replace(',', ';').split(";"));
|
||||||
filter.setPrivilegeIncludes(includeValues);
|
filter.setPrivilegeIncludes(includeValues);
|
||||||
filter.setPrivilegeExcludes(excludeValues);
|
filter.setPrivilegeExcludes(excludeValues);
|
||||||
return filter;
|
return filter;
|
||||||
|
|||||||
@@ -628,8 +628,8 @@ public abstract class NodeServer {
|
|||||||
if (list.getBoolValue("autoload", true)) {
|
if (list.getBoolValue("autoload", true)) {
|
||||||
String includes = list.getValue("includes", "");
|
String includes = list.getValue("includes", "");
|
||||||
String excludes = list.getValue("excludes", "");
|
String excludes = list.getValue("excludes", "");
|
||||||
filter.setIncludePatterns(includes.split(";"));
|
filter.setIncludePatterns(includes.replace(',', ';').split(";"));
|
||||||
filter.setExcludePatterns(excludes.split(";"));
|
filter.setExcludePatterns(excludes.replace(',', ';').split(";"));
|
||||||
} else if (ref2 == null || ref2 == Annotation.class) { // service如果是autoload=false则不需要加载
|
} else if (ref2 == null || ref2 == Annotation.class) { // service如果是autoload=false则不需要加载
|
||||||
filter.setRefused(true);
|
filter.setRefused(true);
|
||||||
} else if (ref2 != Annotation.class) {
|
} else if (ref2 != Annotation.class) {
|
||||||
|
|||||||
@@ -424,8 +424,8 @@ public class MessageModuleEngine extends ModuleEngine {
|
|||||||
if (consumerConf.getBoolValue("autoload", true)) {
|
if (consumerConf.getBoolValue("autoload", true)) {
|
||||||
String includes = consumerConf.getValue("includes", "");
|
String includes = consumerConf.getValue("includes", "");
|
||||||
String excludes = consumerConf.getValue("excludes", "");
|
String excludes = consumerConf.getValue("excludes", "");
|
||||||
filter.setIncludePatterns(includes.split(";"));
|
filter.setIncludePatterns(includes.replace(',', ';').split(";"));
|
||||||
filter.setExcludePatterns(excludes.split(";"));
|
filter.setExcludePatterns(excludes.replace(',', ';').split(";"));
|
||||||
} else {
|
} else {
|
||||||
filter.setRefused(true);
|
filter.setRefused(true);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user