You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2020/10/31 08:17:21 UTC

[camel] 03/04: CAMEL-15778: camel-main - Optimize and clear main configuration configurers after started

This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit a4f7d6f7124de1677056edb156633ea991e3b923
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Fri Oct 30 20:43:46 2020 +0100

    CAMEL-15778: camel-main - Optimize and clear main configuration configurers after started
---
 .../org/apache/camel/ExtendedCamelContext.java     |  14 +-
 .../camel/impl/engine/AbstractCamelContext.java    |  12 +-
 .../camel/impl/ExtendedCamelContextConfigurer.java |  10 +-
 .../services/org/apache/camel/model.properties     | 204 ---------------------
 .../camel/impl/lw/LightweightCamelContext.java     |  20 +-
 .../impl/lw/LightweightRuntimeCamelContext.java    |  20 +-
 .../MainConfigurationPropertiesConfigurer.java     |   5 -
 .../camel-main-configuration-metadata.json         |   1 -
 core/camel-main/src/main/docs/main.adoc            |   1 -
 .../camel/main/DefaultConfigurationConfigurer.java |   2 +-
 .../camel/main/DefaultConfigurationProperties.java |  25 ---
 .../src/main/java/org/apache/camel/main/Main.java  |  13 +-
 .../apache/camel/main/MainFaultToleranceTest.java  |  61 ------
 13 files changed, 45 insertions(+), 343 deletions(-)

diff --git a/core/camel-api/src/main/java/org/apache/camel/ExtendedCamelContext.java b/core/camel-api/src/main/java/org/apache/camel/ExtendedCamelContext.java
index 50cc2d9..e463e66 100644
--- a/core/camel-api/src/main/java/org/apache/camel/ExtendedCamelContext.java
+++ b/core/camel-api/src/main/java/org/apache/camel/ExtendedCamelContext.java
@@ -637,17 +637,15 @@ public interface ExtendedCamelContext extends CamelContext {
     Processor createErrorHandler(Route route, Processor processor) throws Exception;
 
     /**
-     * Whether reifiers should be cleared. If enabled this will trigger some optimizations and memory reduction, however
-     * dynamic routes cannot be added after Camel has been started.
+     * Whether to run in lightweight mode which triggers some optimizations and memory reduction. Danger this causes
+     * Camel to be less dynamic such as adding new route after Camel is started would not be possible.
      */
-    void setClearReifiers(boolean clearReifiers);
+    void setLightweight(boolean lightweight);
 
     /**
-     * Whether reifiers should be cleared. If enabled this will trigger some optimizations and memory reduction, however
-     * dynamic routes cannot be added after Camel has been started.
+     * Whether to run in lightweight mode which triggers some optimizations and memory reduction. Danger this causes
+     * Camel to be less dynamic such as adding new route after Camel is started would not be possible.
      */
-    boolean isClearReifiers();
-
-    // TODO: Come up with a better name
+    boolean isLightweight();
 
 }
diff --git a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java
index 597f463..505889e 100644
--- a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java
+++ b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java
@@ -243,7 +243,7 @@ public abstract class AbstractCamelContext extends BaseService
     private Boolean useBreadcrumb = Boolean.FALSE;
     private Boolean allowUseOriginalMessage = Boolean.FALSE;
     private Boolean caseInsensitiveHeaders = Boolean.TRUE;
-    private boolean clearReifiers;
+    private boolean lightweight;
     private Long delay;
     private ErrorHandlerFactory errorHandlerFactory;
     private Map<String, String> globalOptions = new HashMap<>();
@@ -2709,7 +2709,7 @@ public abstract class AbstractCamelContext extends BaseService
             // we can always clear the bootstrap configurers (such as camel-main) after we have started
             ConfigurerStrategy.clearBootstrapConfigurers();
 
