[AB-190] migrating default config (featureMode, system config, post targets, feature flags) from tables to property files

not longer immediately instantiating the feature flag instance when a new server is found, but only when its config is changed or when a feature mod has its config changed
This commit is contained in:
Sheldan
2021-02-11 00:09:58 +01:00
parent ea12d67e5f
commit 047c574319
98 changed files with 654 additions and 1356 deletions

View File

@@ -0,0 +1,10 @@
package dev.sheldan.abstracto.assignableroles.config;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;
@Configuration
@PropertySource("classpath:assignableRoles-config.properties")
public class AssignableRolesConfig {
}

View File

@@ -0,0 +1,2 @@
abstracto.featureFlags.emoteTracking.featureName=emoteTracking
abstracto.featureFlags.emoteTracking.enabled=false

View File

@@ -9,5 +9,4 @@
<include file="feature.xml" relativeToChangelogFile="true"/>
<include file="module.xml" relativeToChangelogFile="true"/>
<include file="command.xml" relativeToChangelogFile="true"/>
<include file="default_feature_flag.xml" relativeToChangelogFile="true"/>
</databaseChangeLog>

View File

@@ -1,18 +0,0 @@
<?xml version="1.1" encoding="UTF-8" standalone="no"?>
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext"
xmlns:pro="http://www.liquibase.org/xml/ns/pro"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog ../../dbchangelog-3.8.xsd
http://www.liquibase.org/xml/ns/dbchangelog-ext ../../dbchangelog-3.8.xsd
http://www.liquibase.org/xml/ns/pro ../../dbchangelog-3.8.xsd" >
<property name="assignableFeature" value="(SELECT id FROM feature WHERE key = 'assignableRole')"/>
<property name="today" value="(SELECT NOW())"/>
<changeSet author="Sheldan" id="assignableRole_default_feature_flag-insertion">
<insert tableName="default_feature_flag">
<column name="enabled" value="false"/>
<column name="feature_id" valueComputed="${assignableFeature}" />
<column name="created" valueComputed="${today}"/>
</insert>
</changeSet>
</databaseChangeLog>