每当我在 Spring 启动时在我的 restcontroller 中的一个 getmapping 方法中进行以下调用时,它永远不会被执行。当我注释掉三个中的一个时,它可以完美地工作。哪个组合都没有关系,它们都可以工作,但最多有两个。
HttpGet httpget1 = new HttpGet(url+"api/now/table/incident?assignment_group=FS_logistic&incident_state=1");
httpget1.setHeader("Accept", "application/json");
CloseableHttpResponse response1 = httpclient.execute(httpget1);
HttpGet httpget2 = new HttpGet(url+"api/now/table/incident?assignment_group=FS_logistic&incident_state=2");
httpget2.setHeader("Accept", "application/json");
CloseableHttpResponse response2 = httpclient.execute(httpget2);
HttpGet httpget3 = new HttpGet(url+"api/now/table/incident?assignment_group=FS_logistic&incident_state=3");
httpget3.setHeader("Accept", "application/json");
CloseableHttpResponse response3 = httpclient.execute(httpget3);