title: Jmeter not finishing because of daemon threads
body: <p>I am trying to run a <code>JMX</code> file from non GUI mode on <code>linux</code> server. Using <code>SFTP</code> protocol trying to upload file to object store. Below is the script and configuration used to run the script.</p>
  
  <p><strong>Test.jmx</strong></p>
  
  <pre><code>import com.jcraft.jsch.*;
  import java.io.*;
  
  def jsch = new JSch()
  def session = jsch.getSession("user1", "xyz", 4000) 
  session.setConfig("StrictHostKeyChecking", "no")
  session.setPassword("password")
  def sftpSession = session.connect()
  def channel = session.openChannel("sftp")
  channel.connect();
  def channelSftp = (ChannelSftp)channel;
  log.info("SFTP Connection with host is acquired" + channelSftp)
  channelSftp.cd("/0002/test/upload/r9a1");
  def f1 = new File("/home/dc-user/Files/test_exact5mb.txt");
  channelSftp.put(new java.io.FileInputStream(f1), f1.getName()+ Math.random());
  session.disconnect()
  </code></pre>
  
  <p>Configuration used is 
  No of Threads - 150
  Ramp up period - 1
  Loop Count -1</p>
  
  <p>After running the script, out of 150 files sometimes 126 or 129 or 141 files gets uploaded but not 150.
  Below is the error i see on terminal</p>
  
  <pre><code>The JVM should have exited but did not.
  The following non-daemon threads are still running (DestroyJavaVM is OK):
  Thread[Connect thread 10.157.147.242 session,5,main], stackTrace:java.net.SocketInputStream#socketRead0
  java.net.SocketInputStream#socketRead at line:116
  java.net.SocketInputStream#read at line:171
  java.net.SocketInputStream#read at line:141
  com.jcraft.jsch.IO#getByte at line:82
  com.jcraft.jsch.Session#read at line:908
  com.jcraft.jsch.Session#run at line:1378
  java.lang.Thread#run at line:74
  </code></pre>
  
  <p>Please let me know if i am missing any configuration</p>