All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.dell.cpsd.common.rabbitmq.validators.DefaultMessageValidator Maven / Gradle / Ivy

There is a newer version: 2.2.0
Show newest version
/**
 * Copyright © 2017 Dell Inc. or its subsidiaries.  All Rights Reserved.
 * Dell EMC Confidential/Proprietary Information
 */

package com.dell.cpsd.common.rabbitmq.validators;

import com.dell.cpsd.common.rabbitmq.message.HasMessageProperties;
import com.dell.cpsd.common.rabbitmq.message.MessagePropertiesContainer;

/**
 * Default implementation of message validator.
 * 

*

* Copyright © 2017 Dell Inc. or its subsidiaries. All Rights Reserved. * Dell EMC Confidential/Proprietary Information *

*/ public class DefaultMessageValidator> extends GenericMessageValidator { @Override protected void validateMessage(M message, ValidationResult validationResult) throws Exception { MessagePropertiesContainer properties = message.getMessageProperties(); validateNotNull(properties, "messageProperties", validationResult); if (properties != null) { validateNotEmpty(properties.getCorrelationId(), "correlationId", validationResult); validateNotEmpty(properties.getReplyTo(), "replyTo", validationResult); } } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy