text:
package stacks2;

public class Zad2 {
    public static void main(String[] args){
        Stos stos = new Stos();

        stos.dodajNaStos(1);
        stos.dodajNaStos(2);
        stos.dodajNaStos(3);
        stos.dodajNaStos(5);

        try {
            System.out.println(stos.pobierzZeStosu());
            System.out.println(stos.pobierzZeStosu());
            System.out.println(stos.pobierzZeStosu());
            System.out.println(stos.pobierzZeStosu());
            System.out.println(stos.pobierzZeStosu());
        }
        catch(StosPustyException e){
            System.out.println(e.getMessage());
        }
    }
}


text:
package ch.softappeal.yass.tutorial.datagram;

import ch.softappeal.yass.core.remote.Client;
import ch.softappeal.yass.core.remote.MethodMapper;
import ch.softappeal.yass.core.remote.Request;
import ch.softappeal.yass.core.remote.Server;
import ch.softappeal.yass.serialize.Reader;
import ch.softappeal.yass.serialize.Serializer;
import ch.softappeal.yass.serialize.Writer;
import ch.softappeal.yass.transport.SimpleTransportSetup;
import ch.softappeal.yass.util.Check;

import java.net.SocketAddress;
import java.nio.ByteBuffer;
import java.nio.channels.DatagramChannel;

public final class DatagramTransport {

    private DatagramTransport() {
        // disable
    }

    private static void checkOneWay(final MethodMapper.Mapping methodMapping, final Request request) {
        if (!methodMapping.oneWay) {
            throw new IllegalArgumentException(
                "transport not allowed for rpc  method (serviceId " + request.serviceId + ", methodId " + request.methodId + ')'
            );
        }
    }

    public static Client client(final Serializer messageSerializer, final DatagramChannel channel, final SocketAddress target) {
        Check.notNull(messageSerializer);
        Check.notNull(channel);
        Check.notNull(target);
        return new Client() {
            @Override public void invoke(final Invocation invocation) throws Exception {
                invocation.invoke(false, request -> {
                    checkOneWay(invocation.methodMapping, request);
                    final Writer.ByteBufferOutputStream out = new Writer.ByteBufferOutputStream(128);
                    messageSerializer.write(request, Writer.create(out));
                    channel.send(out.toByteBuffer(), target);
                });
            }
        };
    }

    public static void invoke(final SimpleTransportSetup setup, final DatagramChannel channel, final int maxRequestBytes) throws Exception {
        final ByteBuffer in = ByteBuffer.allocate(maxRequestBytes);
        channel.receive(in);
        in.flip();
        final Request request = (Request)setup.messageSerializer.read(Reader.create(in));
        if (in.hasRemaining()) {
            throw new RuntimeException("input buffer is not empty");
        }
        final Server.Invocation invocation = setup.server.invocation(false, request);
        checkOneWay(invocation.methodMapping, request);
        invocation.invoke(reply -> {
        });
    }

}

redpajama_set_name: RedPajamaGithub


text:
rm -f CMakeCache.txt
rm -rf CMakeFiles
rm -f cmake_install.cmake


text:
<!DOCTYPE html>

		<title>three.js webgl - clipping stencil</title>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
		<link type="text/css" rel="stylesheet" href="main.css">

three.js - solid geometry with clip planes and stencil materials


text:
<?xml version='1.0' encoding='UTF-8'?>
<Info location=".emptyfolder" type="File" />


text:
require 'spec_helper'
describe "The CVE-2015-8317 vulnerability" do
	before(:all) do
		@check = Dawn::Kb::CVE_2015_8317.new
		# @check.debug = true
	end
	it "is reported when the vulnerable gem is detected" do
    @check.dependencies = [{:name=>"nokogiri", :version=>"1.6.5"}]
		@check.vuln?.should   == true
	end
	it "is reported when the vulnerable gem is detected" do
    @check.dependencies = [{:name=>"nokogiri", :version=>"1.6.0"}]
		@check.vuln?.should   == true
	end
	it "is reported when the vulnerable gem is detected" do
    @check.dependencies = [{:name=>"nokogiri", :version=>"1.6.7"}]
		@check.vuln?.should   == true
	end
	it "is not reported when a fixed release is detected" do
    @check.dependencies = [{:name=>"nokogiri", :version=>"1.6.7.1"}]
		@check.vuln?.should   == false
	end
	it "is not reported when a fixed release is detected" do
    @check.dependencies = [{:name=>"nokogiri", :version=>"1.5.6"}]
		@check.vuln?.should   == false
	end
	it "is not reported when a fixed release is detected" do
    @check.dependencies = [{:name=>"nokogiri", :version=>"1.4.6"}]
		@check.vuln?.should   == false
	end
end


text:
set -e

TEST_SCRIPTS_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
INSTALLERS_DIR="$TEST_SCRIPTS_DIR/../installers"

# Debian package 64bit
DEB64="${INSTALLERS_DIR}/apacheds-${project.version}-amd64.deb"
DOCKER_CMD="docker run -i --rm -h myhostname -v ${DEB64}:/apacheds.deb -v ${TEST_SCRIPTS_DIR}/deb.test:/deb.test -v ${TEST_SCRIPTS_DIR}/config.ldif:/config.ldif -v ${TEST_SCRIPTS_DIR}/data.ldif:/data.ldif"
if [ -f ${DEB64} ]
then
    echo
    echo
    echo "Testing deb package (Debian 9, OpenJDK 8, 64bit)"
    $DOCKER_CMD debian:9 bash /deb.test

    echo
    echo
    echo "Testing deb package (Ubuntu 18.04, OpenJDK 11, 64bit)"
    $DOCKER_CMD ubuntu:18.04 bash /deb.test

    echo
    echo
    echo "Testing deb package (Ubuntu 20.04, OpenJ9 16, 64bit)"
    $DOCKER_CMD adoptopenjdk/openjdk16-openj9:slim bash -c "ln -s /opt/java/openjdk/bin/java /usr/bin/java; bash /deb.test"
fi


text:
Conditional Exploration
=======================

.. automodule:: chocolate.conditional

.. currentmodule:: chocolate

.. autoclass:: ThompsonSampling

   .. automethod:: ThompsonSampling.next

   .. automethod:: ThompsonSampling.update


text:
static inline bool simdDecodeAscii (ushort *& dst, const uchar *& nextAscii, const uchar *& src, const uchar * end)
{
	// do sixteen characters at a time
	for ( ; end - src >= 16; src += 16, dst += 16) {
		__m128i data = _mm_loadu_si128((__m128i*)src);

#ifdef __AVX2__
		const int BitSpacing = 2;
		// load and zero extend to an YMM register
		const __m256i extended = _mm256_cvtepu8_epi16(data);

		uint n = _mm256_movemask_epi8(extended);
		if (!n) {
			// store
			_mm256_storeu_si256((__m256i*)dst, extended);
			continue;
		}
#else
		const int BitSpacing = 1;

		// check if everything is ASCII
		// movemask extracts the high bit of every byte, so n is non-zero if something isn't ASCII
		uint n = _mm_movemask_epi8(data);
		if (!n) {
			// unpack
			_mm_storeu_si128((__m128i*)dst, _mm_unpacklo_epi8(data, _mm_setzero_si128()));
			_mm_storeu_si128(1+(__m128i*)dst, _mm_unpackhi_epi8(data, _mm_setzero_si128()));
			continue;
		}
#endif

		// copy the front part that is still ASCII
		while (!(n & 1)) {
			*dst++ = *src++;
			n >>= BitSpacing;
		}

		// find the next probable ASCII character
		// we don't want to load 16 bytes again in this loop if we know there are non-ASCII
		// characters still coming
		n = _bit_scan_reverse(n);
		nextAscii = src + (n / BitSpacing) + 1;
		return false;

	}
	return src == end;
}

inline size_t convertToUnicodeFromUtf8 (const char * chars, size_t len, wchar_t * dest, size_t dest_sz)
{
	// UTF-8 to UTF-16 always needs the exact same number of words or less:
	//	  UTF-8		UTF-16
	//	 1 byte		1 word
	//	 2 bytes	1 word
	//	 3 bytes	1 word
	//	 4 bytes	2 words (one surrogate pair)
	// That is, we'll use the full buffer if the input is US-ASCII (1-byte UTF-8),
	// half the buffer for U+0080-U+07FF text (e.g., Greek, Cyrillic, Arabic) or
	// non-BMP text, and one third of the buffer for U+0800-U+FFFF text (e.g, CJK).
	//
	// The table holds for invalid sequences too: we'll insert one replacement char
	// per invalid byte.
	//QString result(len, Qt::Uninitialized);
	//extern const uchar * utf8bom;
	const uchar utf8bom[] = { 0xef, 0xbb, 0xbf };

	static_assert(sizeof(ushort) == sizeof(wchar_t), "ee");
	ushort * dst = reinterpret_cast<ushort *>(dest);
	const uchar * src = reinterpret_cast<const uchar *>(chars);
	const uchar * end = src + len;

	// attempt to do a full decoding in SIMD
	const uchar * nextAscii = end;
	if (!simdDecodeAscii(dst, nextAscii, src, end))
	{
		// at least one non-ASCII entry
		// check if we failed to decode the UTF-8 BOM; if so, skip it
		if (Q_UNLIKELY(src == reinterpret_cast<const uchar *>(chars))
				&& end - src >= 3
				&& Q_UNLIKELY(src[0] == utf8bom[0] && src[1] == utf8bom[1] && src[2] == utf8bom[2])) {
			src += 3;
		}

		while (src < end) {
			nextAscii = end;
			if (simdDecodeAscii(dst, nextAscii, src, end))
				break;

			do {
				uchar b = *src++;
				int res = QUtf8Functions::fromUtf8<QUtf8BaseTraits>(b, dst, src, end);
				if (res < 0) {
					// decoding error
					*dst++ = QChar::ReplacementCharacter;
				}
			} while (src < nextAscii);
		}
	}

	size_t const n = dst - reinterpret_cast<ushort *>(dest);
	return n;
}


text:
<?php

namespace Symfony\Component\CssSelector\Tests\Node;

use Symfony\Component\CssSelector\Node\ElementNode;

class ElementNodeTest extends AbstractNodeTest
{
    public function getToStringConversionTestData()
    {
        return array(
            array(new ElementNode(), 'Element[*]'),
            array(new ElementNode(null, 'element'), 'Element[element]'),
            array(new ElementNode('namespace', 'element'), 'Element[namespace|element]'),
        );
    }

    public function getSpecificityValueTestData()
    {
        return array(
            array(new ElementNode(), 0),
            array(new ElementNode(null, 'element'), 1),
            array(new ElementNode('namespace', 'element'), 1),
        );
    }
}


text:
@import url("{{ pathto('_static/fontawesome/css/fa-brands.min.css', 1) }}");

.console-block {
  text-align: right;
}

.console-block *:before,
.console-block *:after {
  box-sizing: border-box;
}

.console-block > section {
  display: none;
  text-align: left;
}

.console-block > input.c-tab-unix,
.console-block > input.c-tab-win {
  display: none;
}

.console-block > label {
  display: inline-block;
  padding: 4px 8px;
  font-weight: normal;
  text-align: center;
  color: #bbb;
  border: 1px solid transparent;
  font-family: fontawesome;
}

.console-block > input:checked + label {
  color: #555;
  border: 1px solid #ddd;
  border-top: 2px solid #ab5603;
  border-bottom: 1px solid #fff;
}

.console-block > .c-tab-unix:checked ~ .c-content-unix,
.console-block > .c-tab-win:checked  ~ .c-content-win {
  display: block;
}

.console-block pre {
  margin-top: 0px;
}


text:
import numpy as np

def melcd(array1, array2):
    """Calculate mel-cepstrum distortion

    Calculate mel-cepstrum distortion between the arrays.
    This function assumes the shapes of arrays are same.

    Parameters
    ----------
    array1, array2 : array, shape (`T`, `dim`) or shape (`dim`)
        Arrays of original and target.

    Returns
    -------
    mcd : scala, number > 0
        Scala of mel-cepstrum distortion

    """
    if array1.shape != array2.shape:
        raise ValueError(
            "The shapes of both arrays are different \
            : {} / {}".format(array1.shape, array2.shape))

    if array1.ndim == 2:
        # array based melcd calculation
        diff = array1 - array2
        mcd = 10.0 / np.log(10) \
            * np.mean(np.sqrt(2.0 * np.sum(diff ** 2, axis=1)))
    elif array1.ndim == 1:
        diff = array1 - array2
        mcd = 10.0 / np.log(10) * np.sqrt(2.0 * np.sum(diff ** 2))
    else:
        raise ValueError("Dimension mismatch")

    return mcd


text:
This document summarizes supported data formats and iterator APIs to read the
data including

