code: public String exportQueueToString()
    {
      JSONArray logs = new JSONArray();
      while (!queue.isEmpty())
      {
        logs.add(queue.poll());
      }
      return SecretDetector.maskAWSSecret(logs.toString());
    }
docs: convert a list of json objects to a string
  
  @return the result json string