diff --git a/.travis.yml b/.travis.yml index 8f0a8e4..6eab6ce 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,7 +3,6 @@ sudo: false services: cassandra env: - - DJANGO_VERSION=1.5 CASS_DRIVER_NO_CYTHON=1 - DJANGO_VERSION=1.6 CASS_DRIVER_NO_CYTHON=1 - DJANGO_VERSION=1.7 CASS_DRIVER_NO_CYTHON=1 - DJANGO_VERSION=1.8 CASS_DRIVER_NO_CYTHON=1 diff --git a/django_cassandra_engine/models.py b/django_cassandra_engine/models.py index 9772097..f5b4453 100644 --- a/django_cassandra_engine/models.py +++ b/django_cassandra_engine/models.py @@ -1,6 +1,5 @@ -from django_cassandra_engine.utils import get_cassandra_connection +from django_cassandra_engine.utils import get_cassandra_connections -cassandra_connection = get_cassandra_connection() -if cassandra_connection is not None: - cassandra_connection.connect() +for _, conn in get_cassandra_connections(): + conn.connect()