From c81df8489cae5859f70fde4f38cfe3fdcff62ff9 Mon Sep 17 00:00:00 2001 From: Osara-B Date: Thu, 8 Aug 2024 10:53:29 +0530 Subject: [PATCH 1/2] Update info log of bundle activation to debug log --- .../carbon/mex/internal/Office365SupportMexComponent.java | 5 ++++- .../carbon/mex2/internal/DynamicCRMCustomMexComponent.java | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java b/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java index 88c57062..b475caa1 100644 --- a/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java +++ b/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java @@ -36,7 +36,10 @@ public class Office365SupportMexComponent { @Activate protected void activate(ComponentContext ctxt) { - log.info("Office365Support MexServiceComponent bundle activated successfully.."); + + if (log.isDebugEnabled()) { + log.debug("Office365Support MexServiceComponent bundle activated successfully."); + } } @Deactivate diff --git a/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java b/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java index 1579b08e..ec2f8dc9 100644 --- a/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java +++ b/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java @@ -36,7 +36,10 @@ public class DynamicCRMCustomMexComponent { @Activate protected void activate(ComponentContext ctxt) { - log.info("DynamicCRMSupport MexServiceComponent bundle activated successfully."); + + if (log.isDebugEnabled()) { + log.debug("DynamicCRMSupport MexServiceComponent bundle activated successfully."); + } } @Deactivate From 6bcfdd9c44057fe6a12c0cff54b71e4ed95eff03 Mon Sep 17 00:00:00 2001 From: Osara-B Date: Thu, 8 Aug 2024 11:02:35 +0530 Subject: [PATCH 2/2] Reformat code --- .../carbon/mex/internal/Office365SupportMexComponent.java | 5 +++-- .../carbon/mex2/internal/DynamicCRMCustomMexComponent.java | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java b/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java index b475caa1..a4945de1 100644 --- a/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java +++ b/components/org.wso2.carbon.mex/src/main/java/org/wso2/carbon/mex/internal/Office365SupportMexComponent.java @@ -28,8 +28,8 @@ import org.osgi.service.component.annotations.ReferencePolicy; @Component( - name = "carbon.mex.component", - immediate = true) + name = "carbon.mex.component", + immediate = true) public class Office365SupportMexComponent { private static final Log log = LogFactory.getLog(Office365SupportMexComponent.class); @@ -44,6 +44,7 @@ protected void activate(ComponentContext ctxt) { @Deactivate protected void deactivate(ComponentContext ctxt) { + if (log.isDebugEnabled()) { log.debug("Office365Support MexServiceComponent is deactivated "); } diff --git a/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java b/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java index ec2f8dc9..0c05663c 100644 --- a/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java +++ b/components/org.wso2.carbon.mex2/src/main/java/org/wso2/carbon/mex2/internal/DynamicCRMCustomMexComponent.java @@ -28,8 +28,8 @@ import org.osgi.service.component.annotations.ReferencePolicy; @Component( - name = "carbon.mex2.component", - immediate = true) + name = "carbon.mex2.component", + immediate = true) public class DynamicCRMCustomMexComponent { private static final Log log = LogFactory.getLog(DynamicCRMCustomMexComponent.class); @@ -44,6 +44,7 @@ protected void activate(ComponentContext ctxt) { @Deactivate protected void deactivate(ComponentContext ctxt) { + if (log.isDebugEnabled()) { log.debug("DynamicCRMSupport MexServiceComponent is deactivated."); }