### Question:
ReceivedDataProcessor extends SyncUserProcessor<ReceivedData> { @Override public Object handleRequest(BizContext bizCtx, ReceivedData request) { Result result = new Result(); result.setSuccess(true); if (null == request || null == request.getData()) { return result; } try { List<String> registIds = request.getSubscriberRegistIds(); SegmentData segmentData = new SegmentData(); segmentData.setData(request.getData()); segmentData.setVersion(request.getVersion()); segmentData.setSegment(request.getSegment()); for (String registId : registIds) { Subscriber subscriber = registerCache.getSubscriberByRegistId(registId); if (null == subscriber) { continue; } if (subscriber instanceof DefaultSubscriber) { DefaultSubscriber defaultSubscriber = (DefaultSubscriber) subscriber; defaultSubscriber.putReceivedData(segmentData, request.getLocalZone()); try { observerHandler.notify(subscriber); } catch (Exception e) { LOGGER.error("[received] add notify task error, dataId: {}, registId: {}", subscriber.getDataId(), subscriber.getRegistId(), e); } } else { LOGGER.warn("[received] ignore unknown subscriber type: {}", subscriber .getClass().getName()); } } LOGGER .info( "[received] receive subscriber data save success, dataId: {} group: {} version: {} data:{} registIds:{}", request.getDataId(), request.getGroup(), request.getVersion(), request.getData(), registIds); } catch (Exception e) { result.setSuccess(false); result.setMessage(""); LOGGER .info( "[received] receive subscriber data save failed, dataId: {} group: {} version: {} data:{}", request.getDataId(), request.getGroup(), request.getVersion(), request.getData(), e); } return result; } ReceivedDataProcessor(RegisterCache registerCache, ObserverHandler observerHandler); @Override Object handleRequest(BizContext bizCtx, ReceivedData request); @Override String interest();  }### Answer:
@Test public void handleRequest() { Result result = (Result) processor.handleRequest(null, null); Assert.assertTrue(result.isSuccess()); Assert.assertNull(result.getMessage()); ReceivedData request = new ReceivedData(); result = (Result) processor.handleRequest(null, request); Assert.assertTrue(result.isSuccess()); Assert.assertNull(result.getMessage()); request = new ReceivedData(); request.setSubscriberRegistIds(null); request.setData(new HashMap<String, List<DataBox>>()); request.setVersion(1234L); request.setSegment("seg1"); request.setLocalZone("local"); result = (Result) processor.handleRequest(null, request); Assert.assertFalse(result.isSuccess()); Assert.assertEquals("", result.getMessage()); request.setSubscriberRegistIds(Arrays.asList("11", "22", "33")); result = (Result) processor.handleRequest(null, request); Assert.assertTrue(result.isSuccess()); Assert.assertNull(result.getMessage()); }