```eval_rst
.. autosummary::
    :nosignatures:

    mxnet.io
    mxnet.recordio
    mxnet.image
```

First, let's see how to write an iterator for a new data format.
The following iterator can be used to train a symbol whose input data variable has
name `data` and input label variable has name `softmax_label`.
The iterator also provides information about the batch, including the
shapes and name.

```python
>>> nd_iter = mx.io.NDArrayIter(data={'data':mx.nd.ones((100,10))},
...                             label={'softmax_label':mx.nd.ones((100,))},
...                             batch_size=25)
>>> print(nd_iter.provide_data)
[DataDesc[data,(25, 10L),<type 'numpy.float32'>,NCHW]]
>>> print(nd_iter.provide_label)
[DataDesc[softmax_label,(25,),<type 'numpy.float32'>,NCHW]]
```

Let's see a complete example of how to use data iterator in model training.
```python
>>> data = mx.sym.Variable('data')
>>> label = mx.sym.Variable('softmax_label')
>>> fullc = mx.sym.FullyConnected(data=data, num_hidden=1)
>>> loss = mx.sym.SoftmaxOutput(data=data, label=label)
>>> mod = mx.mod.Module(loss, data_names=['data'], label_names=['softmax_label'])
>>> mod.bind(data_shapes=nd_iter.provide_data, label_shapes=nd_iter.provide_label)
>>> mod.fit(nd_iter, num_epoch=2)
```

