I have tests that generate unique dynamodb tables (with streams enabled) for each test (to provide isolation) and keep running into Math.random() with tests timing out. After bash'ing into the docker container and force killing various services, I narrowed it down to kinesalite.

An easy way to reproduce isrun it within sharedLimit = 1 like so:
`node /opt/code/localstack/localstack/node_modules/kinesalite/cli.js --shardLimit 1 --port 4565`

Doing so causes dynamodb.createTable commands to hang after a few tries.
import tempfile
import subprocess
from os.path import expanduser
import six
from boto3 import Session
from localstack.constants import DEFAULT_SERVICE_PORTS, LOCALHOST, PATH_USER_REQUEST, DEFAULT_PORT_WEB_UI
TRUE_VALUES = ('1', 'true')
KINESIS_ERROR_PROBABILITY = float(os.environ.get('KINESIS_ERROR_PROBABILITY', '').strip() or 0.0)
DYNAMODB_ERROR_PROBABILITY = float(os.environ.get('DYNAMODB_ERROR_PROBABILITY', '').strip() or 0.0)
HOSTNAME = os.environ.get('HOSTNAME', '').strip() or LOCALHOST
HOSTNAME_EXTERNAL = os.environ.get('HOSTNAME_EXTERNAL', '').strip() or LOCALHOST
SQS_PORT_EXTERNAL = int(os.environ.get('SQS_PORT_EXTERNAL') or 0)
LOCALSTACK_HOSTNAME = os.environ.get('LOCALSTACK_HOSTNAME', '').strip() or HOSTNAME
LAMBDA_REMOTE_DOCKER = os.environ.get('LAMBDA_REMOTE_DOCKER', '').lower().strip() in TRUE_VALUES
LAMBDA_DOCKER_NETWORK = os.environ.get('LAMBDA_DOCKER_NETWORK', '').strip()
TMP_FOLDER = os.path.join(tempfile.gettempdir(), 'localstack')
if TMP_FOLDER.startswith('/var/folders/') and os.path.exists('/private%s' % TMP_FOLDER):
    TMP_FOLDER = '/private%s' % TMP_FOLDER
HOST_TMP_FOLDER = os.environ.get('HOST_TMP_FOLDER', TMP_FOLDER)
DATA_DIR = os.environ.get('DATA_DIR', '').strip()
USE_SSL = os.environ.get('USE_SSL', '').strip() not in ('0', 'false', '')
DEFAULT_ENCODING = 'utf-8'
DOCKER_SOCK = os.environ.get('DOCKER_SOCK', '').strip() or '/var/run/docker.sock'
DOCKER_FLAGS = os.environ.get('DOCKER_FLAGS', '').strip()
DOCKER_CMD = os.environ.get('DOCKER_CMD', '').strip() or 'docker'
PORT_WEB_UI = int(os.environ.get('PORT_WEB_UI', '').strip() or DEFAULT_PORT_WEB_UI)
DOCKER_BRIDGE_IP = os.environ.get('DOCKER_BRIDGE_IP', '').strip()
EXTRA_CORS_ALLOWED_HEADERS = os.environ.get('EXTRA_CORS_ALLOWED_HEADERS', '').strip()
EXTRA_CORS_EXPOSE_HEADERS = os.environ.get('EXTRA_CORS_EXPOSE_HEADERS', '').strip()
def has_docker():