Merge pull request #668 from warunalakshitha/master

Push notification scheduler Task
revert-dabc3590
Geeth 8 years ago committed by GitHub
commit 5597d4370b

@ -20,7 +20,11 @@ package org.wso2.carbon.device.mgt.mobile.android.impl;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.wso2.carbon.device.mgt.common.*;
import org.wso2.carbon.device.mgt.common.DeviceManagementException;
import org.wso2.carbon.device.mgt.common.DeviceManager;
import org.wso2.carbon.device.mgt.common.InitialOperationConfig;
import org.wso2.carbon.device.mgt.common.OperationMonitoringTaskConfig;
import org.wso2.carbon.device.mgt.common.ProvisioningConfig;
import org.wso2.carbon.device.mgt.common.app.mgt.ApplicationManager;
import org.wso2.carbon.device.mgt.common.configuration.mgt.ConfigurationEntry;
import org.wso2.carbon.device.mgt.common.configuration.mgt.PlatformConfiguration;
@ -94,7 +98,8 @@ public class AndroidDeviceManagementService implements DeviceManagementService {
HashMap<String, String> config = new HashMap<>();
config.put(FCM_API_KEY, this.getConfigProperty(configuration, FCM_API_KEY));
config.put(FCM_SENDER_ID, this.getConfigProperty(configuration, FCM_SENDER_ID));
return new PushNotificationConfig(AndroidPluginConstants.NotifierType.FCM, config);
return new PushNotificationConfig(AndroidPluginConstants.NotifierType.FCM, false,
config);
}
}
}

@ -51,9 +51,13 @@
<ProvisioningConfig>
<SharedWithAllTenants>true</SharedWithAllTenants>
</ProvisioningConfig>
<!--
isScheduled element used to enable scheduler task to send push notification.
Task will send push notification as batches. So this will reduce sudden request burst when many devices try to
access server after receiving push notification.
-->
<!--Configuration for enable firebase push notifications-->
<!--<PushNotificationProvider type="FCM">-->
<!--<PushNotificationProvider type="FCM" isScheduled="false">-->
<!--</PushNotificationProvider>-->
<DataSource>

Loading…
Cancel
Save