private void addGZipSupport(Endpoint ep, Bus bus, GZIP annotation) {
if (annotation != null) {
try {
GZIPFeature feature = new GZIPFeature();
feature.setThreshold(annotation.threshold());
feature.initialize(ep, bus);
} catch (Exception e) {
//ignore - just assume it's an unsupported/unknown annotation
}
}
}