@Test public void testRecordEventsNoContextNoEvents() { eventsImpl.recordEvents(appName, label , userId, events, contextSet); assertFalse("event envelope should not be created", createdEventEnvelope); }
@Override public void recordEvents(Application.Name applicationName, Experiment.Label experimentLabel, User.ID userID, EventList events, Set<Context> contextSet) { Map<Context, Assignment> assignmentHashMap = getAssignments(userID, applicationName, experimentLabel, contextSet); for (Event event : events.getEvents()) { Assignment assignment = assignmentHashMap.get(event.getContext()); if (assignment != null) { postEventToMysql(assignment, event); ingestEventToRealTimeSystems(applicationName, experimentLabel, event, assignment); } } }
EventsImpl implements Events, EventsMBean { @Override public void recordEvents(Application.Name applicationName, Experiment.Label experimentLabel, User.ID userID, EventList events, Set<Context> contextSet) { Map<Context, Assignment> assignmentHashMap = getAssignments(userID, applicationName, experimentLabel, contextSet); for (Event event : events.getEvents()) { Assignment assignment = assignmentHashMap.get(event.getContext()); if (assignment != null) { postEventToMysql(assignment, event); ingestEventToRealTimeSystems(applicationName, experimentLabel, event, assignment); } } } }
EventsImpl implements Events, EventsMBean { @Override public void recordEvents(Application.Name applicationName, Experiment.Label experimentLabel, User.ID userID, EventList events, Set<Context> contextSet) { Map<Context, Assignment> assignmentHashMap = getAssignments(userID, applicationName, experimentLabel, contextSet); for (Event event : events.getEvents()) { Assignment assignment = assignmentHashMap.get(event.getContext()); if (assignment != null) { postEventToMysql(assignment, event); ingestEventToRealTimeSystems(applicationName, experimentLabel, event, assignment); } } } @Inject  EventsImpl(Map<String, EventIngestionExecutor> eventIngestionExecutors,
                      final @Named(EXECUTOR_THREADPOOL_SIZE) Integer threadPoolSize,
                      final Assignments assignments,
                      final TransactionFactory transactionFactory); }
EventsImpl implements Events, EventsMBean { @Override public void recordEvents(Application.Name applicationName, Experiment.Label experimentLabel, User.ID userID, EventList events, Set<Context> contextSet) { Map<Context, Assignment> assignmentHashMap = getAssignments(userID, applicationName, experimentLabel, contextSet); for (Event event : events.getEvents()) { Assignment assignment = assignmentHashMap.get(event.getContext()); if (assignment != null) { postEventToMysql(assignment, event); ingestEventToRealTimeSystems(applicationName, experimentLabel, event, assignment); } } } @Inject  EventsImpl(Map<String, EventIngestionExecutor> eventIngestionExecutors,
                      final @Named(EXECUTOR_THREADPOOL_SIZE) Integer threadPoolSize,
                      final Assignments assignments,
                      final TransactionFactory transactionFactory); @Override void recordEvents(Application.Name applicationName,
                             Experiment.Label experimentLabel, User.ID userID, EventList events, Set<Context> contextSet); @Override void shutdown(); @Override Map<String, Integer> queuesLength(); @Override int getQueueSize(); }
EventsImpl implements Events, EventsMBean { @Override public void recordEvents(Application.Name applicationName, Experiment.Label experimentLabel, User.ID userID, EventList events, Set<Context> contextSet) { Map<Context, Assignment> assignmentHashMap = getAssignments(userID, applicationName, experimentLabel, contextSet); for (Event event : events.getEvents()) { Assignment assignment = assignmentHashMap.get(event.getContext()); if (assignment != null) { postEventToMysql(assignment, event); ingestEventToRealTimeSystems(applicationName, experimentLabel, event, assignment); } } } @Inject  EventsImpl(Map<String, EventIngestionExecutor> eventIngestionExecutors,
                      final @Named(EXECUTOR_THREADPOOL_SIZE) Integer threadPoolSize,
                      final Assignments assignments,
                      final TransactionFactory transactionFactory); @Override void recordEvents(Application.Name applicationName,
                             Experiment.Label experimentLabel, User.ID userID, EventList events, Set<Context> contextSet); @Override void shutdown(); @Override Map<String, Integer> queuesLength(); @Override int getQueueSize();  }