Package com.skava.ratingandreviews.event
Class RatingandReviewEventSender
java.lang.Object
com.skava.ratingandreviews.event.RatingandReviewEventSender
@Configuration
@Component
@ConditionalOnProperty(prefix="skava.event.rabbitmq",
name="enabled",
havingValue="true")
public class RatingandReviewEventSender
extends Object
RatingandReviewEventSender class
class which provides the information for RatingandReviewEventSender
-
Constructor Summary
ConstructorsConstructorDescriptionRatingandReviewEventSender
(com.skava.core.event.EventClientComponent eventClientComponent) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
send
(com.skava.core.event.Message<?> listMessage, String topicName, String routingKey, Long businessId, Long collectionId, String storeId) Message event sender by topic exchange or queue name If default message queue enabled in oms properties this will override queue name to default oms queuevoid
triggerEvent
(RatingReviewEventPayload listEventPayload, String routingKey, long collectionId, String messageType, String storeId, String authToken) The method triggers the event for the given queue or topicvoid
triggerEvent
(RatingSummaryEventPayload listEventPayload, String routingKey, long collectionId, String messageType, String storeId, String authToken) The method triggers the event for the given queue or topic
-
Constructor Details
-
RatingandReviewEventSender
@Autowired(required=false) public RatingandReviewEventSender(com.skava.core.event.EventClientComponent eventClientComponent)
-
-
Method Details
-
send
protected void send(com.skava.core.event.Message<?> listMessage, String topicName, String routingKey, Long businessId, Long collectionId, String storeId) Message event sender by topic exchange or queue name If default message queue enabled in oms properties this will override queue name to default oms queue- Parameters:
listMessage
- Order MessagetopicName
- Topic exchange nameroutingKey
- Routing KeybusinessId
- the business identifier Gets the businessId from the collectionIdcollectionId
- the collection identifierstoreId
- the store identifier
-
triggerEvent
public void triggerEvent(RatingReviewEventPayload listEventPayload, String routingKey, long collectionId, String messageType, String storeId, String authToken) The method triggers the event for the given queue or topic- Parameters:
listEventPayload
- The list pay load of the messageroutingKey
- The routing key where the message needs to be sentcollectionId
- Holds a valid collection identifier of this microservice. The requested operation will be performed on this collection identifier. A collection is the topmost entity of a microservice under which all the other entities/resources reside. Each collection represents an instance of the microservice with the configured properties. These properties can be modified to bring in a different behavior per collection of the same microservice. The Store association is the process of associating a microservice collection to a store along with its respective sub-entity. This way, the storefront can fetch/store the required information from that respective association.messageType
- holds the message type of the eventstoreId
- the store identifierauthToken
- the authToken
-
triggerEvent
public void triggerEvent(RatingSummaryEventPayload listEventPayload, String routingKey, long collectionId, String messageType, String storeId, String authToken) The method triggers the event for the given queue or topic- Parameters:
listEventPayload
- The list pay load of the messageroutingKey
- The routing key where the message needs to be sentcollectionId
- Holds a valid collection identifier of this microservice. The requested operation will be performed on this collection identifier. A collection is the topmost entity of a microservice under which all the other entities/resources reside. Each collection represents an instance of the microservice with the configured properties. These properties can be modified to bring in a different behavior per collection of the same microservice. The Store association is the process of associating a microservice collection to a store along with its respective sub-entity. This way, the storefront can fetch/store the required information from that respective association.messageType
- holds the message type of the eventstoreId
- the store identifierauthToken
- the authToken
-