// Path: multiple-microservices-example/reference-data-service/src/main/java/org/sapient/metalica/referencedataservice/model/CounterParty.java
// @Document
// public class CounterParty {
// 
//     @Id @Field("_id") private String code;
//     @Field private String name;
// 
//     public CounterParty(String code, String name) {
//         this.code = code;
//         this.name = name;
//     }
// 
//     public String getCode() {
//         return code;
//     }
// 
//     public void setCode(String code) {
//         this.code = code;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
// }
// 
// Path: multiple-microservices-example/reference-data-service/src/main/java/org/sapient/metalica/referencedataservice/repository/CounterPartyRepository.java
// @Repository
// public interface CounterPartyRepository extends MongoRepository<CounterParty, String> {
// 
// }
// 
// Path: multiple-microservices-example/reference-data-service/src/main/java/org/sapient/metalica/referencedataservice/util/CommonUtil.java
// public interface CommonUtil {
// 
//     static boolean isEmpty(String obj) {
//         return obj == null || obj.isEmpty();
//     }
// 
//     static boolean notEmpty(String obj) {
//         return !isEmpty(obj);
//     }
// 
// }


import org.sapient.metalica.referencedataservice.model.CounterParty;
import org.sapient.metalica.referencedataservice.repository.CounterPartyRepository;
import org.sapient.metalica.referencedataservice.util.CommonUtil;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import javax.annotation.Resource;
import java.util.Collection;
import java.util.Collections;
import static org.sapient.metalica.referencedataservice.constant.Constants.COUNTER_PARTY_DATA_QUEUE;
package org.sapient.metalica.referencedataservice.listener;




public class CounterPartyListener {

    @Resource CounterPartyRepository counterPartyRepository;

// Path: multiple-microservices-example/reference-data-service/src/main/java/org/sapient/metalica/referencedataservice/model/CounterParty.java
// @Document
// public class CounterParty {
// 
//     @Id @Field("_id") private String code;
//     @Field private String name;
// 
//     public CounterParty(String code, String name) {
//         this.code = code;
//         this.name = name;
//     }
// 
//     public String getCode() {
//         return code;
//     }
// 
//     public void setCode(String code) {
//         this.code = code;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
// }
// 
// Path: multiple-microservices-example/reference-data-service/src/main/java/org/sapient/metalica/referencedataservice/repository/CounterPartyRepository.java
// @Repository
// public interface CounterPartyRepository extends MongoRepository<CounterParty, String> {
// 
// }
// 
// Path: multiple-microservices-example/reference-data-service/src/main/java/org/sapient/metalica/referencedataservice/util/CommonUtil.java
// public interface CommonUtil {
// 
//     static boolean isEmpty(String obj) {
//         return obj == null || obj.isEmpty();
//     }
// 
//     static boolean notEmpty(String obj) {
//         return !isEmpty(obj);
//     }
// 
// }


// Path: multiple-microservices-example/reference-data-service/src/main/java/org/sapient/metalica/referencedataservice/listener/CounterPartyListener.java
import org.sapient.metalica.referencedataservice.model.CounterParty;
import org.sapient.metalica.referencedataservice.repository.CounterPartyRepository;
import org.sapient.metalica.referencedataservice.util.CommonUtil;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import javax.annotation.Resource;
import java.util.Collection;
import java.util.Collections;
import static org.sapient.metalica.referencedataservice.constant.Constants.COUNTER_PARTY_DATA_QUEUE;

package org.sapient.metalica.referencedataservice.listener;




public class CounterPartyListener {

    @Resource CounterPartyRepository counterPartyRepository;

    @RabbitListener(queues = COUNTER_PARTY_DATA_QUEUE)