001package com.avaje.ebean.annotation; 002 003/** 004 * Defines the behavior options when a Insert, Update or Delete event occurs 005 * on a bean with an associated ElasticSearch index. 006 * <p> 007 * For some indexes or some transactions it can be beneficial to queue the event 008 * for later processing rather than look to update ElasticSearch at that time. 009 * </p> 010 */ 011public enum DocStoreMode { 012 013 /** 014 * Add the event to the queue for processing later (delaying the update to the document store). 015 */ 016 QUEUE, 017 018 /** 019 * Update the document store when transaction succeeds. 020 */ 021 UPDATE, 022 023 /** 024 * Ignore the event and not update the document store. 025 * <p> 026 * This can be used on a index or for a transaction where you want to have more 027 * manual programmatic control over the updating of the document store. Say you want to 028 * IGNORE on a particular transaction and instead manually queue a bulk update. 029 * </p> 030 */ 031 IGNORE, 032 033 /** 034 * The actual mode of QUEUE, UPDATE or IGNORE is set from the default configuration. 035 */ 036 DEFAULT 037 038}