public DiscoveryUpstreamData mapToData(DiscoveryUpstreamDO discoveryUpstreamDO) {
        return Optional.ofNullable(discoveryUpstreamDO).map(data -> {
            DiscoveryUpstreamData discoveryUpstreamData = new DiscoveryUpstreamData();
            discoveryUpstreamData.setId(data.getId());
            discoveryUpstreamData.setProtocol(data.getProtocol());
            discoveryUpstreamData.setUrl(data.getUrl());
            discoveryUpstreamData.setStatus(data.getStatus());
            discoveryUpstreamData.setDiscoveryHandlerId(data.getDiscoveryHandlerId());
            discoveryUpstreamData.setWeight(data.getWeight());
            discoveryUpstreamData.setProps(data.getProps());
            discoveryUpstreamData.setDateUpdated(data.getDateUpdated());
            discoveryUpstreamData.setDateCreated(data.getDateCreated());
            return discoveryUpstreamData;
        }).orElse(null);
    }
mapToData.

@param discoveryUpstreamDO discoveryUpstreamDO
@return DiscoveryUpstreamData
shenyu-admin/src/main/java/org/apache/shenyu/admin/transfer/DiscoveryTransfer.java