Phase de test TCP - envoi OK - historique KO

這個提交存在於:
Nabil Moukhlis 2020-12-08 18:49:33 +01:00
父節點 510e436ca9
當前提交 124735fcc9
共有 3 個檔案被更改,包括 4 行新增3 行删除

未顯示二進位檔案。

未顯示二進位檔案。

查看文件

@ -92,7 +92,7 @@ class RunnerTCPEnvoi implements Runnable {
this.out = new PrintWriter(link.getOutputStream());
this.in = new BufferedReader (new InputStreamReader (link.getInputStream()));
this.bonjourEnvoye = bonjour;
this.run();
//this.run();
}
@Override
public void run() {
@ -145,7 +145,6 @@ class RunnerTCPEcoute implements Runnable {
@Override
public void run() {
System.out.println("Creation d'un thread d'ecoute");
ExecutorService exec = Executors.newFixedThreadPool(1);
try {
PrintStream output = new PrintStream(link.getOutputStream());
//InputStream is = link.getInputStream();
@ -190,7 +189,9 @@ class RunnerTCPEcoute implements Runnable {
System.out.println("Bonjour recu!");
//System.out.println(src.split(":")[1].replaceAll("\n", ""));
u2=Utilisateur.stringToUtilisateur(src.split(":")[1].replaceAll("\n", ""));
exec.submit(new RunnerTCPEnvoi(link,app,u2,true));
Thread t = new Thread(new RunnerTCPEnvoi(link,app,u2,true));
t.start();
System.out.println("Thread d'envoi envoye");
}
type = line+"\n";