com.netflix.discovery.converters.wrappers.CodecWrappers Java Examples

The following examples show how to use com.netflix.discovery.converters.wrappers.CodecWrappers. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: EurekaServerAutoConfiguration.java    From didi-eureka-server with MIT License 4 votes vote down vote up
private static CodecWrapper getFullJson(EurekaServerConfig serverConfig) {
	CodecWrapper codec = CodecWrappers.getCodec(serverConfig.getJsonCodecName());
	return codec == null ? CodecWrappers.getCodec(JACKSON_JSON.codecName()) : codec;
}
 
Example #2
Source File: EurekaServerAutoConfiguration.java    From didi-eureka-server with MIT License 4 votes vote down vote up
private static CodecWrapper getFullXml(EurekaServerConfig serverConfig) {
	CodecWrapper codec = CodecWrappers.getCodec(serverConfig.getXmlCodecName());
	return codec == null ? CodecWrappers.getCodec(CodecWrappers.XStreamXml.class)
			: codec;
}
 
Example #3
Source File: EurekaServerAutoConfiguration.java    From didi-eureka-server with MIT License 4 votes vote down vote up
public CloudServerCodecs(EurekaServerConfig serverConfig) {
	super(getFullJson(serverConfig),
			CodecWrappers.getCodec(CodecWrappers.JacksonJsonMini.class),
			getFullXml(serverConfig),
			CodecWrappers.getCodec(CodecWrappers.JacksonXmlMini.class));
}
 
Example #4
Source File: EurekaServerAutoConfiguration.java    From spring-cloud-netflix with Apache License 2.0 4 votes vote down vote up
private static CodecWrapper getFullJson(EurekaServerConfig serverConfig) {
	CodecWrapper codec = CodecWrappers.getCodec(serverConfig.getJsonCodecName());
	return codec == null ? CodecWrappers.getCodec(JACKSON_JSON.codecName()) : codec;
}
 
Example #5
Source File: EurekaServerAutoConfiguration.java    From spring-cloud-netflix with Apache License 2.0 4 votes vote down vote up
private static CodecWrapper getFullXml(EurekaServerConfig serverConfig) {
	CodecWrapper codec = CodecWrappers.getCodec(serverConfig.getXmlCodecName());
	return codec == null ? CodecWrappers.getCodec(CodecWrappers.XStreamXml.class)
			: codec;
}
 
Example #6
Source File: EurekaServerAutoConfiguration.java    From spring-cloud-netflix with Apache License 2.0 4 votes vote down vote up
CloudServerCodecs(EurekaServerConfig serverConfig) {
	super(getFullJson(serverConfig),
			CodecWrappers.getCodec(CodecWrappers.JacksonJsonMini.class),
			getFullXml(serverConfig),
			CodecWrappers.getCodec(CodecWrappers.JacksonXmlMini.class));
}