private Cluster.GatewaySender initGatewaySender(ObjectName mbeanName)
      throws InstanceNotFoundException, ReflectionException, IOException {

    Cluster.GatewaySender gatewaySender = new Cluster.GatewaySender();
    AttributeList attributeList =
        mbs.getAttributes(mbeanName, PulseConstants.GATEWAYSENDER_MBEAN_ATTRIBUTES);

    for (Object o : attributeList) {
      Attribute attribute = (Attribute) o;
      String name = attribute.getName();
      switch (name) {
        case PulseConstants.MBEAN_ATTRIBUTE_EVENTRECEIVEDDATE:
          gatewaySender
              .setLinkThroughput(getDoubleAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_BATCHSIZE:
          gatewaySender
              .setBatchSize(getIntegerAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_SENDERID:
          gatewaySender.setId(getStringAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_EVENTQUEUESIZE:
          gatewaySender
              .setQueueSize(getIntegerAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_RUNNING:
          gatewaySender.setStatus(getBooleanAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_PRIMARY:
          gatewaySender.setPrimary(getBooleanAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_PERSISTENCEENABLED:
          gatewaySender.setPersistenceEnabled(
              getBooleanAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_PARALLEL:
          gatewaySender
              .setSenderType(getBooleanAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_REMOTE_DS_ID:
          gatewaySender
              .setRemoteDSId(getIntegerAttribute(attribute.getValue(), attribute.getName()));
          break;
        case PulseConstants.MBEAN_ATTRIBUTE_EVENTS_EXCEEDING_ALERT_THRESHOLD:
          gatewaySender.setEventsExceedingAlertThreshold(
              getIntegerAttribute(attribute.getValue(), attribute.getName()));
          break;
      }
    }
    return gatewaySender;
  }
function used to get attribute values of Gateway Sender and map them to GatewaySender inner
class object
geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/data/JMXDataUpdater.java