<commit_before>package org.jasig.portal.events.tincan;

import java.util.Queue;
import java.util.concurrent.ConcurrentLinkedQueue;

import org.jasig.portal.events.tincan.om.LrsObject;
import org.springframework.scheduling.annotation.Scheduled;

public class TincanConcurrentQueueHandler {
	
	final private Queue<LrsObject> theQueue = new ConcurrentLinkedQueue<LrsObject>();
	
	/**
	 * Clear the queue every 1 second after last completion
	 */
	@Scheduled(fixedDelay = 1000)
	private void clearQueue()
	{
		LrsObject	 cur = theQueue.poll();
		while (cur != null) {
			//TODO : Add in call to process request
			cur = theQueue.poll();
		}
	}
	
	public void sendLrs(LrsObject newEdition) {
		theQueue.add(newEdition);
	}
}
<commit_msg>UP-3724 Switch to use LrsStatement type<commit_after>package org.jasig.portal.events.tincan;

import java.util.Queue;
import java.util.concurrent.ConcurrentLinkedQueue;

import org.jasig.portal.events.tincan.om.LrsObject;
import org.jasig.portal.events.tincan.om.LrsStatement;
import org.springframework.scheduling.annotation.Scheduled;

public class TincanConcurrentQueueHandler {
	
	final private Queue<LrsStatement> theQueue = new ConcurrentLinkedQueue<LrsStatement>();
	
	/**
	 * Clear the queue every 1 second after last completion
	 */
	@Scheduled(fixedDelay = 1000)
	private void clearQueue()
	{
	    LrsStatement	 cur = theQueue.poll();
		while (cur != null) {
			//TODO : Add in call to process request
			cur = theQueue.poll();
		}
	}
	
	public void sendLrs(LrsStatement newEdition) {
		theQueue.add(newEdition);
	}
}

{'fraction_non_alphanumeric': 0.10512820512820513, 'fraction_numerical': 0.008974358974358974, 'mean_word_length': 4.535460992907802, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6207347', 'n_tokens_mistral': 548, 'n_tokens_neox': 506, 'n_words': 113}