A detailed tutorial is available at
[Iterators - Loading data](http://mxnet.io/tutorials/basic/data.html).

## Data iterators

```eval_rst
    .. currentmodule:: mxnet
```

```eval_rst
.. autosummary::
    :nosignatures:

    io.NDArrayIter
    io.CSVIter
    io.ImageRecordIter
    io.ImageRecordUInt8Iter
    io.MNISTIter
    recordio.MXRecordIO
    recordio.MXIndexedRecordIO
    image.ImageIter
    image.ImageDetIter
```

## Helper classes and functions

Data structures and other iterators provided in the ``mxnet.io`` packages.

```eval_rst
.. autosummary::
    :nosignatures:

    io.DataDesc
    io.DataBatch
    io.DataIter
    io.ResizeIter
    io.PrefetchingIter
    io.MXDataIter
```

Functions to read and write RecordIO files.

```eval_rst
.. autosummary::
    :nosignatures:

    recordio.pack
    recordio.unpack
    recordio.unpack_img
    recordio.pack_img
```

## Develop a new iterator

Writing a new data iterator in Python is straightforward. Most MXNet
training/inference programs accept an iterable object with ``provide_data``
and ``provide_label`` properties.
This [tutorial](http://mxnet.io/tutorials/basic/data.html) explains how to
write an iterator from scratch.

The following example demonstrates how to combine
multiple data iterators into a single one. It can be used for multiple
modality training such as image captioning, in which images are read by
``ImageRecordIter`` while documents are read by ``CSVIter``

```python
class MultiIter:
    def __init__(self, iter_list):
        self.iters = iter_list
    def next(self):
        batches = [i.next() for i in self.iters]
        return DataBatch(data=[*b.data for b in batches],
                         label=[*b.label for b in batches])
    def reset(self):
        for i in self.iters:
            i.reset()
    @property
    def provide_data(self):
        return [*i.provide_data for i in self.iters]
    @property
    def provide_label(self):
        return [*i.provide_label for i in self.iters]

iter = MultiIter([mx.io.ImageRecordIter('image.rec'), mx.io.CSVIter('txt.csv')])
```

Parsing and performing another pre-processing such as augmentation may be expensive.
If performance is critical, we can implement a data iterator in C++. Refer to
[src/io](https://github.com/dmlc/mxnet/tree/master/src/io) for examples.

### Change batch layout

By default, the backend engine treats the first dimension of each data and label variable in data
iterators as the batch size (i.e. `NCHW` or `NT` layout). In order to override the axis for batch size,
the `provide_data` (and `provide_label` if there is label) properties should include the layouts. This
is especially useful in RNN since `TNC` layouts are often more efficient. For example:

```python
@property
def provide_data(self):
    return [DataDesc(name='seq_var', shape=(seq_length, batch_size), layout='TN')]
```
The backend engine will recognize the index of `N` in the `layout` as the axis for batch size.

## API Reference

<script type="text/javascript" src='../../_static/js/auto_module_index.js'></script>

```eval_rst
.. automodule:: mxnet.io
    :members:
.. automodule:: mxnet.recordio
    :members:
```
<script>auto_index("api-reference");</script>


text:
<?xml version="1.0" encoding="UTF-8" ?>

<container xmlns="http://symfony.com/schema/dic/services"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd"
>
    <parameters>
        <parameter key="fungio_google_map.directions.class">Fungio\GoogleMap\Services\Directions\Directions</parameter>
        <parameter key="fungio_google_map.directions_request.class">Fungio\GoogleMap\Services\Directions\DirectionsRequest</parameter>
        <parameter key="fungio_google_map.directions_request.builder.class">Fungio\GoogleMapBundle\Model\Services\Directions\DirectionsRequestBuilder</parameter>
    </parameters>

    <services>
        <service id="fungio_google_map.directions" class="%fungio_google_map.directions.class%" />

        <service
            id="fungio_google_map.directions_request"
            class="%fungio_google_map.directions_request.class%"
            shared="false">
            <factory service="fungio_google_map.directions_request.builder" method="build" />
        </service>

        <service
            id="fungio_google_map.directions_request.builder"
            class="%fungio_google_map.directions_request.builder.class%"
        >
            <argument>%fungio_google_map.directions_request.class%</argument>
        </service>
    </services>
</container>


text:
package com.netflix.spinnaker.front50.controllers;

import static com.netflix.spinnaker.front50.model.pipeline.Pipeline.TYPE_TEMPLATED;
import static com.netflix.spinnaker.front50.model.pipeline.TemplateConfiguration.TemplateSource.SPINNAKER_PREFIX;

import com.fasterxml.jackson.databind.ObjectMapper;
import com.google.common.annotations.VisibleForTesting;
import com.netflix.spinnaker.front50.exception.BadRequestException;
import com.netflix.spinnaker.front50.exception.NotFoundException;
import com.netflix.spinnaker.front50.exceptions.DuplicateEntityException;
import com.netflix.spinnaker.front50.exceptions.InvalidRequestException;
import com.netflix.spinnaker.front50.model.pipeline.Pipeline;
import com.netflix.spinnaker.front50.model.pipeline.PipelineDAO;
import com.netflix.spinnaker.front50.model.pipeline.PipelineTemplate;
import com.netflix.spinnaker.front50.model.pipeline.PipelineTemplateDAO;
import com.netflix.spinnaker.front50.model.pipeline.TemplateConfiguration;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import java.util.Optional;
import java.util.stream.Collectors;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("pipelineTemplates")
public class PipelineTemplateController {

  @Autowired(required = false)
  PipelineTemplateDAO pipelineTemplateDAO = null;

  @Autowired PipelineDAO pipelineDAO;

  @Autowired ObjectMapper objectMapper;

  // TODO rz - Add fiat authz

  @RequestMapping(value = "", method = RequestMethod.GET)
  List<PipelineTemplate> list(
      @RequestParam(required = false, value = "scopes") List<String> scopes) {
    return (List<PipelineTemplate>) getPipelineTemplateDAO().getPipelineTemplatesByScope(scopes);
  }

  @RequestMapping(value = "", method = RequestMethod.POST)
  void save(@RequestBody PipelineTemplate pipelineTemplate) {
    checkForDuplicatePipelineTemplate(pipelineTemplate.getId());
    getPipelineTemplateDAO().create(pipelineTemplate.getId(), pipelineTemplate);
  }

  @RequestMapping(value = "{id}", method = RequestMethod.GET)
  PipelineTemplate get(@PathVariable String id) {
    return getPipelineTemplateDAO().findById(id);
  }

  @RequestMapping(value = "{id}", method = RequestMethod.PUT)
  PipelineTemplate update(@PathVariable String id, @RequestBody PipelineTemplate pipelineTemplate) {
    PipelineTemplate existingPipelineTemplate = getPipelineTemplateDAO().findById(id);
    if (!pipelineTemplate.getId().equals(existingPipelineTemplate.getId())) {
      throw new InvalidRequestException(
          "The provided id "
              + id
              + " doesn't match the pipeline template id "
              + pipelineTemplate.getId());
    }

    pipelineTemplate.setLastModified(System.currentTimeMillis());
    getPipelineTemplateDAO().update(id, pipelineTemplate);

    return pipelineTemplate;
  }

  @RequestMapping(value = "{id}", method = RequestMethod.DELETE)
  void delete(@PathVariable String id) {
    checkForDependentConfigs(id, true);
    checkForDependentTemplates(id);
    getPipelineTemplateDAO().delete(id);
  }

  @RequestMapping(value = "{id}/dependentPipelines", method = RequestMethod.GET)
  List<Pipeline> listDependentPipelines(
      @PathVariable String id,
      @RequestParam(required = false, value = "recursive", defaultValue = "false")
          boolean recursive) {
    List<String> dependentConfigsIds = getDependentConfigs(id, recursive);

    return pipelineDAO.all().stream()
        .filter(pipeline -> dependentConfigsIds.contains(pipeline.getId()))
        .collect(Collectors.toList());
  }

  @VisibleForTesting
  List<String> getDependentConfigs(String templateId, boolean recursive) {
    List<String> dependentConfigIds = new ArrayList<>();

    List<String> templateIds = convertAllTemplateIdsToSources(templateId, recursive);

    pipelineDAO.all().stream()
        .filter(pipeline -> pipeline.getType() != null && pipeline.getType().equals(TYPE_TEMPLATED))
        .forEach(
            templatedPipeline -> {
              String source;
              try {
                TemplateConfiguration config =
                    objectMapper.convertValue(
                        templatedPipeline.getConfig(), TemplateConfiguration.class);

                source = config.getPipeline().getTemplate().getSource();
              } catch (Exception e) {
                return;
              }

              if (source != null && containsAnyIgnoreCase(source, templateIds)) {
                dependentConfigIds.add(templatedPipeline.getId());
              }
            });
    return dependentConfigIds;
  }

  private List<String> convertAllTemplateIdsToSources(String rootTemplateId, boolean recursive) {
    List<String> templateIds = new ArrayList<>();
    templateIds.add(SPINNAKER_PREFIX + rootTemplateId);
    if (recursive) {
      for (String id : getDependentTemplates(rootTemplateId, Optional.empty())) {
        templateIds.add(SPINNAKER_PREFIX + id);
      }
    }
    return templateIds;
  }

  private static boolean containsAnyIgnoreCase(String source, List<String> templateIds) {
    for (String templateId : templateIds) {
      if (source.equalsIgnoreCase(templateId)) {
        return true;
      }
    }
    return false;
  }

  @VisibleForTesting
  void checkForDependentConfigs(String templateId, boolean recursive) {
    List<String> dependentConfigIds = getDependentConfigs(templateId, recursive);
    if (dependentConfigIds.size() != 0) {
      throw new InvalidRequestException(
          "The following pipeline configs"
              + " depend on this template: "
              + String.join(", ", dependentConfigIds));
    }
  }

  @VisibleForTesting
  List<String> getDependentTemplates(
      String templateId, Optional<Collection<PipelineTemplate>> templates) {
    List<String> dependentTemplateIds = new ArrayList<>();

    final Collection<PipelineTemplate> pipelineTemplates =
        templates.orElse(getPipelineTemplateDAO().all());
    pipelineTemplates.forEach(
        template -> {
          if (template.getSource() != null
              && template.getSource().equalsIgnoreCase(SPINNAKER_PREFIX + templateId)) {
            dependentTemplateIds.add(template.getId());
            dependentTemplateIds.addAll(
                getDependentTemplates(template.getId(), Optional.of(pipelineTemplates)));
          }
        });
    return dependentTemplateIds;
  }

  @VisibleForTesting
  void checkForDependentTemplates(String templateId) {
    List<String> dependentTemplateIds = getDependentTemplates(templateId, Optional.empty());
    if (dependentTemplateIds.size() != 0) {
      throw new InvalidRequestException(
          "The following pipeline templates"
              + " depend on this template: "
              + String.join(", ", dependentTemplateIds));
    }
  }

  private void checkForDuplicatePipelineTemplate(String id) {
    try {
      getPipelineTemplateDAO().findById(id);
    } catch (NotFoundException e) {
      return;
    }
    throw new DuplicateEntityException("A pipeline template with the id " + id + " already exists");
  }

  private PipelineTemplateDAO getPipelineTemplateDAO() {
    if (pipelineTemplateDAO == null) {
      throw new BadRequestException(
          "Pipeline Templates are not supported with your current storage backend");
    }
    return pipelineTemplateDAO;
  }
}


text:
export const DATASETS_STORAGE_PATH_PREFIX = 'datasets';
export const ELEMENT_PROPS_DATASET_KEY = 'cd-element-props';
export const DATASET_SIZE_LIMIT_ERROR = 'Dataset size limit exceeded. Limit is 512 KB';

// TODO: increase limit once data-tree can handle it
export const DATASET_SIZE_LIMIT = 512000; // 512 KB

export const DATA_CHIP_TAG = 'cd-data-chip';
export const DATA_CHIP_SOURCE_ATTR = 'source';
export const DATA_CHIP_LOOKUP_ATTR = 'lookup';

export const DATASET_DELIMITER = '.';


text:
package controllers;

import models.User;
import play.Logger;
import play.mvc.Controller;

import com.elevenpaths.latch.Latch;
import com.elevenpaths.latch.LatchResponse;

public class Application extends Controller {

	private static final String LATCH_APP_ID = "YOUR_APP_ID";
	private static final String LATCH_OP_EDIT_PROFILE = "YOUR_LOGIN_OPERATION_ID";
	private static final String LATCH_OP_LOGIN = "YOUR_EDIT_PROFILE_OPERATION_ID";
	private static final String LATCH_SECRET = "YOUR_APP_SECRET";

    public static void index() {
        render();
    }

    public static void registration() {
        render();
    }

    public static void logout() {
    	session.remove("username");
    	index();
    }

    public static void doRegister(String username, String password, String color, String phone){
    	User user = new User(username, password, color, phone);
    	user.save();
    	session.put("username", username);
    	profile();
    }

    public static void profile() {
    	if (session.contains("username")){
    		String username = session.get("username");
    		User user = User.load(username);
    		render(username, user);
    	}else{
    		index();
    	}
    }

    public static void latch(){
    	User user = User.load(session.get("username"));
    	if (user.getAccountId().isEmpty()){
    		render("Latch/pair.html");
    	}else{
    		render("Latch/unpair.html");
    	}
    }

    private static void invalidCredentials(){
    	flash.put("errorCredentials", true);
		index();
    }

    public static void doLogin(String username, String password){
    	boolean authOk = User.authenticate(username, password);
    	if (authOk){

    		User user = User.load(username);
    		boolean isLoginAllowed = checkLatchStatus(user, LATCH_OP_LOGIN);

    		if(isLoginAllowed){
	    		session.put("username", username);
	    		profile();
    		}else{
    			invalidCredentials();
    		}
    	}else{
    		invalidCredentials();
    	}
    }

    public static void editProfile(String color, String phone){
    	User user = User.load(session.get("username"));
    	boolean isEditAllowed = checkLatchStatus(user, LATCH_OP_EDIT_PROFILE);
    	if (isEditAllowed){
	    	user.setColor(color);
	    	user.setPhone(phone);
	    	user.save();
	    	flash.put("editOk", true);
    	}else{
    		flash.put("editFail", true);
    	}
    	profile();
    }

    private static boolean checkLatchStatus(User user, String operationId){
    	boolean isAllowed = true;
    	String accountId = user.getAccountId();
    	if (!accountId.isEmpty()){
			Latch latch = new Latch(LATCH_APP_ID,LATCH_SECRET);
	    	LatchResponse latchResponse = latch.operationStatus(accountId, operationId);
	    	if (latchResponse != null && latchResponse.getData() != null){
	    		String status = latchResponse.getData().get("operations").getAsJsonObject().get(operationId).getAsJsonObject().get("status").getAsString();
	    		if(status.equals("off")){
	    			isAllowed = false;
	    		}
	    	}
		}
    	return isAllowed;
    }

    public static void pair(String token){
    	Latch latch = new Latch(LATCH_APP_ID,LATCH_SECRET);
    	LatchResponse latchResponse = latch.pair(token);

    	if (latchResponse != null){
    		String json = latchResponse.toJSON().toString();
        	flash.put("json", json);
    		if (latchResponse.getData() != null){
    			String accountId = latchResponse.getData().get("accountId").getAsString();
	    		User user = User.load(session.get("username"));
	    		user.setAccountId(accountId);
	    		user.save();
	    		flash.put("pairOk", true);
    		}else{
        		flash.put("pairFail", true);
        	}
    	}

    	latch();
    }

    public static void unpair(){
    	User user = User.load(session.get("username"));
    	Latch latch = new Latch(LATCH_APP_ID,LATCH_SECRET);
    	LatchResponse latchResponse = latch.unpair(user.getAccountId());
    	if (latchResponse != null && latchResponse.getError() == null){
    		String json = latchResponse.toJSON().toString();
    		flash.put("json", json);

    		user.setAccountId("");
    		user.save();
    		flash.put("unpairOk", true);
    	}else{
    		flash.put("unpairFail", true);
    	}

    	latch();
    }
}


text:
#include "xenia/ui/win32/win32_menu_item.h"

#include "xenia/base/assert.h"

namespace xe {
namespace ui {
namespace win32 {

Win32MenuItem::Win32MenuItem(Type type, int id, const std::wstring& text)
    : id_(id), MenuItem(type, text) {
  switch (type) {
    case MenuItem::Type::kNormal:
      handle_ = CreateMenu();
      break;
    case MenuItem::Type::kPopup:
      handle_ = CreatePopupMenu();
      break;
  }
}

Win32MenuItem::Win32MenuItem(Type type) : Win32MenuItem(type, 0, L"") {}

Win32MenuItem::Win32MenuItem(Type type, const std::wstring& text)
    : Win32MenuItem(type, 0, text) {}

Win32MenuItem::~Win32MenuItem() {
  if (handle_) {
    DestroyMenu(handle_);
  }
}

void Win32MenuItem::OnChildAdded(MenuItem* generic_child_item) {
  auto child_item = static_cast<Win32MenuItem*>(generic_child_item);

  switch (child_item->type()) {
    case MenuItem::Type::kPopup:
      AppendMenuW(handle_, MF_POPUP,
                  reinterpret_cast<UINT_PTR>(child_item->handle()),
                  child_item->text().c_str());
      break;
    case MenuItem::Type::kSeparator:
      AppendMenuW(handle_, MF_SEPARATOR, child_item->id(), 0);
      break;
    case MenuItem::Type::kString:
      AppendMenuW(handle_, MF_STRING, child_item->id(),
                  child_item->text().c_str());
      break;
  }
}

void Win32MenuItem::OnChildRemoved(MenuItem* generic_child_item) {
  auto child_item = static_cast<Win32MenuItem*>(generic_child_item);
  //
}

}  // namespace win32
}  // namespace ui
}  // namespace xe


text:
namespace ql {
	struct light_source {
		reg_ptr reg;

		id id;

		//! How brightly this light source shines.
		lum luminance;

		//! The distance this light source's light reaches.
		auto range() const -> pace;

		//! How brightly this light source shines at @p target_location.
		auto luminance_at(location target_location) const -> lum;
	};
}


text:
        <button type="button" class="close" data-dismiss="modal" aria-label="Close">×</button>

Confirmation

{{$ctrl.tx}}

                <tag-transaction d="$ctrl.tx" tooltip-position="'left'"></tag-transaction>

        <button type="submit" class="btn btn-success" data-dismiss="modal">{{ 'GENERAL_CLOSE' | translate }}</button>


text:
<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>Trips 2014</title>
    <meta name="description" content="">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="shortcut icon" href="content/img/favicon.ico"/>

    <link href="content/loading-bar.css" rel="stylesheet" />
    <link href="content/app.css" rel="stylesheet" />


text:
package org.apache.flink.contrib.streaming.state;

import org.apache.flink.api.common.typeutils.base.IntSerializer;
import org.apache.flink.api.common.typeutils.base.StringSerializer;
import org.apache.flink.core.memory.ByteArrayInputStreamWithPos;
import org.apache.flink.core.memory.ByteArrayOutputStreamWithPos;
import org.apache.flink.core.memory.DataInputViewStreamWrapper;
import org.apache.flink.core.memory.DataOutputView;
import org.apache.flink.core.memory.DataOutputViewStreamWrapper;

import org.junit.Assert;
import org.junit.Test;

/**
 * Tests for guarding {@link RocksDBKeySerializationUtils}.
 */
public class RocksDBKeySerializationUtilsTest {

	@Test
	public void testIsAmbiguousKeyPossible() {
		Assert.assertFalse(RocksDBKeySerializationUtils.isAmbiguousKeyPossible(
			IntSerializer.INSTANCE, StringSerializer.INSTANCE));

		Assert.assertTrue(RocksDBKeySerializationUtils.isAmbiguousKeyPossible(
			StringSerializer.INSTANCE, StringSerializer.INSTANCE));
	}

	@Test
	public void testKeyGroupSerializationAndDeserialization() throws Exception {
		ByteArrayOutputStreamWithPos outputStream = new ByteArrayOutputStreamWithPos(8);
		DataOutputView outputView = new DataOutputViewStreamWrapper(outputStream);

		for (int keyGroupPrefixBytes = 1; keyGroupPrefixBytes <= 2; ++keyGroupPrefixBytes) {
			for (int orgKeyGroup = 0; orgKeyGroup < 128; ++orgKeyGroup) {
				outputStream.reset();
				RocksDBKeySerializationUtils.writeKeyGroup(orgKeyGroup, keyGroupPrefixBytes, outputView);
				int deserializedKeyGroup = RocksDBKeySerializationUtils.readKeyGroup(
					keyGroupPrefixBytes,
					new DataInputViewStreamWrapper(new ByteArrayInputStreamWithPos(outputStream.toByteArray())));
				Assert.assertEquals(orgKeyGroup, deserializedKeyGroup);
			}
		}
	}

	@Test
	public void testKeySerializationAndDeserialization() throws Exception {
		ByteArrayOutputStreamWithPos outputStream = new ByteArrayOutputStreamWithPos(8);
		DataOutputView outputView = new DataOutputViewStreamWrapper(outputStream);

		// test for key
		for (int orgKey = 0; orgKey < 100; ++orgKey) {
			outputStream.reset();
			RocksDBKeySerializationUtils.writeKey(orgKey, IntSerializer.INSTANCE, outputStream, outputView, false);
			ByteArrayInputStreamWithPos inputStream = new ByteArrayInputStreamWithPos(outputStream.toByteArray());
			int deserializedKey = RocksDBKeySerializationUtils.readKey(IntSerializer.INSTANCE, inputStream, new DataInputViewStreamWrapper(inputStream), false);
			Assert.assertEquals(orgKey, deserializedKey);

			RocksDBKeySerializationUtils.writeKey(orgKey, IntSerializer.INSTANCE, outputStream, outputView, true);
			inputStream = new ByteArrayInputStreamWithPos(outputStream.toByteArray());
			deserializedKey = RocksDBKeySerializationUtils.readKey(IntSerializer.INSTANCE, inputStream, new DataInputViewStreamWrapper(inputStream), true);
			Assert.assertEquals(orgKey, deserializedKey);
		}
	}

	@Test
	public void testNamespaceSerializationAndDeserialization() throws Exception {
		ByteArrayOutputStreamWithPos outputStream = new ByteArrayOutputStreamWithPos(8);
		DataOutputView outputView = new DataOutputViewStreamWrapper(outputStream);

		for (int orgNamespace = 0; orgNamespace < 100; ++orgNamespace) {
			outputStream.reset();
			RocksDBKeySerializationUtils.writeNameSpace(orgNamespace, IntSerializer.INSTANCE, outputStream, outputView, false);
			ByteArrayInputStreamWithPos inputStream = new ByteArrayInputStreamWithPos(outputStream.toByteArray());
			int deserializedNamepsace = RocksDBKeySerializationUtils.readNamespace(IntSerializer.INSTANCE, inputStream, new DataInputViewStreamWrapper(inputStream), false);
			Assert.assertEquals(orgNamespace, deserializedNamepsace);

			RocksDBKeySerializationUtils.writeNameSpace(orgNamespace, IntSerializer.INSTANCE, outputStream, outputView, true);
			inputStream = new ByteArrayInputStreamWithPos(outputStream.toByteArray());
			deserializedNamepsace = RocksDBKeySerializationUtils.readNamespace(IntSerializer.INSTANCE, inputStream, new DataInputViewStreamWrapper(inputStream), true);
			Assert.assertEquals(orgNamespace, deserializedNamepsace);
		}
	}
}


text:
// Copyright (c) Christof Senn. All rights reserved. See license.txt in the project root for license information.

namespace Common.Model
{
    public class OrderItem
    {
        public int Id { get; set; }

        public int ProductId { get; set; }

        public int Quantity { get; set; }
    }
}


text:
#ifndef _XN_OSLINUX_X86_H_
#define _XN_OSLINUX_X86_H_

//---------------------------------------------------------------------------
// Includes
//---------------------------------------------------------------------------
#include <sys/types.h>
#include <stdarg.h>
#include <time.h>
#include <stdio.h>

//---------------------------------------------------------------------------
// Files
//---------------------------------------------------------------------------
/** A generic handle type. */
typedef	void* XN_HANDLE;

/** A file handle type. */
typedef FILE* XN_FILE_HANDLE;

/** The value of an invalid file handle. */
#define XN_INVALID_FILE_HANDLE NULL

/** A string that specifies the current directory. */
#define XN_FILE_LOCAL_DIR "./"

/** The file directory separator. */
#define XN_FILE_DIR_SEP "/"

/** The file extension separator. */
#define XN_FILE_EXT_SEP "."

/** The file "all" wildcard. */
#define XN_FILE_ALL_WILDCARD "*"

/** The newline separation string. */
#define XN_NEW_LINE_SEP "\n"

//---------------------------------------------------------------------------
// INI Files
//---------------------------------------------------------------------------
/** A string that specifies the extension of INI files. */
#define XN_INI_FILE_EXT "ini"

/** The maximum allowed INI string length (in bytes). */
// Note: This must always be big enough to contain a 32-bit number!
#define XN_INI_MAX_LEN 256

//---------------------------------------------------------------------------
// Shared Libraries
//---------------------------------------------------------------------------
/** A shared library handle type. */
typedef	void* XN_LIB_HANDLE;

/** A string that specifies the prefix of shared library files. */
#define XN_SHARED_LIBRARY_PREFIX "lib"

/** A string that specifies the postfix of shared library files. */
#define XN_SHARED_LIBRARY_POSTFIX ".so"

//---------------------------------------------------------------------------
// Threads
//---------------------------------------------------------------------------
/** A Xiron thread type. */
typedef	int XN_THREAD_HANDLE;

/** A Xiron thread ID. */
typedef	int XN_THREAD_ID;

/** A Xiron process ID. */
typedef int XN_PROCESS_ID;

/** The thread entry point function prototype. */
typedef void* (*XN_THREAD_PROC_PROTO)(void* arg);

/** The thread entry point function definition. */
#define	XN_THREAD_PROC void*

/** The thread return function. */
#define	XN_THREAD_PROC_RETURN(ret) return((void*)ret)

/** The thread passable data pointer type. */
typedef	void* XN_THREAD_PARAM;

//---------------------------------------------------------------------------
// Time Outs
//---------------------------------------------------------------------------
/** The mutex lock infinite timeout. */
#define	XN_WAIT_INFINITE 0xFFFFFFFF

//---------------------------------------------------------------------------
// Mutex
//---------------------------------------------------------------------------
/** A Xiron mutex type. */
struct XnMutex;
typedef	struct XnMutex* XN_MUTEX_HANDLE;

//---------------------------------------------------------------------------
// Critical Sections
//---------------------------------------------------------------------------
/** A Xiron critical sections type. */
typedef	XN_MUTEX_HANDLE XN_CRITICAL_SECTION_HANDLE;

//---------------------------------------------------------------------------
// Events
//---------------------------------------------------------------------------
/** A Xiron event type. */
struct _XnEvent;
typedef struct _XnEvent *XN_EVENT_HANDLE;

//---------------------------------------------------------------------------
// Semaphores
//---------------------------------------------------------------------------
/** A Xiron event type. */
struct _XnSemaphore;
typedef struct _XnSemaphore *XN_SEMAPHORE_HANDLE;

//---------------------------------------------------------------------------
// Timer
//---------------------------------------------------------------------------
/** The Xiron OS timer structure. */
typedef struct XnOSTimer
{
	XnUInt64 nStartTick;
} XnOSTimer;

//---------------------------------------------------------------------------
// Network
//---------------------------------------------------------------------------
/** The network host name and port separator. */
#define XN_NETWORK_HOST_PORT_SEP ":"

//---------------------------------------------------------------------------
// Swaps
//---------------------------------------------------------------------------
#define XN_PREPARE_VAR16_IN_BUFFER(var) (var)
#define XN_PREPARE_VAR32_IN_BUFFER(var) (var)
#define XN_PREPARE_VAR64_IN_BUFFER(var) (var)
#define XN_PREPARE_VAR_FLOAT_IN_BUFFER(var) (var)

#define XN_IMPLEMENT_OS \
	printf("Not Implemented: %s at %s(%u)\n", __FUNCTION__, __FILE__, __LINE__); \
	_brk();

#endif //_XN_OSLINUX_X86_H_


text:
<?xml version="1.0"?>
<!--
  ~ Copyright 2019 ThoughtWorks, Inc.
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~     http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  -->

<!DOCTYPE hibernate-mapping PUBLIC
        "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
        "http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">

<hibernate-mapping package="com.thoughtworks.go.domain" default-access="field" default-lazy="false">
    <class name="com.thoughtworks.go.domain.EnvironmentVariable" table="environmentVariables">
        <cache usage="read-write"/>
        <id name="id" column="id">
            <generator class="identity"/>
        </id>

        <property name="name" column="variableName" />
        <property name="isSecure"/>
        <property name="entityId"/>
        <property name="entityType"/>
        <property name="value" access="property" column="variableValue"/>
    </class>
</hibernate-mapping>


text:
**Namespace:** [OfficeDevPnP.Core.Framework.Provisioning.Providers.Xml.V201705](OfficeDevPnP.Core.Framework.Provisioning.Providers.Xml.V201705.md)
**Assembly:** OfficeDevPnP.Core.dll
## Syntax
```C#
public string Owner { get; set; }
```

### Property Value
Type: System.String

## See also
- [SiteGroup](OfficeDevPnP.Core.Framework.Provisioning.Providers.Xml.V201705.SiteGroup.md)
- [OfficeDevPnP.Core.Framework.Provisioning.Providers.Xml.V201705](OfficeDevPnP.Core.Framework.Provisioning.Providers.Xml.V201705.md)


text:
package io.apiman.manager.ui.server;

import io.apiman.manager.ui.server.beans.ApiAuthType;

/**
 * Interface providing UI configuration information.
 *
 * @author eric.wittmann@redhat.com
 */
public interface IUIConfig {

    /**
     * Returns true if the metrics UI should be enabled.
     */
    public boolean isMetricsEnabled();

    /**
     * Gets the management layer's API endpoint.
     * @return the management api endpoint
     */
    public String getManagementApiEndpoint();

    /**
     * Gets the management layer's API authentication type.
     * @return the api auth type
     */
    public ApiAuthType getManagementApiAuthType();

    /**
     * Gets the username to use when doing basic auth to the management layer
     * api.
     * @return the management api auth username
     */
    public String getManagementApiAuthUsername();

    /**
     * Gets the password to use when doing basic auth to the management layer
     * api.
     * @return the management api auth password
     */
    public String getManagementApiAuthPassword();

    /**
     * Gets the classname of the token generator to use when doing token auth to
     * the management layer api.
     * @return the management api auth token generator
     */
    public String getManagementApiAuthTokenGenerator();

    /**
     * Gets the URL to use to logout of the UI.
     * @return the logout url
     */
    public String getLogoutUrl();

    /**
     * @return The current platform (e.g. f8 or community).
     */
    public String getPlatform();

}


text:
cask :v1 => 'mysqlworkbench' do
  version '6.3.3'
  sha256 '2ba28b163f88bd6d3a43df8236f351bc43d8fe3d21936424fcb395bb9d56e1a6'

  url "https://dev.mysql.com/get/Downloads/MySQLGUITools/mysql-workbench-community-#{version}-osx-x86_64.dmg"
  name 'MySQL Workbench'
  gpg "#{url}.asc",
      :key_id => '8c718d3b5072e1f5'
  homepage 'https://www.mysql.com/products/workbench'
  license :gpl

  app 'MySQLWorkbench.app'

  zap :delete => [
                  '~/Library/Application Support/MySQL/Workbench',
                  '~/Library/Preferences/com.oracle.mysql.workbench.plist',
                  '~/Library/Preferences/com.oracle.MySQLWorkbench.plist',
                  '~/Library/Saved Application State/com.oracle.mysql.workbench.savedState',
                  '~/Library/Saved Application State/com.oracle.MySQLWorkbench.savedState',
                  '~/Library/Caches/com.oracle.mysql.workbench'
                 ]
end


text:
module OmniAuth
  module Twitter
    VERSION = "1.2.1"
  end
end


text:
**JDBC Driver 3.13.25**

- \|| Set ALLOW_UNDERSCORES_IN_HOST to false by default.

**JDBC Driver 3.13.24**

- \|| Upgraded the following libraries:
- \|| arrow from version 8.0.0 to 9.0.0
- \|| jacksondatabind from version 2.13.2.2 to 2.13.4.2
- \|| google-cloud-storage from version 2.5.0 to 2.6.2
- \|| Remove DML check on getUpdateCount()

**JDBC Driver 3.13.23**

- \|| Relocate Google Guava classes from com/google/common/util/concurrent/** in FIPS driver
- \|| Return an empty resultset for getProcedures() when connected with a reader account
- \|| Use parallelism parameter for PUT/GET with Azure
- \|| Set default logger level for arrow project to SEVERE to avoid unwanted INFO messages
- \|| login test params updated and test case added

**JDBC Driver 3.13.22**

- \| | Updated the tika-core library to version 2.4.1.
- \| | Fixed an issue where getColumnClassName() threw an exception when the column type is timestamp_tx.
- \| | Fixed an issue where calling getSQLStateType() throws an exception while retrieving database metadata.
- \| | Fixed an issue where calling executeLargeBatch() for prepared statements might result in no rows being inserted.

**JDBC Driver 3.13.21**

- \| | Fix memory leak with statement object in SnowflakeConnectionV1::createResultSet
- \| | Fix memory leak with arrow result sets
- \| | Fix JDBC chunk downloader missing data issue
- \| | Update prefetch memory max retry number
- \| | Supporting parsing otherParameters in JDBC
- \| | Add query context support

**JDBC Driver 3.13.20**

- \|| Implemented fast fail functionality for 404 errors returned from Amazon S3
- \Upgraded the following dependencies: arrow, tika-core
- \Upgraded the following Google library versions: google-auth-library, google-cloud-storage, google api client, google http client

**JDBC Driver 3.13.19**

- \| | Updated the isValid() function to send a heartbeat call instead of a SELECT 1 to validate the session connection.
- \| | Added support for setting VARBINARY byte[] arrays in the SnowflakePreparedStatement.setObject() function.
- \| | Updated the following dependencies in the JDBC driver:
- \| | arrow version  0.15.1 to 7.0.0
- \| | jackson version 2.11.0 to 2.13.2
- \| | bouncy version 1.64 to 1.70
- \| | Fixed an issue with TIMESTAMP_INPUT_FORMAT for stage binding.

**JDBC Driver 3.13.18**

- \ | | Upgrade arrow and jackson versions to fix vulnerabilities
- \SNOW-576187 | | Don't append retryCount to the scoped URL for chunk downloading

**JDBC Driver 3.13.17**

- \SNOW-571607 | | Create patch for driver release v3.13.16 to fix incorrect behavior for getSchemas() function
- \| | Fix setting of invalid JVM parameters proxyHost and proxyPort
- \SNOW-348660 | | Add getters for the timezone and ZonedDateTime for SnowflakeTimestampWithTimezone object

**JDBC Driver 3.13.16**

- \| | nonProxyHosts Parameter is Not Honored

**JDBC Driver 3.13.15**

- \| | Refactored the isFileTransfer function into the base class.
- \| | Updated version for Apache Tika.
- \| | Allow URLs with underscores by default, add configuration to covert underscores to hyphens.
- \| | Refactored the FileTransferAgent facade classes into base class
- \| SNOW-538708 | Fixed a segmentation fault issue within Graal VM Native Image applications.
- \| SNOW-508017 | Fixed and issue that cause the ChunkDownloader to hang.

**JDBC Driver 3.13.14**

- \| SNOW-532783 | Updating BC FIPS version in public POM
- \| SNOW-524708 | Adding streaming ingest related metadata for streaming ingest billing
- \| SNOW-475617 SNOW-494684 | Fix DatabaseMetadata bugs : double quotes and wildcards

**JDBC Driver 3.13.13**

- \|SNOW-520660 | Fix for S3 Regional URL not being updated in stageInfo
- \|SNOW-521194 | Fix account name breakage and update host url

**JDBC Driver 3.13.12**

- \| SNOW-473749 | Fix bug where time(3) objects weren't honoring USE_SESSION_TIMEZONE when called with getTimestamp() in Arrow format
- \| SNOW-500624 | Fix JVM http proxy properties to work with PUT/GET
- \| SNOW-513708 | Refactor bind uploader
- \| | Bouncy Castle FIPS update to 1.0.2.1
- \SNOW-496117: Add test for backend bug fix

**JDBC Driver 3.13.11**

- \| SNOW-473749 | Fix bug where time(3) objects weren't honoring USE_SESSION_TIMEZONE when called with getTimestamp() in Arrow format

**JDBC Driver 3.13.10**

- \| SNOW-492055 | Handle uncaught exceptions that can occur in PUT statements
- \| SNOW-477795 | Regard BLOCKED query as running query.
- \| SNOW-458293 | Added parameter JDBC_CHUNK_DOWNLOADER_MAX_RETRY to make chunk downloader max retry configurable

**JDBC Driver 3.13.9**

- \| SNOW-411516 | Enhance JDBC to support SFAsyncResultSet.getResultSetSerializables(Long).
- \| SNOW-366563 | Fix London/Europe daylight savings offset with timestamp_ntz.
- \| SNOW-412040 | Fix ResultSet.getQueryID() so it returns correct query ID for PUT/GET statements.
- \| SNOW-472364 | Add API to get query IDs for multiple statements.
- \| SNOW-441847 | Cancel Prefetch threads to avoid endless ChunkDownloader hanging thread.
- \| SNOW-464020 | Azure iterator exception bug fix.
- \| SNOW-224719 | Allow curly bracket syntax in JDBC CallableStatement.prepareCall().

**JDBC Driver 3.13.8**

- \| SNOW-443760 | Bumped jsoup library from 1.11.3 to 1.14.2
- \| SNOW-148296 | Introduce new connection parameter to enable JDBC https proxying.
- \| SNOW-449297 | Fully implemented Connection.IsValid() function.

**JDBC Driver 3.13.7**

- \| SNOW-394504 | Fix issue with JDBC rejecting accounts with underscores in them.
- \| SNOW-373633 | Fix issue with JDBC not loading the version properly in all cases.

**JDBC Driver 3.13.6**

- \| SNOW-369447 | Make MAX_CONNECTIONS and MAX_CONNECTIONS_PER_ROUTE changeable with jvm parameters.

**JDBC Driver 3.13.5**

- \| SNOW-363333 | Add ability to use Multiple proxies in the same JVM.
- \| SNOW-364253 | Update  json-smart library from 2.4.2 to 2.4.5 to remove security vulnerability.

**JDBC Driver 3.13.4**

- \| SNOW-330467 | Fixed an issue with the logic for updating the driver parameters.
- \| SNOW-348866 | Added the ability for clients to pass in data from a PUT command for file upload without creating a Snowflake session.

**JDBC Driver 3.13.3**

- \| SNOW-346424 | Add snowflakeClientInfo connection parameter for use with Spark connector.
- \| SNOW-299374 | In case of private link, have JDBC driver invoke different API to get regional storage link for AWS us-east-1 deployments.
- \| SNOW-332390 | Fix misleading function name isRetryableHTTPCode()
- \| SNOW-299137 | Add log line to show JWT token info.
- \| SNOW-259255 | Add ability to set TIMESTAMP_NTZ and TIMESTAMP_LTZ types with PreparedStatement.setObject() function.
- \| SNOW-334974 | Update json-smart library from 2.3.x to 2.4.2 to remove security vulnerability.
- \| SNOW-344455 | Update commons-io library from 2.2 to 2.8.0 to remove security vulnerability.

**JDBC Driver 3.13.2**

- \| SNOW-285542 | Fixed an issue with the ResultSet.getTimestamp()/getTime()/getDate() methods when the JDBC_USE_SESSION_TIMEZONE parameter was set.
- \| SNOW-297092 | Fixed an issue with scoping metadata requests to the schema in the session context.
- \| SNOW-259063 | Downgraded the Apache httpclient version to 4.12.11 to avoid an S3 certificate error regression.

**JDBC Driver 3.13.1**

- \| SNOW-258666 | Changed the driver to free up memory chunks when a thread is interrupted.
- \| SNOW-281822 | Fixed a session token expiry error and made the heartbeat frequency configurable.

**JDBC Driver 3.13.0**

- \| SNOW-209530 | Changed the handling of proxy settings. Proxy parameters in the connection string now override the JVM proxy settings. When connecting to Azure, PUT/GET commands now go through the specified proxy.
- \| SNOW-165204 | Fixed a number overflow exception that resulted from calling getObject() on a SQL BIGINT value.
- \| SNOW-136474 | Changed the default value of the multi-part threshold from 64 to 200, and changed the JDBC Driver to read this parameter from the server.
- \| SNOW-251457 | Changed  the ResultSet.getString() method to return DATE objects in the session time zone (rather than use the offset from the JVM time zone).
- \| SNOW-250222 | Fixed an exception thrown by the COPY INTO command when the JDBC Driver inserts more than INT_MAX records from a single file.
- \| SNOW-255552 | Fixed a null pointer exception in ResultSet.getCharacterStream().
- \| SNOW-180954 | Removed the JNA classes from the Snowflake JDBC Driver JAR file.

**JDBC Driver 3.12.17**

- \| SNOW-174428 | Change bulk array binds to be uploaded with streaming PUT instead of local file creation + PUT.
- \| SNOW-213443 | Add configurable TimeToLive command line parameter
- \| SNOW-257198 | Updated google guava library from 28.0 to 30.0 to address vulnerability.

**JDBC Driver 3.12.16**

- \| SNOW-206907 | Added support for downscoping GCS credentials (which can be used instead of presigned URLs).

**JDBC Driver 3.12.15**

- \| SNOW-207061 | Fixed a problem with null checking when converting to timestamp values.

**JDBC Driver 3.12.14**

- \| SNOW-150601 | Suppressed a warning about Illegal reflective access.
- \| SNOW-163265 | Fixed an issue when the getDate method passed in a Calendar object.
- \| SNOW-201788 | Prevented attempts to drop a column that is part of clustering key when generating a temp table.
- \| SNOW-204185 | Fixed an edge case in which ResultSet.next() can hang when the ResultSet data downloader threads hit unexpected errors.
- \| SNOW-208695 | Updated the junit version from 4.12 to 4.13.1.

**JDBC Driver 3.12.13**

- \| SNOW-194437 | INSERT of TIME type bind values via JDBC does not trigger bulk array load via stage.
- \| SNOW-161733 | JDBC setString function performance is not satisfactory.
- \| SNOW-195989 | Snowflake JDBC driver is unable to connect via Key-Pair authentication if they private key is encrypted and if the key is generated using OpenSSL 1.1.1g on Windows or Ubuntu.
- \| SNOW-199080 | Yearly GPG key rotation.

**JDBC Driver 3.12.12**

- \| SNOW-180303 | Removed unnecessary log lines from the JDBC Driver log.

**JDBC Driver 3.12.11**

- \| SNOW-182450 | Added in-band telemetry metrics for the DatabaseMetaData get methods (e.g. getTables).
- \| SNOW-176125 | When the log level is set to DEBUG, log the OOB telemetry entries that are sent to Snowflake.

**JDBC Driver 3.12.10**
- \| SNOW-136193 | JDBC is adjusting DLS for some values that are towards the DLS switch, resulting in a wrong result
- \| SNOW-164505 | Implement telemetry events in JDBC driver where needed
- \| SNOW-170758 | SAML/SSO works in Snowflake UI but does not work with SnowSQL or JDBC when using ExternalBrowser

**JDBC Driver 3.12.9**

- \| SNOW-170944 | Enhance the way how JDBC masks sensitive data.
- \| SNOW-171834 | Cut down on redundant parameters in ClientEnv field

**JDBC Driver 3.12.8**

- \| SNOW-164084 | Reverted a fix that broke OOB telemetry for the driver.
- \| SNOW-163938 | Resolve telemetry response failures in JDBC driver
- \| SNOW-163587 | DatabaseMetaData getFunctionColumns(null, "%", "%", "%") throws SQL compilation error
- \| SNOW-165718 | Add log of client parameter settings to be accessed in Snowhouse
- \| SNOW-169174 | CVE-2020-14061, CVE-2020-14062, CVE-2020-14060, CVE-2020-14195 com.fasterxml.jackson.core:jackson-databind to version 2.9.10.5 or later

**JDBC Driver 3.12.7**

- \| N/A         | Version is not available for download; all fixes are available in 3.12.8 (and higher).

**JDBC Driver 3.12.6**

- \| SNOW-146005 | Fixed issue where using the Spring Data JDBC ``SimpleJdbcInsert`` class to execute a SQL statement threw an exception.
- \| SNOW-150921 | Fixed issue where the connection was retrying the OCSP endpoint while using ``insecureMode``; updated the driver to use OCSP mode specified in the session config for OOB telemetry.
- \| SNOW-152748 | Added new connection parameter, ``stringsQuotedForColumnDef``, to support changes to how the ``DatabaseMetaData.getColumns()`` and ``DatabaseMetaData.getProcedureColumns()`` methods return COLUMN_DEF string values with or without single quotes.
- \| SNOW-157758 | Internal fix for pending feature.
- \| SNOW-163080 | Performance improvements for calling ``ResultSet.next()`` after queries have completed.

**JDBC Driver 3.12.5**

- \| SNOW-115446 | JDBC: Wrong File Name When Using compressAndUploadStream Method on GCP Deployment
- \| SNOW-152637 | Investigate/add metrics to see when asynchronous querying is used
- \| SNOW-150593 | Snowflake throws ConcurrentModificationException when attempting to close resultSets #212
- \| SNOW-153278 | Confirm IDToken presence in JDBC Debug Logs
- \| SNOW-154633 | Create javadoc of JDBC and add all JDBC licenses in it
- \| SNOW-154927 | CVE-2020-10969 CVE-2020-9546 CVE-2020-11620 CVE-2020-10672: Vulnerable versions: >= 2.9.0, <= 2.9.10.3 Patched version: 2.9.10.4
- \| SNOW-156092 | Fix Spark/JDBC nullpointer error in getObject()
- \| SNOW-158363 | Snowflake Authentication Token sneaking through secret detector in logs
- \| SNOW-155630 | Fix some async query PrPr issues and add metadata retrieval

**JDBC Driver 3.12.4**

- \| SNOW-146005 | Spring JDBC bug for Snowflake
- \| SNOW-136193 | JDBC is adjusting DLS for some values that are towards the DLS switch, resulting in a wrong result
- \| SNOW-153256 | Add more verbose error handling to telemetry services
- \| SNOW-86734 | Add client information to USER-AGENT HTTP header
- \| SNOW-153485 | Implemented asynchronous querying in JDBC driver
- \| SNOW-143877 | Support for a custom type name in ResultSetMetadata.getColumnTypeName(); to be used for new types.

**JDBC Driver 3.12.3**

- \| SNOW-75286 | Hide Sensitive data from logs and exceptions for JDBC
- \| SNOW-117429 | Remove Result JSON parser v1 from JDBC.
- \| SNOW-144823 | Fix memory Leak with Telemetry Service's shutdown hook
- \| SNOW-147672 | CVE-2020-8840 CVE-2019-20330 Upgrade com.fasterxml.jackson.core:jackson-databind to version 2.9.10.3 or later.

**JDBC Driver 3.12.2**

- \| SNOW-121867 | SnowflakeConnectionV1.uploadStream() - automatically appends '@' even to correct stage names - unable to upload using escaped internal table stage #199
- \| SNOW-142833 | CVE-2019-20330 CVE-2020-8840 Upgrade com.fasterxml.jackson.core:jackson-databind to version 2.9.10.3 or later.

**JDBC Driver 3.12.1**

- \| SNOW-29974  | Add binding support for TIMESTAMP_TZ including Timezone
- \| SNOW-128360  | Fix NoSuchMethodError: org.slf4j.helpers.MessageFormatter.arrayFormat for Matlab
- \| SNOW-134689 | Increase multi part upload threshold to 64MB for PUT command

**JDBC Driver 3.12.0**

- \| SNOW-68471  | Introduce CLIENT_METADATA_USE_SESSION_DATABASE to scope the database for metadata access. false by default.
- \| SNOW-125221 | Fix getStringFunctions() that does not return all support string functions
- \| SNOW-122286 | AWS: When OVERWRITE is false, which is set by default, the file is uploaded if no same file name exists in the stage. This used to check the content signature but it will no longer check. Azure and GCP already work this way.
- \| SNOW-124868 | Add new statement types for LIST, GET, PUT, RM
- \| SNOW-103629 | Use the FIPS S3 endpoints for regions in FIPS mode
- \| SNOW-128360 | Fix slf4j compatibility issue with Matlab

**JDBC Driver 3.11.1**

- \| SNOW-126957 | Add CLIENT_ENABLE_LOG_INFO_STATEMENT_PARAMETERS for logging statements and binding data in INO log level.
- \| SNOW-122023  | Fix the order of escapeChars for getTables and getColumns.
- \| SNOW-123702 | Update BouncyCastle to 1.60 to fix two high severity issues
- \| SNOW-124928 | Fix precision loss while using getFloat/getDouble for Decimal values having large scale
- \| SNOW-121276 | Add ability to serialize SnowflakeDataSource objects

**JDBC Driver 3.11.0**

- \| SNOW-84438 | GA: ARROW format support, to be enabled in the next few weeks
- \| SNOW-105117 | Fix JDBC Failures retrieving results on GCP
- \| SNOW-119801 | Upgrade JDBC's arrow lib to 0.15.1
- \| SNOW-115434 | Added in writeable check on file cache and change to the home directory if not writable.
- \| SNOW-116121 | Fix JDBC result set produces wrong result for date 0200-02-28
- \| SNOW-98693 | Implement DriverPropertyInfo
- \| SNOW-70240 | Add connection parameter helps to the JDBC command line
- \| SNOW-65944 | Connection.supportsTransactionIsolationLevel() returned not supported
- \| SNOW-115735 | Reduce alter session set autocommit
- \| SNOW-75486 | Add support of keypair parameters in JDBC connection string
- \| SNOW-119059 | Improve error message when required proxy parameter is missing
- \| SNOW-120495 | Add support for OAuth token to SnowflakeBasicDataSource #194
- \| SNOW-70240  | Add connection parameter helps to the JDBC command line

**JDBC Driver 3.10.3**

- \| SNOW-110357 | Fix CVE-2019-16942
- \| SNOW-110744 | Fix array batch is not usable if number of records*fields in a batch is large #186
- \| SNOW-86551 | Fix bugs related to GS generated Arrow results and queries with subqueries
- \| SNOW-97749 | Enable JDBC ResultSet distributed process to support proxy

**JDBC Driver 3.10.2**

- \| SNOW-102750 | Increasing the max limit connection to 300 for JDBC driver.
- \| SNOW-96797 | Support Arrow for select query results generated by GS
- \| SNOW-109827 | Fix bug in JDBC sample code hang
- \| SNOW-104007 | Fix CVE with nimbusds < 7.9

**JDBC Driver 3.10.1**

- \| SNOW-99312 | Implement better retry functionality for chunk downloader
- \| SNOW-98272 | Enable OVERWRITE option for PUT command to overwrite the files
- \| SNOW-23970 | Support wildcards in directory names in PUT commands
- \| SNOW-99497 | Add session id to SnowflakeConnection
- \| SNOW-99630 | Fix CVE-2019-16335, CVE-2019-14540
- \| SNOW-99954 | Associate describe and execute jobs for the server

**JDBC Driver 3.10.0**

- \| SNOW-94386 | Fix getShort, getInt, getLong, getBigDecimal, getFloat, getDouble, getBytes to be consistent between JSON and ARROW result sets
- \| SNOW-97598 | Fix special Characters in Table Name causes getColumns() to not return values
- \| SNOW-97684 | Async submit in-band telemetry data
- \| SNOW-97215 | Change Prepare statement to defer SQL syntax and binding value check to Execute to improve the latency
- \| SNOW-99630 | Fix CVE-2019-16335, CVE-2019-14540: com.fasterxml.jackson.core:jackson-databind

**JDBC Driver 3.9.2**

- \| SNOW-91553 | Refactor for JDBC ResultSet distributed processing
- \| SNOW-88820 | Add cross type tests to JDBC
- \| SNOW-90601 | Add GCS PUT and GET test cases
- \| SNOW-91578 | Fix NullPointerException in TelemetryService.java in SnowflakeFileTransferAgent.java
- \| SNOW-92223 | Merge ArrowLogger and ArrowLogFactory to Arrow source code
- \| SNOW-90927 | Fix AccessControlException in SFResultSet.next()
- \| SNOW-91271 | Fix prepareStatement(String sql, int autoGeneratedKeys) that throws SQLFeatureNotSupportedException
- \| SNOW-90968 | Fix NullPointerException in calling resultSet.getTimestamp() on Time column with null value
- \| SNOW-74252 | Fix calculateUpdateCount(SFBaseResultSet resultSet) that has updateCount as int limited to 4B implying 2.1B records limit
- \| SNOW-94341 | Deprecate Arrow format for JDBC version older than 3.9.1
- \| SNOW-94387 | Fix JDBC Arrow Result: getBoolean, getShort, getInt, getLong, getBigDecimal, getFloat, getDouble, getBytes
- \| SNOW-95458 | Loosen the test interval constraint in SFFormatterTest.java
- \| SNOW-96157 | Add SnowflakeConnection interface

**JDBC Driver 3.9.1**

- \| SNOW-90169 | Fix OCSP fail open
- \| SNOW-84419 | Support proxy for Azure in JDBC (host and port only. No user and password is supported)
- \| SNOW-90230 | Flush revoked OCSPExceptionTelemetryEvent immediately
- \| SNOW-92525 | Make Arrow lib compatible with Java 8

**JDBC Driver 3.9.0**

- \| SNOW-90644 | Add Statement.getLargeCount and executeLargeUpdate
- \| SNOW-86243 | Add Parameter to control Multi-Statement Support with Count
- \| SNOW-75648 | Add validateDefaultParameters to validate the database, schema and warehouse at connection time. false by default.
- \| SNOW-85191 | Fixed DatabaseMetaData.getColumns returns empty string on COLUMN_DEF for columns with no defaults
- \| SNOW-86345 | Add PrivateKey based authentication with datasource
- \| SNOW-88426 | Fix setObject and setNull in the PrepareStatement results into error using latest JDBC driver
- \| SNOW-88467 | Remove javax.activation from jdbc
- \| SNOW-88628 | Fix getTime() method returns NullPointerException error when reading nulls
- \| SNOW-88756 | Fix the return format for VARIANT type with ARROW is some different to that with JSON.
- \| SNOW-89066 | Fix failures to decode the value for datatype time(0) if the result format is ARROW.
- \| SNOW-89110 | Upgrade com.fasterxml.jackson.core:jackson-databind to version 2.9.9.2 to fix security vulnerability.
- \| SNOW-89737 | Fix ResultSet from Arrow_force format does not match resultSet from JSON format after calling executeQuery()
- \| SNOW-90009 | Upgrade org.apache.tika:tika-core to version 1.22 to fix security vulnerability
- \| SNOW-90431 | Fix OOB throwing NPE or provides wrong context in multithread scenarios

**JDBC Driver 3.8.8**

- \| SNOW-79383 | Implement CallableStatement
- \| SNOW-87251 | Added result_query_format parameter for the private preview of new result set format
- \| SNOW-87589  | Upgrade com.fasterxml.jackson.core:jackson-databind to version 2.9.9.1 or later to fix security vulnerability.

**JDBC Driver 3.8.7**

- \| SNOW-85251 | Increase the adjust steps in conservative memory usage mode to better utilize result cache
- \| SNOW-83429 | Build JDBC driver with FIPS certified Bouncy Castle libraries
- \| SNOW-83815 | Query id no longer accessible via JDBC as of 3.7.1
- \| SNOW-84396 | Types.SMALLINT not supported in getColumnClassName

**JDBC Driver 3.8.6**

- \| SNOW-84683 | Add oktausername parameter support to OKTA authenticator

**JDBC Driver 3.8.5**

- \| SNOW-82723 | Support proxyHost including dash and dot
- \| SNOW-84129 | JDBC turn on CLIENT_ENABLE_CONSERVATIVE_MEMORY_USAGE except prod for testing
- \| SNOW-83666 | PUT to S3 endpoint return timeout when using a JDBC connection through proxy
- \| SNOW-84396 | Types.SMALLINT not supported in getColumnClassName

**JDBC Driver 3.8.4**

- \| SNOW-38957 | Connection errors will return multiple error codes instead of 200002
- \| SNOW-70888 | Update Client Driver OCSP Endpoint URL for Private Link Customers
- \| SNOW-19476 | Implement DatabaseMetadata.getTablePrivileges
- \| SNOW-80773 | Connection.setClientInfo refuses any parameter
- \| SNOW-81015 | proxyUser and proxyPassword are optional in the JDBC connect string.
- \| SNOW-81829 | Use Standard Connection Fields for Global URL
- \| SNOW-78996 | Remove https from account name if specified.
- \| SNOW-74255 | Implement java.sql.Statement.executeLargeBatch

**JDBC Driver 3.8.3**

- \| SNOW-70888 | JDBC OCSP URL Update for Privatelink

**JDBC Driver 3.8.2**

- \| SNOW-62766 | Deprecate CLIENT_RESULT_PREFETCH_THREADS and CLIENT_RESULT_PREFETCH_SLOTS
- \| SNOW-77592 | Implemented getProcedures and getProcedureColumns
- \| SNOW-79011 | JDBC don't surface errors when the session is gone
- \| SNOW-79125 | Key comparison should be done by equals method instead of double equal signs
- \| SNOW-79699 | Upgrade com.fasterxml.jackson.core:jackson-databind to version 2.9.9 or later
- \| SNOW-80208 | Fixed a missing data bug on JDBC 3.7.1+'s resultChunkV2: strictly clean isNulls while using from the cache

**JDBC Driver 3.8.1**

- \|SNOW-76035 | DML returns the number of updated rows in getUpdateCount() otherwise -1
- \|SNOW-70751 | Connection.setClientInfo for JDBC to support ApplicationName
- \|SNOW-74086 | Implement DatabaseMetaData.getFunctionColumns
- \|SNOW-76375 | Implement PreparedStatement.getParameterMetaData(), ParameterMetaData.getParameterCount() ParameterMetaData.getParameterType(int)
- \|SNOW-77987 | Revoked OCSP Response persists in in-memory cache
- \|SNOW-67078 | executeBatch supports PUT and GET
- \|SNOW-79011 | Ignore session is missing error when closing connection

**JDBC Driver 3.8.0**

- \|SNOW-75285|Remove sensitive data from URL for JDBC logging
- \|SNOW-75925|Create JDBC interfaces SnowflakeStatement, SnowflakeResultSet, and, SnowflakePreparedStatement to expose Snowflake specific APIs: SnowflakeStatement.getQueryID(), SnowflakeStatement.getBatchQueryID(), SnowflakeResultSet.getQueryID(), SnowflakePreparedStatement.getQueryID()
- \|SNOW-76010|Updated c3p0 version for tests
- \|SNOW-76375|Implements DataBaseMetaData.getParameterMetaData() and ParameterMetaData.getType()
- \|SNOW-75285|Scrub secrets before logging
- \|SNOW-77160|Add OCSP_MODE metric
- \|SNOW-74086|Add getFunctionColumns
- \|SNOW-76150|OCSP SoftFail support for JDBC

**JDBC Driver 3.7.2**

- \|SNOW-67615| Apply CLIENT_METADATA_REQUEST_USE_CONNECTION_CTX behavior to all JDBC get functions with catalog and schema as inputs
- \|SNOW-68058| CLIENT_SESSION_KEEP_ALIVE_HEARTBEAT_FREQUENCY for JDBC
- \|SNOW-73034| Setting the index 0 for binding is ignored. It should raise an exception.
- \|SNOW-68756| JAVA heap space error when querying data: provide detailed error message and suggestions when hits OOM
- \|SNOW-70356| Ensure all associated objects are freed when closed.
- \|SNOW-70409| Close all associated objects when the parent object is closed.
- \|SNOW-71689| Update Client Driver to use new OCSP Endpoint URL based on Client Failover
- \|SNOW-73555| Fixed Not dropping unselected columns after creating temp table
- \|SNOW-67871| Add getQueryId() method to SnowflakeStatementV1 and SnowflakeResultSetV1
- \|SNOW-74238| JDBC SnowflakeBasicDatasource use a driver does not comes from Snowflake

**JDBC Driver 3.7.1**

- \| SNOW-73421 | Internal change for future improvement
- \|SNOW-70354 | Throw SQLException when calling methods of the closed objects.

**JDBC Driver 3.7.0**

- \|SNOW-65887|Change source and target Java version to 1.8 for JDBC driver

**JDBC Driver 3.6.28**

- \|SNOW-67095|Fix a bug which caused the 3.6.x JDBC Driver hangs when resultSet is not consumed. The JDBC driver now always releases resultSet and its memory usage when a statement is closed.
- \|SNOW-67120|Change getTableTypes() from only returning TABLE and VIEW to including TEMPORARY and TRANSIENT types.
- \|SNOW-66302|Fixed parsing date and time format issue.

**JDBC Driver 3.6.27**

- \|SNOW-42661| Add unknown type  binding variable support in table UDF
- \|SNOW-66840| Align CLIENT_METADATA_REQUEST_USE_CONNECTION_CTX behavior of JDBC with ODBC
- \|SNOW-67327| NPE when timestamp value is null in binding
- \|SNOW-62511| Mask AWS password in a query

**JDBC Driver 3.6.26**

- \|SNOW-66026|Change all INFO and WARNING logging to DEBUG in JDBC
- \|SNOW-66015|Binary column always returns 0 precision
- \|SNOW-65421|Fixed binding null with data type raising error.
- \|SNOW-65154|Fixed CHANGELOG.rst format
- \|SNOW-64977|More granular error message for failed batch loads
- \|SNOW-64063|Update JDBC Loader API to using CREATE TABLE ... LIKE syntax
- \|SNOW-53174|Improve error messages when a driver fails to connect to Snowflake, S3 or OCSP

**JDBC Driver 3.6.25**

- \|SNOW-64564| Lazy init JDBC legacy logger
- \|SNOW-63813| Explicitly allows all proxy data to be fed via the JDBC connection string
- \|SNOW-64570| Failed to serialize ClientAuthnDTO in boomi cloud environment

**JDBC Driver 3.6.24**

- \|SNOW-63844| Security vulnerability: com.fasterxml.jackson.core:jackson-databind >= 2.9.0, < 2.9.8
- \|SNOW-62247| Add enum REJECTED_RECORD in class LoadingError
- \|SNOW-61650| Support Dell boomi cloud

**JDBC Driver 3.6.23**

- \|SNOW-63523| Removed hard-coded ``Level.ALL`` for logger initialization.
- \|SNOW-63481| Security enhancement: Updated ``tika-core`` to 1.20.
- \|SNOW-63341| Driver no longer throws an incident for a ``no row found`` user error.
- \|SNOW-63240| Added additional null checks in statements.
- \|SNOW-63137| Changed default driver log level from ``ALL`` to ``INFO`` in the ``logging.properties`` example (in the Snowflake documentation).
- \|SNOW-63067| Fixed issue with intermittent error in driver even though the **Query Details** page (in the web interface) shows the query was successful.
- \|SNOW-61210| Improved OCSP Cert Auth and Handshake retry.
- \|SNOW-45402| Added support for 256-bit encryption for Azure stages.

**JDBC Driver 3.6.22**

- \|SNOW-63026| Driver now invalidates outdated OCSP responses when checking the cache.
- \|SNOW-62996| Fixed intermittent JDBC connection failure in PrivateLink.
- \|SNOW-62140| The default setting for CLIENT_MEMORY_LIMIT parameter is now dynamic, based on the amount of system memory available.
- \|SNOW-61424| Removed unnecessary/redundant version logs.
- \|SNOW-54606| Fixed issue that caused the following exception when using the driver with Java Spring Boot: ``Caused by: java.lang.IllegalArgumentException: URL must start with 'jdbc'``.
- \|SNOW-63163| Fixed NPE when fetching data.

**JDBC Driver 3.6.21**

- \|SNOW-61862| Driver now uses ``YYYY-MM-DD HH24:MI:SS.FF9 TZH:TZM`` for timestamp array binding.

**JDBC Driver 3.6.20**

- \|SNOW-61209| Fixed performance issue with result set download.

**JDBC Driver 3.6.19**

- \|SNOW-44393| Driver now catches exceptions for ``prepareStatement`` so that execution can continue.

**JDBC Driver 3.6.17**

- \|SNOW-59862| Added JVM properties for CLIENT_PREFETCH_THREADS, CLIENT_MEMORY_LIMIT, and CLIENT_RESULT_CHUNK_SIZE.
- \|SNOW-58812| Fixed issue with PARALLEL parameter for PUT and GET commands.
- \|SNOW-59802| Fixed issue with wrong TIME format for the Loader API.
- \|SNOW-56081| CLOB data type now mapped to STRING data type in Snowflake.

**JDBC Driver 3.6.16**

- \|SNOW-57107| Driver now checks to ensure all dependencies are correctly shaded.
- \|SNOW-56603| As announced previously, the CLIENT_MEMORY_LIMIT parameter now governs the total memory used per process instead of per query.

**JDBC Driver 3.6.15**

- \|SNOW-56771| Implemented shading of additional dependencies to a new location to mitigate package conflicts.
- \|SNOW-57051| Fixed CVE-2018-11761.
- \|SNOW-56836| Added support for nanoseconds precision for TIMESTAMP data in Loader API.
- \|SNOW-56604| Added ``skipParsing`` option to ``prepareStatement`` method to skip fetching metadata.

**JDBC Driver 3.6.14**

- \|SNOW-55075| Introduced the CLIENT_RESULT_COLUMN_CASE_INSENSITIVE session parameter to enable matching case-sensitivity for column names in ``ResultSet``.

**JDBC Driver 3.6.13**

- \|SNOW-55868| Added service name support for multi-GS clustering (internal feature).
- \|SNOW-55138| Upgraded dependency to fix known vulnerabilities.
- \|SNOW-55095| Internal change for pending feature.
- \|SNOW-54926| Added ``compressFileByPut``, ``compressDataBeforePut``, ``compressLevel`` to Loader API.
- \|SNOW-55035| Added ``request_guid`` for HTTP request tracing.

**JDBC Driver 3.6.12**

- \|SNOW-26324| Added ``--version`` option to return the JDBC driver version and additional information.

**JDBC Driver 3.6.11**

- \|SNOW-53650| Internal change for pending feature.
- \|SNOW-53452| Internal change for pending feature.

**JDBC Driver 3.6.10**

- \|SNOW-52486| Fixed ``clientStartTime`` and ``retryCount`` metrics in ``query-request``.
- \|SNOW-50766| Updated driver to enforce virtual host style for S3 URLs.
- \|SNOW-50717| Fixed ``SQLException`` in ``getFunctionColumns`` API call.
- \|SNOW-45419| Changed the heartbeat frequency to hourly to mitigate issue with token expiration.
- \|SNOW-39748| Disabled cookie management.

**JDBC Driver 3.6.9**

- \|SNOW-51691| Added support for specifying file cache directories as environment variables or JVM system properties.
- \|SNOW-49850| Added support for disabling SOCKS proxy for JDBC traffic using a new connection parameter (``disableSocksProxy``).
- \|SNOW-41673| Added ``retryCount`` and ``clientStartTime`` parameters to ``query-request`` requests for JDBC.

**JDBC Driver 3.6.8**

- \|SNOW-49653| Internal change for pending feature.

**JDBC Driver 3.6.7**

- \|SNOW-50141| Fixed issue with ``setObject`` not handling BOOLEAN data type.
- \|SNOW-49982| Added ``onError`` parameter in the Loader API; corresponds to the ``ON_ERROR`` option in the COPY INTO *<table>* command.
- \|SNOW-49850| Upgraded AWS SDK to enable support for disabling socket proxy.
- \|SNOW-49653| Internal change for pending feature.

**JDBC Driver 3.6.6**

- \|SNOW-50032| Fixed issue with the OCSP retry check, which wasn't performed if the validity check failed.

**JDBC Driver 3.6.5**

- \|SNOW-45631| Improved array binding when routing bind values through stage.
- \|SNOW-45545| Fixed issue with the data-to-CSV converter for the Loader API. ``NULL`` and empty values are now correctly converted to ``NULL`` and empty, respectively.
- \|SNOW-45021| Removed login name requirement when authenticating with an OAuth access token.

**JDBC Driver 3.6.4**

- \|SNOW-45612| Added ``authenticator`` setting to ``SnowflakeBasicDatasource``.
- \|SNOW-45600| Driver now closes the HTTP response stream to allow HTTP client to reuse socket.
- \|SNOW-45484| Fixed calculation for 50MB file size.
- \|SNOW-41096| Added a parameter to control Telemetry service (for pending feature in the Spark Connector).

**JDBC Driver 3.6.3**

- \|SNOW-43251| Fixed erroneous exception raised when COPY statement loads 0 files.

**JDBC Driver 3.6.2**

- \|SNOW-44536| Fixed the Loader API to support CSV filenames that contain spaces.
- \|SNOW-44497| Fixed the Loader API to suppress race conditions for date formatting.
- \|SNOW-44405| Added ``copyEmptyFieldAsEmpty`` to the Loader API to support ``EMPTY_FIELD_AS_NULL=false`` option for COPY command.

**JDBC Driver 3.6.1**

- \|SNOW-43215| Updated the driver to support OCSP dynamic cache server for PrivateLink.

**JDBC Driver 3.6.0**

- \|SNOW-42908| Enabled the automatic class loader for ``SnowflakeDriver`` class.
- \|SNOW-39684| Enabled the OCSP Response Cache Server by default.

**JDBC Driver 3.5.5**

- \|SNOW-42722| Added support for SF_OCSP_RESPONSE_CACHE_DIR environment variable to specify the OCSP cache file location.
- \|SNOW-39872| Added APPLICATION connection property to allow setting the name for 3rd-party applications.

**JDBC Driver 3.5.4**

- \|SNOW-41484| Fixed URL mismatch error that occurred when using OKTA authentication and the JDBC connection URL contains a port number.

**JDBC Driver 3.5.3**

- \|SNOW-40230| Removed dependency on ``commons-lang3`` package.
- \|SNOW-34464| Added support for key pair authentication.

**JDBC Driver 3.5.2**

- \|SNOW-38455| Upgraded HttpClient to 4.5.5.
- \|SNOW-38454| Upgraded Jackson JSON packages to 2.9.4.

**JDBC Driver 3.5.1**

- \|N\/A| Private release (for internal purposes only; no changes)

**JDBC Driver 3.5.0**

- \|SNOW-38486| Added support for checking for OCSP revocation.
- \|SNOW-37766| Added support for getting ``SecureRandom`` instances without specifying a provider name; this is required because the driver could be running under the IBM JDK.

**JDBC Driver 3.4.3**

- \|SNOW-34464| Internal change for pending feature.

**JDBC Driver 3.4.2**

- \|SNOW-37755| Refactored a server-side fix (SNOW-36580) on the client side.
- \|SNOW-37184| Added support for binding object identifiers.

**JDBC Driver 3.4.1**

- \|SNOW-37400| Added shaded ``amazon.ion`` package.

**JDBC Driver 3.4.0**

- \|SNOW-37276| Fixed an issue where the driver could not use the TLS 1.2 cipher suites in JDK1.7.
- \|SNOW-37242| Allow preparing all types of statements (reverts a change introduced in v3.3.0).
- \|SNOW-37186| Fixed an issue with the NUMBER format in JDBC ``SnowflakeBasicaDataSource.java``.

**JDBC Driver 3.3.3**

- \|SNOW-36917| Fixed an issue where the Loader API incorrectly converted timestamp dates earlier than 1582-Oct-04 due to differences between the Julian and Gregorian calendar.
- \|SNOW-35613| Internal change for pending feature.

**JDBC Driver 3.3.2**

- \|SNOW-32282| Internal change for pending feature.
- \|SNOW-32001| Replaced AWS_ID and AWS_KEY with newer versions.

**JDBC Driver 3.3.1**

- \|SNOW-30511| Fixed issue where Okta returned a 403 error (during federated authentication) due to the driver caching the Okta token in a cookie.

**JDBC Driver 3.3.0**

- \|SNOW-32656| Driver behavior changed to throw an exception if SQL statement cannot be prepared.

**JDBC Driver 3.2.7**

- \|SNOW-32618| Added support for SAML 2.0-compliant services/applications for federated authentication by adding the ``externalbrowser`` option to the ``authenticator`` connection parameter.

**JDBC Driver 3.2.6**

- \|SNOW-31633| Changed ``SFTimestamp`` to accommodate the full range of timestamps supported in Snowflake.

**JDBC Driver 3.2.5**

- \|SNOW-33566| Added support for ``ResultSet.isLast()``, ``isBeforeFirst()``, and ``isAfterLast()``.
- \|SNOW-30962| Optimized the driver by combining ``describe`` and ``execute`` methods when there is no bind.

**JDBC Driver 3.2.4**

- \|SNOW-33371| Fixed issue with v3.2.2 of the JDBC driver not working with the internal stage transfer feature for the Spark Connector.
- \|SNOW-33227| Added support for new session parameter, JDBC_TREAT_DECIMAL_AS_INT, which, if set to TRUE (default value) instructs the driver to treat a column whose scale is zero as BIGINT instead of DECIMAL.
- \|SNOW-33042| Added support to driver for PUT/GET over encrypted staged files for MS Azure.

**JDBC Driver 3.2.3**

- \|SNOW-32618| JDBC driver ADFS integration rewritten using socket API.

**JDBC Driver 3.2.2**

- \|SNOW-32618| Added support for SAML 2.0-compliant applications.
- \|SNOW-31703| Added support for MS Azure.

**JDBC Driver 3.2.1**

- \|SNOW-32060| Added support in the Loader API for binding ``java.sql.Time`` with the TIME data type and dropped support for binding ``java.sql.Time`` with TIMESTAMP.

**JDBC Driver 3.2.0**

- \|SNOW-31749| Updated the driver to use AWS SDK 1.11.165.
- \|SNOW-31647| Fixed issue with NUMBER columns that have a scale of 0; they now return BIGINT instead of DECIMAL in the column metadata.
- \|SNOW-30967| Updated the driver to use the latest S3 SDK to provide support for ``proxy`` and ``nonProxy`` JVM options.

**JDBC Driver 3.1.1**

- \|SNOW-31425| Fixed an issue with a missing statement type for ``executeUpdate()``, which caused the statement to fail in USE commands.

**JDBC Driver 3.1.0**

- \|SNOW-31069| Added support for enforcing JDBC driver to use TLS v1.2.
- \|SNOW-30962| Added support for ``executeBatch()`` on prepared DML statements.

**JDBC Driver 3.0.21**

- \|SNOW-15992| Support added for bulk updates using the APIs ``Statement.addBatch()``, ``executeBatch()``, and ``clearBatch()``.

**JDBC Driver 3.0.20**

- \|SNOW-30700| Driver now always uses Gregorian Calendar for DATE, TIME, and TIMESTAMP values in Loader API.
- \|SNOW-18939| Added support for ORC file format in PUT command.

**JDBC Driver 3.0.19**

- \|SNOW-29998| Implemented the basic ``DataSource`` API, which produces a standard ``Connection`` object.
- \|SNOW-21314| Fixed Date value and validity for '0001-01-01'. Previously, it displayed incorrect date output.

**JDBC Driver 3.0.18**

- \|SNOW-30146| Shortened the heartbeat interval to resolve some token expiration issues.

**JDBC Driver 3.0.17**

- \|SNOW-28390| Fixed an issue where JDBC fails to parse an infinite number.
- \|SNOW-26354| Driver returns a ``SQLWarning`` if a non-existent database or schema is specified in the connection properties.

**JDBC Driver 3.0.16**

- \|SNOW-29262| Fixed an issue when calculating time spent on retry.

**JDBC Driver 3.0.15**

- \|SNOW-29141| Fixed a null pointer exception when binding a null value in JDBC.

**JDBC Driver 3.0.14**

- \|SNOW-28882| Fixed issue where null values were returned for 0 values cast to DOUBLE due to the ``wasNull`` flag not being set correctly.
- \|SNOW-28879| Fixed issue where the result chunk downloader thread prevented the JVM from exiting.

**JDBC Driver 3.0.13**

- \|SNOW-24601| Implemented security patch for federated authentication in JDBC.
- \|SNOW-24184| Open-sourced JDBC Driver on Github.

**JDBC Driver 3.0.12**

- \|SNOW-25540| Added support for binding timestamp variables as timestamp_ntz for applications that use the bind API to load data into datetime columns (which are equivalent to the timestamp_ntz data type).

**JDBC Driver 3.0.11**

- \|SNOW-27255| Fixed internal issue that occurred intermittently if the EventHandler encountered multiple class loaders.

**JDBC Driver 3.0.10**

- \|SNOW-27320| Reverted internal fix from a previous version that caused an issue in this version of the driver.

**JDBC Driver 3.0.9**

- \|SNOW-27121| Fixed an issue where the driver sometimes would hang if it encountered 403 errors while downloading large results. The driver now times out after 1 hour with no response from the application thread during download of results.

**JDBC Driver 3.0.8**

- \|SNOW-25306| Improved performance by using the connection context when retrieving database metadata requests.

**JDBC Driver 3.0.7**

- \|SNOW-26597| Fixed issue where the driver returns an error if the connecting application uses the ``Statement.executeUpdate(String sql, int autoGeneratedKey)`` API because the driver does not support auto-generated keys. The new version of the driver still does not support auto-generated keys; however, if the value for ``autoGeneratedKey`` is ``Statement.NO_KEYS_RETURNED``, the driver now executes the statement successfully.

**JDBC Driver 3.0.6**

- \|SNOW-26298| Fixed issue with invalid UTF-8 returned by driver when extracting data from a table into a file.
- \|SNOW-18758| Forward-slash after the port number is now optional in the URL for the JDBC connect string.

**JDBC Driver 3.0.5**

- \|SNOW-26032| Fixed issue with SNOWFLAKE_SAMPLE_DATABASE not being returned by ``DatabaseMetadata.getCatalogs()`` method.
- \|SNOW-25974| Fixed issue in Windows where PUT command failed if the filename was in quotes and contained backslashes.

**JDBC Driver 3.0.4**

- \|SNOW-14445| Added support for pointing JDBC logger path to a directory other than ``tmp`` to prevent file permission issues.

**JDBC Driver 3.0.3**

- \|SNOW-18243| Added support for case-insensitive searches on column names in result sets. By default, searches are case-sensitive. To request enabling case-insensitive search for your account, please contact `Snowflake Support <https://support.snowflake.net/s/snowflake-support>`_.

**JDBC Driver 3.0.2**

- \|SNOW-25029| Fixed binding support for the TIME data type in the ``PreparedStatement`` API implementation.
- \|SNOW-25024, SNOW-24868| Implemented a fix to generate a user error when the client calls the ``getData``, ``getTimestamp``, or ``getTime`` methods on columns with invalid data types.
- \|SNOW-24947| Fixed issue with GET command when it ends with a semicolon.
- \|SNOW-24610| Updated javadoc related to an issue that caused the Informatica Cloud Snowflake Connector (v1) to fail with the following error: ``invalid data encountered during decompression for file...``.
- \|SNOW-24884| Updated javadoc related to an issue where the Informatica Cloud Snowflake Connector (v1) treated all timestamps as UTC.

**JDBC Driver 3.0.1**

- \|SNOW-24581, SNOW-24569| Fixed issue where an internal error was generated rather than a user error when attempting to convert a data type to an invalid data type.

**JDBC Driver 3.0.0**

- \|SNOW-24544| Added support for AWS Signature JDBC Driver v4.
- \|SNOW-23803| Migrated the classpath from ``com.snowflake ...`` to ``net.snowflake ...``.
- \|SNOW-22351| Improved memory management for downloading large result sets.

**JDBC Driver 2.8.2**

- \|SNOW-24335| Fixed issue where a file upload (PUT command) might not correctly close a file handle that was opened during this operation.
- \|SNOW-21736| Driver now throws a user error instead of generating an incident if a closed ``resultset`` is fetched.

**JDBC Driver 2.8.1**

- \|SNOW-23919| Fixed issue with timezone not being set correctly for the DATE data type, which resulted in date values not being returned correctly.
- \|SNOW-23809| Improved the performance of the ``Connection.getAutoCommit`` API.
- \|SNOW-20904| Driver now available on central ``mvn`` nexus repository.


text:
package net.fec.openrq.suites;

import net.fec.openrq.SBDInfoReadWriteTest;
import net.fec.openrq.parameters.FECParametersReadWriteTest;

import org.junit.runner.RunWith;
import org.junit.runners.Suite;
import org.junit.runners.Suite.SuiteClasses;

@RunWith(Suite.class)
@SuiteClasses({
               FECParametersReadWriteTest.class,
               SBDInfoReadWriteTest.class
})
public class ReadWriteSuite {

    // placeholder class for inclusion of remaining test classes
}


text:
import client
import datetime
import random
import threading
import uuid
from monitoring.monitorlib import rid
from locust import task, between

class Sub(client.USS):
    wait_time = between(0.01, 1)
    lock = threading.Lock()

    def gen_vertices(self):
        base_lng = random.randint(0, 180)
        base_lat = random.randint(-90, 90)
        return [
            {
                'lng': base_lng + 0.6205,
                'lat': base_lat + 0.6558
            },
            {
                'lng': base_lng + 0.6301,
                'lat': base_lat + 0.6898
            },
            {
                'lng': base_lng + 0.6700,
                'lat': base_lat + 0.6709
            },
            {
                'lng': base_lng + 0.6466,
                'lat': base_lat + 0.6407
            },
        ]

    @task(100)
    def create_sub(self):
        time_start = datetime.datetime.utcnow()
        time_end = time_start + datetime.timedelta(minutes=60)
        sub_uuid = str(uuid.uuid4())

        resp = self.client.put(
            "/subscriptions/{}".format(sub_uuid),
            json={
                "extents": {
                    "spatial_volume": {
                        "footprint": {
                            "vertices": self.gen_vertices(),
                        },
                        "altitude_lo": 20,
                        "altitude_hi": 400,
                    },
                    "time_start": time_start.strftime(rid.DATE_FORMAT),
                    "time_end": time_end.strftime(rid.DATE_FORMAT),
                },
                "callbacks": {
                    "identification_service_area_url": "https://example.com/foo"
                },
            },
        )
        if resp.status_code == 200:
            self.sub_dict[sub_uuid] = resp.json()["subscription"]["version"]

    @task(20)
    def get_sub(self):
        target_sub = random.choice(list(self.sub_dict.keys())) if self.sub_dict else None
        if not target_sub:
            print("Nothing to pick from sub_dict for GET")
            return
        self.client.get("/subscriptions/{}".format(target_sub))

    @task(50)
    def update_sub(self):
        target_sub, target_version = self.checkout_sub()
        if not target_sub:
            print("Nothing to pick from sub_dict for UPDATE")
            return

        time_start = datetime.datetime.utcnow()
        time_end = datetime.datetime.utcnow() + datetime.timedelta(minutes=2)
        resp = self.client.put(
            "/subscriptions/{}/{}".format(target_sub, target_version),
            json={
                "extents": {
                    "spatial_volume": {
                        "footprint": {
                            "vertices": self.gen_vertices(),
                        },
                        "altitude_lo": 20,
                        "altitude_hi": 400,
                    },
                    "time_start": time_start.strftime(rid.DATE_FORMAT),
                    "time_end": time_end.strftime(rid.DATE_FORMAT),
                },
                "callbacks": {
                    "identification_service_area_url": "https://example.com/foo"
                },
            },
        )
        if resp.status_code == 200:
            self.sub_dict[target_sub] = resp.json()["subscription"]["version"]

    @task(5)
    def delete_sub(self):
        target_sub, target_version = self.checkout_sub()
        if not target_sub:
            print("Nothing to pick from sub_dict for DELETE")
            return
        self.client.delete("/subscriptions/{}/{}".format(target_sub, target_version))

    def checkout_sub(self):
        self.lock.acquire()
        target_sub = random.choice(list(self.sub_dict.keys())) if self.sub_dict else None
        target_version = self.sub_dict.pop(target_sub, None)
        self.lock.release()
        return target_sub, target_version

    def on_start(self):
        # Insert atleast 1 Sub for update to not fail
        self.create_sub()

    def on_stop(self):
        self.sub_dict = {}


text:
'use strict';

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = reporterFactory;

var _gulpUtil = require('gulp-util');

var _gulpUtil2 = _interopRequireDefault(_gulpUtil);

var _stylelint = require('stylelint');

var _writer = require('./writer');

var _writer2 = _interopRequireDefault(_writer);

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

/**
 * Creates a reporter from the given config.
 * @param {Object} [config] - Reporter config.
 * @param {Object} [options] - Plugin options.
 * @return {Function} Reporter.
 */
function reporterFactory() {
  var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

  /**
   * Formatter for stylelint results.
   *
   * User has a choice of passing a custom formatter function,
   * or a name of formatter bundled with stylelint by default.
   *
   * @type {Function}
   */
  var formatter = typeof config.formatter === 'string' ? _stylelint.formatters[config.formatter] : config.formatter;

  /**
   * Reporter.
   * @param {[Object]} results - Array of stylelint results.
   * @return {Promise} Resolved when writer and logger are done.
   */
  return function reporter(results) {

    /**
     * Async tasks performed by the reporter.
     * @type [Promise]
     */
    var asyncTasks = [];

    /**
     * Formatter output.
     * @type String
     */
    var formattedText = formatter(results);

    if (config.console && formattedText.trim()) {
      asyncTasks.push(_gulpUtil2.default.log('\n' + formattedText + '\n'));
    }

    if (config.save) {
      asyncTasks.push((0, _writer2.default)(formattedText, config.save, options.reportOutputDir));
    }

    return Promise.all(asyncTasks);
  };
} /**
   * Gulp stylelint reporter factory.
   * @module gulp-stylelint/reporter-factory
   */


text:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
    <assemblyIdentity version="1.0.0.0" processorArchitecture="X86" name="ElfView" type="win32" />
    <description>Elf Viewer</description>
    <dependency>
        <dependentAssembly>
            <assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="X86" publicKeyToken="6595b64144ccf1df" language="*" />
        </dependentAssembly>
    </dependency>
</assembly>


text:
export class Node {
  constructor(triangle) {
    this.nodeLeft = null;
    this.nodeRight = null;
    this.triangle = triangle;
  }
}