use of com.linkedin.databus2.relay.config.PhysicalSourceConfig in project databus by linkedin.
the class TestDbusPhysicalPartitionEventBuffer method deserializePhysicalSourceConfigWithEbuffer.
@Test
public void deserializePhysicalSourceConfigWithEbuffer() throws JSONException, JsonParseException, JsonMappingException, IOException {
JSONObject jsonObject = new JSONObject(PhysicalSourcesConfigWithEBuffer.toString());
Assert.assertNotEquals(jsonObject.get("dbusEventBuffer"), JSONObject.NULL);
ObjectMapper mapper = new ObjectMapper();
PhysicalSourceConfig config = mapper.readValue(jsonObject.toString(), PhysicalSourceConfig.class);
//System.out.println(config.toString());
Assert.assertEquals(config.isDbusEventBufferSet(), true);
}
Aggregations