Configuring event logging for the promotion engine

Enable event logging to track problems that are related to promotion events. The events are written to the SystemOut.log file that contains all other HCL Commerce output. When you enable event logging, promotion events from both HCL Commerce Accelerator and Management Center are included in the file.

Procedure

  1. Edit the promotion engine configuration XML file.

    workspace_dir/WC/xml/PromotionEngineConfiguration/WCSPromotionEngineConfig.xml

  2. Update the following code segment:
    <!--        
    <Listener
    impl="com.ibm.commerce.marketing.promotion.event.PrintPromotionLifeCycleEventListener">
       <Name>PrintLifeCycleEventListener</Name>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionChangedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionCreatedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionDeployedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionRemovedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionResetEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionResumedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionSuspendedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionWithdrawnEvent</ListensFor>
    
    </Listener>
    
    <Listener
    impl="com.ibm.commerce.marketing.promotion.event.PrintPromotionExecutionEventListener">
       <Name>PrintExecutionEventListener</Name>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionAssessedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionAppliedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionEliminatedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionQualifiedEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionRejectedEvent</ListensFor>
    </Listener>
    
    <Listener
    impl="com.ibm.commerce.marketing.promotion.event.PrintPromotionRASEventListener">
       <Name>PrintRASEventListener</Name>
       
    <StoreKey>
          <DN>ou=BlueMall B2C Organization,o=Seller
    Organization,o=Root Organization</DN>
          <Identifier>BlueStore 201</Identifier>
       </StoreKey>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionDebugEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionErrorEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionLogEvent</ListensFor>
      
    <ListensFor>com.ibm.commerce.marketing.promotion.event.PromotionTraceEvent</ListensFor>
       </Listener>
    -->
    
    Remove the segments in bold to enable event logging. This includes the comment delimiter (<!-- and -->) and the entire StoreKey XML element.
  3. Save the file.

Results

The trace is written to the SystemOut.log file that contains all other HCL Commerce output. When you have captured the required trace information, you should disable tracing as it might negatively affect performance.