在jboss域配置中组织大量概要文件

在jboss域配置中组织大量概要文件,jboss,jboss-eap-6,Jboss,Jboss Eap 6,我有一个jboss域服务器,有10-20个配置文件 基本上,我有10-20个相同应用程序的实例在不同的端口上运行 配置文件上的设置90%相同,唯一的区别是数据源和日志记录配置 我正在为每个应用程序实例复制/粘贴一个配置文件,因此我的domain.xml很快变得越来越大,并且大多数设置都是重复的 如果我能做以下两件事中的一件,它将帮助我更容易地维护: 是否有一种方法可以重用概要文件并从服务器组传递参数,以便稍微更改一点配置 例如: <server-group name="instan

我有一个jboss域服务器,有10-20个配置文件

基本上,我有10-20个相同应用程序的实例在不同的端口上运行

配置文件上的设置90%相同,唯一的区别是数据源和日志记录配置

我正在为每个应用程序实例复制/粘贴一个配置文件,因此我的domain.xml很快变得越来越大,并且大多数设置都是重复的

如果我能做以下两件事中的一件,它将帮助我更容易地维护:

  • 是否有一种方法可以重用概要文件并从服务器组传递参数,以便稍微更改一点配置 例如:

        <server-group name="instance1-group" profile="common_template-ha">
              <!-- This are the bits and pieces that are different between instances  -->
              <datasource>
                   .... configuration
              </datasource>
              <logging>
                   .... configuration
              </logging>
        </server-group>
    
    <profiles>
        <!-- profiles would be imported from 3 other files -->
        <profile source="profile-instance1.xml />
        <profile source="profile-instance2.xml />
        <profile source="profile-instance3.xml />
    </profiles>
    
    
    .... 配置
    .... 配置
    
  • 我可以将domain.xml文件拆分为几个不同的小文件,每个文件都包含一个配置文件配置吗
  • 例如:

        <server-group name="instance1-group" profile="common_template-ha">
              <!-- This are the bits and pieces that are different between instances  -->
              <datasource>
                   .... configuration
              </datasource>
              <logging>
                   .... configuration
              </logging>
        </server-group>
    
    <profiles>
        <!-- profiles would be imported from 3 other files -->
        <profile source="profile-instance1.xml />
        <profile source="profile-instance2.xml />
        <profile source="profile-instance3.xml />
    </profiles>