-            if (isClearReifiers()) {
+            if (isLightweight()) {
                 LOG.info(
                         "Clearing Camel bootstrap services to free memory."
                          + " Danger this impacts the CamelContext not being able to add new routes or use reflection-free configuration, etc.");
@@ -3790,13 +3790,13 @@ public abstract class AbstractCamelContext extends BaseService
     }
 
     @Override
-    public boolean isClearReifiers() {
-        return clearReifiers;
+    public boolean isLightweight() {
+        return lightweight;
     }
 
     @Override
-    public void setClearReifiers(boolean clearReifiers) {
-        this.clearReifiers = clearReifiers;
+    public void setLightweight(boolean lightweight) {
+        this.lightweight = lightweight;
     }
 
     @Override
diff --git a/core/camel-core-engine/src/generated/java/org/apache/camel/impl/ExtendedCamelContextConfigurer.java b/core/camel-core-engine/src/generated/java/org/apache/camel/impl/ExtendedCamelContextConfigurer.java
index bfa37fa..596d0df 100644
--- a/core/camel-core-engine/src/generated/java/org/apache/camel/impl/ExtendedCamelContextConfigurer.java
+++ b/core/camel-core-engine/src/generated/java/org/apache/camel/impl/ExtendedCamelContextConfigurer.java
@@ -28,7 +28,6 @@ public class ExtendedCamelContextConfigurer extends org.apache.camel.support.com
         map.put("BeanIntrospection", org.apache.camel.spi.BeanIntrospection.class);
         map.put("CaseInsensitiveHeaders", java.lang.Boolean.class);
         map.put("ClassResolver", org.apache.camel.spi.ClassResolver.class);
-        map.put("ClearReifiers", boolean.class);
         map.put("ComponentNameResolver", org.apache.camel.spi.ComponentNameResolver.class);
         map.put("ComponentResolver", org.apache.camel.spi.ComponentResolver.class);
         map.put("ConfigurerResolver", org.apache.camel.spi.ConfigurerResolver.class);
@@ -48,6 +47,7 @@ public class ExtendedCamelContextConfigurer extends org.apache.camel.support.com
         map.put("InterceptEndpointFactory", org.apache.camel.spi.InterceptEndpointFactory.class);
         map.put("InternalProcessorFactory", org.apache.camel.spi.InternalProcessorFactory.class);
         map.put("LanguageResolver", org.apache.camel.spi.LanguageResolver.class);
+        map.put("Lightweight", boolean.class);
         map.put("LoadTypeConverters", java.lang.Boolean.class);
         map.put("LogExhaustedMessageBody", java.lang.Boolean.class);
         map.put("LogMask", java.lang.Boolean.class);
@@ -119,8 +119,6 @@ public class ExtendedCamelContextConfigurer extends org.apache.camel.support.com
         case "CaseInsensitiveHeaders": target.setCaseInsensitiveHeaders(property(camelContext, java.lang.Boolean.class, value)); return true;
         case "classresolver":
         case "ClassResolver": target.setClassResolver(property(camelContext, org.apache.camel.spi.ClassResolver.class, value)); return true;
-        case "clearreifiers":
-        case "ClearReifiers": target.setClearReifiers(property(camelContext, boolean.class, value)); return true;
         case "componentnameresolver":
         case "ComponentNameResolver": target.setComponentNameResolver(property(camelContext, org.apache.camel.spi.ComponentNameResolver.class, value)); return true;
         case "componentresolver":
@@ -159,6 +157,8 @@ public class ExtendedCamelContextConfigurer extends org.apache.camel.support.com
         case "InternalProcessorFactory": target.setInternalProcessorFactory(property(camelContext, org.apache.camel.spi.InternalProcessorFactory.class, value)); return true;
         case "languageresolver":
         case "LanguageResolver": target.setLanguageResolver(property(camelContext, org.apache.camel.spi.LanguageResolver.class, value)); return true;
+        case "lightweight":
+        case "Lightweight": target.setLightweight(property(camelContext, boolean.class, value)); return true;
         case "loadtypeconverters":
         case "LoadTypeConverters": target.setLoadTypeConverters(property(camelContext, java.lang.Boolean.class, value)); return true;
         case "logexhaustedmessagebody":
@@ -287,8 +287,6 @@ public class ExtendedCamelContextConfigurer extends org.apache.camel.support.com
         case "CaseInsensitiveHeaders": return target.isCaseInsensitiveHeaders();
         case "classresolver":
         case "ClassResolver": return target.getClassResolver();
-        case "clearreifiers":
-        case "ClearReifiers": return target.isClearReifiers();
         case "componentnameresolver":
         case "ComponentNameResolver": return target.getComponentNameResolver();
         case "componentresolver":
@@ -327,6 +325,8 @@ public class ExtendedCamelContextConfigurer extends org.apache.camel.support.com
         case "InternalProcessorFactory": return target.getInternalProcessorFactory();
         case "languageresolver":
         case "LanguageResolver": return target.getLanguageResolver();
+        case "lightweight":
+        case "Lightweight": return target.isLightweight();
         case "loadtypeconverters":
         case "LoadTypeConverters": return target.isLoadTypeConverters();
         case "logexhaustedmessagebody":
diff --git a/core/camel-core-engine/src/generated/resources/META-INF/services/org/apache/camel/model.properties b/core/camel-core-engine/src/generated/resources/META-INF/services/org/apache/camel/model.properties
deleted file mode 100644
index 2777089..0000000
--- a/core/camel-core-engine/src/generated/resources/META-INF/services/org/apache/camel/model.properties
+++ /dev/null
@@ -1,204 +0,0 @@
-# Generated by camel build tools - do NOT edit this file!
-aggregate
-any23
-apiKey
-asn1
-avro
-barcode
-base64
-basicAuth
-batch-config
-bean
-beanio
-bindy
-blacklistServiceFilter
-cachingServiceDiscovery
-cbor
-choice
-circuitBreaker
-claimCheck
-combinedServiceDiscovery
-combinedServiceFilter
-constant
-consulServiceDiscovery
-contextScan
-convertBodyTo
-crypto
-csv
-customDataFormat
-customLoadBalancer
-customServiceFilter
-dataFormats
-defaultLoadBalancer
-delay
-delete
-description
-dnsServiceDiscovery
-doCatch
-doFinally
-doTry
-dynamicRouter
-enrich
-etcdServiceDiscovery
-exchangeProperty
-expression
-failover
-faultToleranceConfiguration
-fhirJson
-fhirXml
-filter
-flatpack
-from
-get
-globalOption
-globalOptions
-grok
-groovy
-gzipdeflater
-head
-header
-healthyServiceFilter
-hl7
-hl7terser
-hystrixConfiguration
-ical
-idempotentConsumer
-inOnly
-inOut
-inputType
-intercept
-interceptFrom
-interceptSendToEndpoint
-jacksonxml
-jaxb
-joor
-json
-jsonApi
-jsonpath
-kubernetesServiceDiscovery
-language
-loadBalance
-loadBalancerConfiguration
-log
-loop
-lzf
-marshal
-method
-mime-multipart
-multicast
-mvel
-oauth2
-ognl
-onCompletion
-onException
-onFallback
-optimisticLockRetryPolicy
-otherwise
-outputType
-packageScan
-param
-passThroughServiceFilter
-patch
-pgp
-pipeline
-policy
-pollEnrich
-post
-process
-property
-protobuf
-put
-random
-recipientList
-redeliveryPolicy
-ref
-removeHeader
-removeHeaders
-removeProperties
-removeProperty
-resequence
-resilience4jConfiguration
-responseHeader
-responseMessage
-rest
-restBinding
-restConfiguration
-restContextRef
-restProperty
-rests
-ribbonLoadBalancer
-rollback
-roundRobin
-route
-routeBuilder
-routeContextRef
-routeTemplate
-routeTemplateContextRef
-routeTemplates
-routes
-routingSlip
-rss
-saga
-sample
-script
-secureXML
-security
-securityDefinitions
-serviceCall
-serviceCallConfiguration
-serviceChooserConfiguration
-serviceDiscoveryConfiguration
-serviceExpression
-serviceFilterConfiguration
-setBody
-setExchangePattern
-setHeader
-setProperty
-simple
-soapjaxb
-sort
-spel
-split
-staticServiceDiscovery
-step
-sticky
-stop
-stream-config
-syslog
-tarfile
-templateParameter
-threadPoolProfile
-threads
-thrift
-throttle
-throwException
-tidyMarkup
-to
-toD
-tokenize
-topic
-transacted
-transform
-transformers
-typeFilter
-univocity-csv
-univocity-fixed
-univocity-header
-univocity-tsv
-unmarshal
-validate
-validators
-verb
-weighted
-when
-whenSkipSendToEndpoint
-wireTap
-xmlrpc
-xpath
-xquery
-xstream
-xtokenize
-yaml
-zipdeflater
-zipfile
-zookeeperServiceDiscovery
diff --git a/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightCamelContext.java b/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightCamelContext.java
index 7e1110d..b42f8ed 100644
--- a/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightCamelContext.java
+++ b/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightCamelContext.java
@@ -1483,6 +1483,16 @@ public class LightweightCamelContext implements ExtendedCamelContext, CatalogCam
         return getExtendedCamelContext().createErrorHandler(route, processor);
     }
 
+    @Override
+    public void setLightweight(boolean lightweight) {
+        getExtendedCamelContext().setLightweight(lightweight);
+    }
+
+    @Override
+    public boolean isLightweight() {
+        return getExtendedCamelContext().isLightweight();
+    }
+
     //
     // CatalogCamelContext
     //
@@ -1795,16 +1805,6 @@ public class LightweightCamelContext implements ExtendedCamelContext, CatalogCam
         getModelCamelContext().registerTransformer(transformer);
     }
 
-    @Override
-    public void setClearReifiers(boolean clearReifiers) {
-        getExtendedCamelContext().setClearReifiers(clearReifiers);
-    }
-
-    @Override
-    public boolean isClearReifiers() {
-        return getExtendedCamelContext().isClearReifiers();
-    }
-
     //
     // Immutable
     //
diff --git a/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightRuntimeCamelContext.java b/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightRuntimeCamelContext.java
index c2b1427..387a4d9 100644
--- a/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightRuntimeCamelContext.java
+++ b/core/camel-core-engine/src/main/java/org/apache/camel/impl/lw/LightweightRuntimeCamelContext.java
@@ -345,16 +345,6 @@ public class LightweightRuntimeCamelContext implements ExtendedCamelContext, Cat
     }
 
     @Override
