package com.example.test; import java.net.URL;import java.net.URLConnection;import java.util.concurrent.CountDownLatch; /** * Created with IDEA * author:QinWei * Date:2018/12/27 * Time:11:08 * 并发测试 */public class ConnectTest { public static void main
一,问题 并发测试,对外接口测试50个并发的时候开发报错,报错信息类似如下: {"status":"0500","message":"GiftExchangeOrderClient#queryExchangeGifts(String,String,String,String) could not be queued for execution and no fallback available.","data&qu
直接上代码进行验证吧 /** * 通过countdownlatch的机制,来实现并发运行 * 模拟200个并发测试 * @author ll * @date 2018年4月18日 下午3:55:59 */ public class CountDownLatchTest { private static final int threadnum = 200; public CountDownLatch cd = new CountDownLatch(threadnum); @Test public