Commit 3a03e176 by admin

部分推送取消

parent 025cc5e6
...@@ -305,6 +305,19 @@ public class ExcelReadAndWrite { ...@@ -305,6 +305,19 @@ public class ExcelReadAndWrite {
} }
public static void main(String[] args) {
try (Socket s = new Socket(host, port);
PrintWriter pw = new PrintWriter(s.getOutputStream());
BufferedReader bufferedReader = new BufferedReader(
new InputStreamReader(s.getInputStream(), "utf-8"));) {
pw.println("getnum");
pw.flush();
String str = bufferedReader.readLine();
System.out.println("正常运行" + str);
} catch (Exception e) {
log.error("错误信息{}", e);
}
}
public static byte[] readStream(InputStream inStream) throws Exception { public static byte[] readStream(InputStream inStream) throws Exception {
ByteArrayOutputStream outSteam = new ByteArrayOutputStream(); ByteArrayOutputStream outSteam = new ByteArrayOutputStream();
byte[] buffer = new byte[1024]; byte[] buffer = new byte[1024];
......
...@@ -22,7 +22,9 @@ public class ReaderExcel { ...@@ -22,7 +22,9 @@ public class ReaderExcel {
private final static Log log = LogFactory.getLog(ReaderExcel.class); private final static Log log = LogFactory.getLog(ReaderExcel.class);
public static void main(String[] args) throws IOException { public static void main(String[] args) throws IOException {
System.out.println("https://mp.weixin.qq.com/s?src=11&timestamp=1525385592&ver=855&signature=t61muuTJKorCLU9B6F9khlfr3ezct6GGh-Moxq*9b4RZxgQnHSpElHV9CYCi2YnSA3nOz2*a04k6R9iHOGzctg1KS9Bgx3jelhxEi5NzmXHmhglHbp8Tjf5*rKEFilpi&new=1&key=95dc4253938e3c7ba33e1ff6f7363608ab00e37f99c7f7ff7e7cb4e5b1a6ce70df92e7de80d56d237ffe33cd15ffcb0a80bc0d064ece8d169c6e38960f0d44e359a01cd7bcb987a08b3de1a19e94eb06&uin=NTk1NjM2Nzg3&key=b97b0a94956e0cb2b01167441267dc09f5e79cb852c323792d0040c1988b0c39913e23a2e43b0bccef725d2843e0da0d81c5164338260e6b932f25085936eec21b0e71ca66cd78582d2411b4737cb644&uin=MzM3MTk2NzAxNA%3D%3D".replaceAll("&key=[\\s\\S]+", "")); System.out.println(
"https://mp.weixin.qq.com/s?src=11&timestamp=1525385592&ver=855&signature=t61muuTJKorCLU9B6F9khlfr3ezct6GGh-Moxq*9b4RZxgQnHSpElHV9CYCi2YnSA3nOz2*a04k6R9iHOGzctg1KS9Bgx3jelhxEi5NzmXHmhglHbp8Tjf5*rKEFilpi&new=1&key=95dc4253938e3c7ba33e1ff6f7363608ab00e37f99c7f7ff7e7cb4e5b1a6ce70df92e7de80d56d237ffe33cd15ffcb0a80bc0d064ece8d169c6e38960f0d44e359a01cd7bcb987a08b3de1a19e94eb06&uin=NTk1NjM2Nzg3&key=b97b0a94956e0cb2b01167441267dc09f5e79cb852c323792d0040c1988b0c39913e23a2e43b0bccef725d2843e0da0d81c5164338260e6b932f25085936eec21b0e71ca66cd78582d2411b4737cb644&uin=MzM3MTk2NzAxNA%3D%3D"
.replaceAll("&key=[\\s\\S]+", ""));
} }
...@@ -101,7 +103,7 @@ public class ReaderExcel { ...@@ -101,7 +103,7 @@ public class ReaderExcel {
} }
} }
} }
if (w != null) if (w != null && w.getUrl() != null)
list.add(w); list.add(w);
} }
} }
...@@ -140,6 +142,7 @@ public class ReaderExcel { ...@@ -140,6 +142,7 @@ public class ReaderExcel {
} }
return list; return list;
} }
public static Sheet getSheetByNum(Workbook book, int number) { public static Sheet getSheetByNum(Workbook book, int number) {
Sheet sheet = null; Sheet sheet = null;
try { try {
......
...@@ -17,7 +17,7 @@ import com.zw.entity.NewsResult; ...@@ -17,7 +17,7 @@ import com.zw.entity.NewsResult;
import sendmail.SendMailUtil; import sendmail.SendMailUtil;
@Component //@Component
public class PushFinanceByTimeLess extends Thread { public class PushFinanceByTimeLess extends Thread {
private static final Log log = LogFactory.getLog(PushFinanceByTimeLess.class); private static final Log log = LogFactory.getLog(PushFinanceByTimeLess.class);
private static final MongoConnection con = new MongoConnection(); private static final MongoConnection con = new MongoConnection();
......
...@@ -230,6 +230,7 @@ public class MainController { ...@@ -230,6 +230,7 @@ public class MainController {
excel.setSite(0); excel.setSite(0);
excel.setSurplusCount(list.size()); excel.setSurplusCount(list.size());
excel.setStartDate("未开始"); excel.setStartDate("未开始");
System.out.println(list.size());
lists.add(excel); lists.add(excel);
if (!ExcelReadAndWrite.runStrat) { if (!ExcelReadAndWrite.runStrat) {
Thread t = new Thread() { Thread t = new Thread() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment