public class Test {
public static void main(String[] args) throws Exception {
//final BlockingQueue<String> bq = new ArrayBlockingQueue<String>(10);
final SynchronousQueue<String> bq=new SynchronousQueue<String>();
final Semaphore sp = new Semaphore(1,true);
/*Executors.newFixedThreadPool(10).execute(new Runnable(){
public void run() {
// TODO Auto-generated method stub
try {
sp.acquire();
String output = null;