Skip to content

Instantly share code, notes, and snippets.

View EgorLakomkin's full-sized avatar

Egor Lakomkin EgorLakomkin

View GitHub Profile
#include <iostream>
#include <sox.h>
#include <assert.h>
#include <cstring>
#include <vector>
using namespace std;
int main() {
curl -XDELETE "http://localhost:9200/test_es_index" && echo
curl -XPUT "http://localhost:9200/test_es_index" -d ' {
"settings" : {
"number_of_shards": 1,
"number_of_replicas": 0,
"analysis" : {
@EgorLakomkin
EgorLakomkin / gist:3930622
Created October 22, 2012 09:29
HSE keyword src
# -*- coding: utf8 -*-
def check_if_tag_present_strict(tag, chk_list):
if tag in chk_list:
return True
return False
def partial_match(tag1,tag2):
str_tag_1 = tag1.split(" ")
public class QueueTest {
public static void main( String[] args )
{
ProducerThread producer = new ProducerThread();
ConsumerClass consumer = new ConsumerClass( producer );
Thread csThread = new Thread( consumer );
csThread.setPriority(Thread.MAX_PRIORITY);
Thread prodThread = new Thread( producer );