com.appsmith
reactiveCaching
diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/configurations/FeatureFlagConfig.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/configurations/FeatureFlagConfig.java
index e262917c2f..bf7f6083fa 100644
--- a/app/server/appsmith-server/src/main/java/com/appsmith/server/configurations/FeatureFlagConfig.java
+++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/configurations/FeatureFlagConfig.java
@@ -1,7 +1,7 @@
package com.appsmith.server.configurations;
import org.ff4j.FF4j;
-import org.ff4j.parser.yaml.YamlParser;
+import org.ff4j.conf.XmlParser;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@@ -10,7 +10,7 @@ public class FeatureFlagConfig {
@Bean
public FF4j ff4j() {
- return new FF4j(new YamlParser(), "features/init-flags.yml")
+ return new FF4j(new XmlParser(), "features/init-flags.xml")
.audit(true)
.autoCreate(true);
}
diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/featureflags/FeatureFlagEnum.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/featureflags/FeatureFlagEnum.java
index 072668274c..22464cc05d 100644
--- a/app/server/appsmith-server/src/main/java/com/appsmith/server/featureflags/FeatureFlagEnum.java
+++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/featureflags/FeatureFlagEnum.java
@@ -6,10 +6,10 @@ import org.ff4j.strategy.time.OfficeHourStrategy;
/**
* This enum lists all the feature flags available along with their flipping strategy.
- * In order to create a new feature flag, create another enum entry and add the same string to {@link features/init-flags.yml}
+ * In order to create a new feature flag, create another enum entry and add the same string to {@link features/init-flags.xml}
*
* If you wish to define a custom flipping strategy, define a class that implements {@link FlippingStrategy} and
- * ensure that you've mentioned this custom class when defining the feature in {@link features/init-flags.yml}
+ * ensure that you've mentioned this custom class when defining the feature in {@link features/init-flags.xml}
*
* The feature flag implementation class should extend an existing feature flag implementation like {@link PonderationStrategy},
* {@link OfficeHourStrategy} etc. These default classes provide a lot of basic functionality out of the box.
diff --git a/app/server/appsmith-server/src/main/resources/features/init-flags.xml b/app/server/appsmith-server/src/main/resources/features/init-flags.xml
new file mode 100644
index 0000000000..033928a766
--- /dev/null
+++ b/app/server/appsmith-server/src/main/resources/features/init-flags.xml
@@ -0,0 +1,36 @@
+
+
+ false
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/server/appsmith-server/src/main/resources/features/init-flags.yml b/app/server/appsmith-server/src/main/resources/features/init-flags.yml
deleted file mode 100644
index 22148aa015..0000000000
--- a/app/server/appsmith-server/src/main/resources/features/init-flags.yml
+++ /dev/null
@@ -1,56 +0,0 @@
-# Check sample file at: https://github.com/ff4j/ff4j-samples/blob/master/spring-boot-2x/ff4j-sample-springboot2x/src/main/resources/ff4j-init-dataset.yml
-
-# -----------------------------
-# Core FF4J
-# -----------------------------
-ff4j:
- autocreate: false
- audit: false
-
- features:
- - uid: DATASOURCE_ENVIRONMENTS
- enable: true
- description: Introducing multiple execution environments for datasources
- flipstrategy:
- class: com.appsmith.server.featureflags.strategies.EmailBasedRolloutStrategy
- param:
- - name: emails
- value: me-eng1@appsmith.com,me-eng2@appsmith.com,me-qa1@appsmith.com,me-qa2@appsmith.com,me-demo@appsmith.com
-
- - uid: MULTIPLE_PANES
- enable: true
- description: Have multiple panes in the Appsmith IDE
- flipstrategy:
- class: com.appsmith.server.featureflags.strategies.EmailBasedRolloutStrategy
- param:
- - name: emails
- value: multipanes@appsmith.com,ndx@appsmith.com
-
- - uid: AUTO_LAYOUT
- enable: true
- description: Enable auto layout editor for everyone
- flipstrategy:
- class: org.ff4j.strategy.PonderationStrategy
- param:
- - name: weight
- value: 1
-
- - uid: APP_NAVIGATION_LOGO_UPLOAD
- enable: true
- description: Logo upload feature for app viewer navigation
- flipstrategy:
- class: com.appsmith.server.featureflags.strategies.EmailBasedRolloutStrategy
- param:
- - name: emailDomains
- value: appsmith.com,moolya.com
-
- # Put EE flags below this line, to avoid conflicts.
-
- - uid: ONE_CLICK_BINDING
- enable: true
- description: Show property controls to generate queries for table widget with just clicks
- flipstrategy:
- class: com.appsmith.server.featureflags.strategies.EmailBasedRolloutStrategy
- param:
- - name: emails
- value: balaji@appsmith.com,vamsi@appsmith.com
diff --git a/app/server/appsmith-server/src/test/java/com/appsmith/server/services/FeatureFlagServiceTest.java b/app/server/appsmith-server/src/test/java/com/appsmith/server/services/FeatureFlagServiceTest.java
index 2a75659acf..3825a141b6 100644
--- a/app/server/appsmith-server/src/test/java/com/appsmith/server/services/FeatureFlagServiceTest.java
+++ b/app/server/appsmith-server/src/test/java/com/appsmith/server/services/FeatureFlagServiceTest.java
@@ -3,7 +3,7 @@ package com.appsmith.server.services;
import com.appsmith.server.featureflags.FeatureFlagEnum;
import lombok.extern.slf4j.Slf4j;
import org.ff4j.FF4j;
-import org.ff4j.parser.yaml.YamlParser;
+import org.ff4j.conf.XmlParser;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.springframework.beans.factory.annotation.Autowired;
@@ -86,7 +86,7 @@ public class FeatureFlagServiceTest {
@Bean
FF4j ff4j() {
- FF4j ff4j = new FF4j(new YamlParser(), "features/init-flags-test.yml")
+ FF4j ff4j = new FF4j(new XmlParser(), "features/init-flags-test.xml")
.audit(true)
.autoCreate(false);
return ff4j;
diff --git a/app/server/appsmith-server/src/test/resources/features/init-flags-test.xml b/app/server/appsmith-server/src/test/resources/features/init-flags-test.xml
new file mode 100644
index 0000000000..5273ee9d2b
--- /dev/null
+++ b/app/server/appsmith-server/src/test/resources/features/init-flags-test.xml
@@ -0,0 +1,24 @@
+
+
+ false
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/server/appsmith-server/src/test/resources/features/init-flags-test.yml b/app/server/appsmith-server/src/test/resources/features/init-flags-test.yml
deleted file mode 100644
index 944d2c6a85..0000000000
--- a/app/server/appsmith-server/src/test/resources/features/init-flags-test.yml
+++ /dev/null
@@ -1,37 +0,0 @@
-# Check sample file at: https://github.com/ff4j/ff4j-samples/blob/master/spring-boot-2x/ff4j-sample-springboot2x/src/main/resources/ff4j-init-dataset.yml
-
-# -----------------------------
-# Core FF4J configuration for testing. DO NOT USE THIS IN PRODUCTION
-# -----------------------------
-ff4j:
- autocreate: false
- audit: false
-
- features:
-
- - uid: TEST_FEATURE_1
- enable: true
- description: The test feature should only be visible to Appsmith users
- flipstrategy:
- class: com.appsmith.server.featureflags.strategies.AppsmithUserStrategy
- param:
- - name: requiredKey
- value: requiredValue
-
- - uid: TEST_FEATURE_2
- enable: true
- description: Enable this feature based on weight. It's randomized.
- flipstrategy:
- class: org.ff4j.strategy.PonderationStrategy
- param:
- - name: weight
- value: 1
-
- - uid: TEST_FEATURE_3
- enable: true
- description: The test feature should only be visible to certain users
- flipstrategy:
- class: com.appsmith.server.featureflags.strategies.EmailBasedRolloutStrategy
- param:
- - name: emailDomains
- value: test@example.com
\ No newline at end of file
diff --git a/app/server/pom.xml b/app/server/pom.xml
index e947ab879e..13cdbf0921 100644
--- a/app/server/pom.xml
+++ b/app/server/pom.xml
@@ -35,6 +35,8 @@
3.5.1
${java.version}
${java.version}
+
+ 2.0