-    public void setClearReifiers(boolean clearReifiers) {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public boolean isClearReifiers() {
-        return true;
-    }
-
-    @Override
     public void setStreamCaching(Boolean cache) {
         throw new UnsupportedOperationException();
     }
@@ -1803,6 +1793,16 @@ public class LightweightRuntimeCamelContext implements ExtendedCamelContext, Cat
     }
 
     @Override
+    public void setLightweight(boolean lightweight) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public boolean isLightweight() {
+        return true;
+    }
+
+    @Override
     public RouteController getInternalRouteController() {
         return new RouteController() {
             @Override
diff --git a/core/camel-main/src/generated/java/org/apache/camel/main/MainConfigurationPropertiesConfigurer.java b/core/camel-main/src/generated/java/org/apache/camel/main/MainConfigurationPropertiesConfigurer.java
index 14e3a01..5798b43 100644
--- a/core/camel-main/src/generated/java/org/apache/camel/main/MainConfigurationPropertiesConfigurer.java
+++ b/core/camel-main/src/generated/java/org/apache/camel/main/MainConfigurationPropertiesConfigurer.java
@@ -34,7 +34,6 @@ public class MainConfigurationPropertiesConfigurer extends org.apache.camel.supp
         map.put("BeanIntrospectionLoggingLevel", org.apache.camel.LoggingLevel.class);
         map.put("BeanPostProcessorEnabled", boolean.class);
         map.put("CaseInsensitiveHeaders", boolean.class);
-        map.put("ClearReifiers", boolean.class);
         map.put("ConfigurationClasses", java.lang.String.class);
         map.put("Configurations", java.util.List.class);
         map.put("ConsumerTemplateCacheSize", int.class);
@@ -143,8 +142,6 @@ public class MainConfigurationPropertiesConfigurer extends org.apache.camel.supp
         case "BeanPostProcessorEnabled": target.setBeanPostProcessorEnabled(property(camelContext, boolean.class, value)); return true;
         case "caseinsensitiveheaders":
         case "CaseInsensitiveHeaders": target.setCaseInsensitiveHeaders(property(camelContext, boolean.class, value)); return true;
-        case "clearreifiers":
-        case "ClearReifiers": target.setClearReifiers(property(camelContext, boolean.class, value)); return true;
         case "configurationclasses":
         case "ConfigurationClasses": target.setConfigurationClasses(property(camelContext, java.lang.String.class, value)); return true;
         case "configurations":
@@ -334,8 +331,6 @@ public class MainConfigurationPropertiesConfigurer extends org.apache.camel.supp
         case "BeanPostProcessorEnabled": return target.isBeanPostProcessorEnabled();
         case "caseinsensitiveheaders":
         case "CaseInsensitiveHeaders": return target.isCaseInsensitiveHeaders();
-        case "clearreifiers":
-        case "ClearReifiers": return target.isClearReifiers();
         case "configurationclasses":
         case "ConfigurationClasses": return target.getConfigurationClasses();
         case "configurations":
diff --git a/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json b/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json
index c291594..b64d68b 100644
--- a/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json
+++ b/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json
@@ -25,7 +25,6 @@
     { "name": "camel.main.beanIntrospectionLoggingLevel", "description": "Sets the logging level used by bean introspection, logging activity of its usage. The default is TRACE.", "sourceType": "org.apache.camel.main.DefaultConfigurationProperties", "type": "object", "javaType": "org.apache.camel.LoggingLevel", "enum": [ "ERROR", "WARN", "INFO", "DEBUG", "TRACE", "OFF" ] },
     { "name": "camel.main.beanPostProcessorEnabled", "description": "Can be used to turn off bean post processing. Be careful to turn this off, as this means that beans that use Camel annotations such as org.apache.camel.EndpointInject , org.apache.camel.ProducerTemplate , org.apache.camel.Produce , org.apache.camel.Consume etc will not be injected and in use. Turning this off should only be done if you are sure you do not use any of these Camel features. Not all runtimes allow turning t [...]
     { "name": "camel.main.caseInsensitiveHeaders", "description": "Whether to use case sensitive or insensitive headers. Important: When using case sensitive (this is set to false). Then the map is case sensitive which means headers such as content-type and Content-Type are two different keys which can be a problem for some protocols such as HTTP based, which rely on case insensitive headers. However case sensitive implementations can yield faster performance. Therefore use case sensitiv [...]
-    { "name": "camel.main.clearReifiers", "description": "Whether reifiers should be cleared. If enabled this will trigger some optimizations and memory reduction, however dynamic routes cannot be added after Camel has been started.", "sourceType": "org.apache.camel.main.DefaultConfigurationProperties", "type": "boolean", "javaType": "boolean" },
     { "name": "camel.main.configurationClasses", "description": "Sets classes names that will be used to configure the camel context as example by providing custom beans through org.apache.camel.BindToRegistry annotation.", "sourceType": "org.apache.camel.main.MainConfigurationProperties", "type": "string", "javaType": "java.lang.String" },
     { "name": "camel.main.configurations", "description": "Sets the configuration objects used to configure the camel context.", "sourceType": "org.apache.camel.main.MainConfigurationProperties", "type": "object", "javaType": "java.util.List" },
     { "name": "camel.main.consumerTemplateCacheSize", "description": "Consumer template endpoints cache size.", "sourceType": "org.apache.camel.main.DefaultConfigurationProperties", "type": "integer", "javaType": "int", "defaultValue": 1000 },
diff --git a/core/camel-main/src/main/docs/main.adoc b/core/camel-main/src/main/docs/main.adoc
index 2de4441..832d6d9 100644
--- a/core/camel-main/src/main/docs/main.adoc
+++ b/core/camel-main/src/main/docs/main.adoc
@@ -37,7 +37,6 @@ The following table lists all the options:
 | *camel.main.beanIntrospection{zwsp}LoggingLevel* | Sets the logging level used by bean introspection, logging activity of its usage. The default is TRACE. |  | LoggingLevel
 | *camel.main.beanPostProcessor{zwsp}Enabled* | Can be used to turn off bean post processing. Be careful to turn this off, as this means that beans that use Camel annotations such as org.apache.camel.EndpointInject , org.apache.camel.ProducerTemplate , org.apache.camel.Produce , org.apache.camel.Consume etc will not be injected and in use. Turning this off should only be done if you are sure you do not use any of these Camel features. Not all runtimes allow turning this off (such as came [...]
 | *camel.main.caseInsensitive{zwsp}Headers* | Whether to use case sensitive or insensitive headers. Important: When using case sensitive (this is set to false). Then the map is case sensitive which means headers such as content-type and Content-Type are two different keys which can be a problem for some protocols such as HTTP based, which rely on case insensitive headers. However case sensitive implementations can yield faster performance. Therefore use case sensitive implementation with [...]
-| *camel.main.clearReifiers* | Whether reifiers should be cleared. If enabled this will trigger some optimizations and memory reduction, however dynamic routes cannot be added after Camel has been started. |  | boolean
 | *camel.main.configuration{zwsp}Classes* | Sets classes names that will be used to configure the camel context as example by providing custom beans through org.apache.camel.BindToRegistry annotation. |  | String
 | *camel.main.configurations* | Sets the configuration objects used to configure the camel context. |  | List
 | *camel.main.consumerTemplate{zwsp}CacheSize* | Consumer template endpoints cache size. | 1000 | int
diff --git a/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationConfigurer.java b/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationConfigurer.java
index f8df0db..a35bded 100644
--- a/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationConfigurer.java
+++ b/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationConfigurer.java
@@ -89,7 +89,7 @@ public final class DefaultConfigurationConfigurer {
      */
     public static void configure(CamelContext camelContext, DefaultConfigurationProperties config) throws Exception {
         ExtendedCamelContext ecc = camelContext.adapt(ExtendedCamelContext.class);
-        ecc.setClearReifiers(config.isClearReifiers());
+        ecc.setLightweight(config.isLightweight());
         ecc.getBeanPostProcessor().setEnabled(config.isBeanPostProcessorEnabled());
         ecc.getBeanIntrospection().setExtendedStatistics(config.isBeanIntrospectionExtendedStatistics());
         if (config.getBeanIntrospectionLoggingLevel() != null) {
diff --git a/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationProperties.java b/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationProperties.java
index 702b724..7998476 100644
--- a/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationProperties.java
+++ b/core/camel-main/src/main/java/org/apache/camel/main/DefaultConfigurationProperties.java
@@ -86,7 +86,6 @@ public abstract class DefaultConfigurationProperties<T> {
     private String xmlRouteTemplates = "classpath:camel-template/*.xml";
     private String xmlRests = "classpath:camel-rest/*.xml";
     private boolean lightweight;
-    private boolean clearReifiers;
     // route controller
     @Metadata(defaultValue = "INFO")
     private LoggingLevel routeControllerRouteStartupLoggingLevel = LoggingLevel.INFO;
@@ -935,20 +934,6 @@ public abstract class DefaultConfigurationProperties<T> {
         this.lightweight = lightweight;
     }
 
-    @Experimental
-    public boolean isClearReifiers() {
-        return clearReifiers;
-    }
-
-    /**
-     * Whether reifiers should be cleared. If enabled this will trigger some optimizations and memory reduction, however
-     * dynamic routes cannot be added after Camel has been started.
-     */
-    @Experimental
-    public void setClearReifiers(boolean clearReifiers) {
-        this.clearReifiers = clearReifiers;
-    }
-
     public LoggingLevel getRouteControllerRouteStartupLoggingLevel() {
         return routeControllerRouteStartupLoggingLevel;
     }
@@ -1776,16 +1761,6 @@ public abstract class DefaultConfigurationProperties<T> {
     }
 
     /**
-     * Whether reifiers should be cleared. If enabled this will trigger some optimizations and memory reduction, however
-     * dynamic routes cannot be added after Camel has been started.
-     */
-    @Experimental
-    public T withClearReifiers(boolean clearReifiers) {
-        this.clearReifiers = clearReifiers;
-        return (T) this;
-    }
-
-    /**
      * Sets the logging level used for logging route startup activity. By default INFO level is used. You can use this
      * to change the level for example to OFF if this kind of logging is not wanted.
      */
diff --git a/core/camel-main/src/main/java/org/apache/camel/main/Main.java b/core/camel-main/src/main/java/org/apache/camel/main/Main.java
index 941aa0a..af29695 100644
--- a/core/camel-main/src/main/java/org/apache/camel/main/Main.java
+++ b/core/camel-main/src/main/java/org/apache/camel/main/Main.java
@@ -21,7 +21,6 @@ import java.util.Map;
 import org.apache.camel.CamelContext;
 import org.apache.camel.ProducerTemplate;
 import org.apache.camel.impl.DefaultCamelContext;
-import org.apache.camel.impl.lw.LightweightCamelContext;
 import org.apache.camel.spi.Registry;
 
 /**
@@ -140,11 +139,13 @@ public class Main extends MainCommandLineSupport {
 
     @Override
     protected CamelContext createCamelContext() {
-        if (mainConfigurationProperties.isLightweight()) {
-            return new LightweightCamelContext(registry);
-        } else {
-            return new DefaultCamelContext(registry);
-        }
+        return new DefaultCamelContext(registry);
+        // TODO: LightweightCamelContext is not ready yet
+        //if (mainConfigurationProperties.isLightweight()) {
+        //    return new LightweightCamelContext(registry);
+        //} else {
+        //    return new DefaultCamelContext(registry);
+        //}
     }
 
 }
diff --git a/core/camel-main/src/test/java/org/apache/camel/main/MainFaultToleranceTest.java b/core/camel-main/src/test/java/org/apache/camel/main/MainFaultToleranceTest.java
deleted file mode 100644
index bcb3c1a..0000000
--- a/core/camel-main/src/test/java/org/apache/camel/main/MainFaultToleranceTest.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.camel.main;
-
-import org.apache.camel.CamelContext;
-import org.apache.camel.model.FaultToleranceConfigurationDefinition;
-import org.apache.camel.model.ModelCamelContext;
-import org.junit.jupiter.api.Test;
-
-import static org.junit.jupiter.api.Assertions.assertEquals;
-import static org.junit.jupiter.api.Assertions.assertNotNull;
-
-public class MainFaultToleranceTest {
-
-    @Test
-    public void testMain() throws Exception {
-        Main main = new Main();
-
-        main.addInitialProperty("camel.faulttolerance.failure-ratio", "555");
-        main.addInitialProperty("camel.faulttolerance.timeout-pool-size", "20");
-
-        main.configure().faultTolerance()
-                .withBulkheadEnabled(true)
-                .withDelay(500L)
-                .withSuccessThreshold(123)
-                .withTimeoutPoolSize(5)
-                .end();
-
-        main.start();
-
-        CamelContext context = main.getCamelContext();
-        assertNotNull(context);
-
-        ModelCamelContext mcc = context.adapt(ModelCamelContext.class);
-        FaultToleranceConfigurationDefinition def = mcc.getFaultToleranceConfiguration(null);
-        assertNotNull(def);
-
-        assertEquals("500", def.getDelay());
-        assertEquals("123", def.getSuccessThreshold());
-        assertEquals("20", def.getTimeoutPoolSize());
-        assertEquals("555", def.getFailureRatio());
-        assertEquals("true", def.getBulkheadEnabled());
-
-        main.stop();
-    }
-
-}