Uploaded image for project: 'Apache IoTDB'
  1. Apache IoTDB
  2. IOTDB-2018

Query dataset memory leak on server caused by python client

    XMLWordPrintableJSON

Details

    Description

      version: 0.12.2 & 0.13.0-SNAPSHOT
      def close_operation_handle(self) is not worked as expected.
      I'm testing the performance of java client and python client. During the test, I found that Python client will lead to memory leakage of sever, which leads to continuous query performance degradation when using Python client for continuous query operations. 
      My python client test code is:

      for i in range(0, times):
              session_dataset = session.execute_query_statement(sql)
              while session_dataset.has_next():
                  session_dataset.next()
              session_dataset.close_operation_handle()

      My java client test code is:

      for (int i = 0; i < times; i++) {
          SessionDataSet sessionDataSet = session.executeQueryStatement(sql);
          while (sessionDataSet.hasNext()) {
              sessionDataSet.next();
          }
          sessionDataSet.closeOperationHandle();
      }

      After continuous query operation with Python client, the memory usage of the server is:

      2021-11-15 12:26:15,177 [Thread-0] INFO  o.a.i.d.s.IoTDBShutdownHook:33 - IoTDB exits. Jvm memory usage: 1 GB 23 MB 111 KB 888 B 

      After continuous query operation with Java client, the memory usage of the server is:

      2021-11-15 08:38:42,582 [Thread-0] INFO  o.a.i.d.s.IoTDBShutdownHook:33 - IoTDB exits. Jvm memory usage: 0 GB 303 MB 846 KB 952 B 

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              noorall yanglei
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: