From 53777da01f1858a5775df1395d5fa5351979c598 Mon Sep 17 00:00:00 2001 From: Adam Holmberg Date: Thu, 5 Feb 2015 11:41:41 -0600 Subject: [PATCH] Remove cqlengine project artifacts, update existing README --- AUTHORS | 17 -- CONTRIBUTING.md | 12 - Makefile | 14 -- README.rst | 13 +- RELEASE.txt | 7 - Vagrantfile | 46 ---- bin/get_changelog.py | 18 -- bin/test.py | 6 - changelog | 279 ---------------------- manifests/default.pp | 66 ----- modules/cassandra/files/cassandra.upstart | 18 -- requirements-dev.txt | 7 - test-requirements.txt | 2 + upgrading.txt | 13 - 14 files changed, 9 insertions(+), 509 deletions(-) delete mode 100644 AUTHORS delete mode 100644 CONTRIBUTING.md delete mode 100644 Makefile delete mode 100644 RELEASE.txt delete mode 100644 Vagrantfile delete mode 100644 bin/get_changelog.py delete mode 100755 bin/test.py delete mode 100644 changelog delete mode 100644 manifests/default.pp delete mode 100644 modules/cassandra/files/cassandra.upstart delete mode 100644 requirements-dev.txt delete mode 100644 upgrading.txt diff --git a/AUTHORS b/AUTHORS deleted file mode 100644 index 8e03f7f8..00000000 --- a/AUTHORS +++ /dev/null @@ -1,17 +0,0 @@ -PRIMARY AUTHORS - -Blake Eggleston -Jon Haddad - -CONTRIBUTORS (let us know if we missed you) - -Eric Scrivner - test environment, connection pooling -Kevin Deldycke -Roey Berman -Danny Cosson -Michael Hall -Netanel Cohen-Tzemach -Mariusz KryƄski -Greg Doermann -@pandu-rao -Amy Hanlon diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 62f6d786..00000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,12 +0,0 @@ -### Contributing code to cqlengine - -Before submitting a pull request, please make sure that it follows these guidelines: - -* Limit yourself to one feature or bug fix per pull request. -* Include unittests that thoroughly test the feature/bug fix -* Write clear, descriptive commit messages. -* Many granular commits are preferred over large monolithic commits -* If you're adding or modifying features, please update the documentation - -If you're working on a big ticket item, please check in on [cqlengine-users](https://groups.google.com/forum/?fromgroups#!forum/cqlengine-users). -We'd hate to have to steer you in a different direction after you've already put in a lot of hard work. diff --git a/Makefile b/Makefile deleted file mode 100644 index 061fc274..00000000 --- a/Makefile +++ /dev/null @@ -1,14 +0,0 @@ -clean: - find . -name *.pyc -delete - rm -rf cqlengine/__pycache__ - - -build: clean - python setup.py build - -release: clean - python setup.py sdist upload - - -.PHONY: build - diff --git a/README.rst b/README.rst index d4995afa..74967740 100644 --- a/README.rst +++ b/README.rst @@ -8,7 +8,9 @@ A Python client driver for Apache Cassandra. This driver works exclusively with the Cassandra Query Language v3 (CQL3) and Cassandra's native protocol. Cassandra versions 1.2 through 2.1 are supported. -The driver supports Python 2.6, 2.7, 3.3, and 3.4. +The driver supports Python 2.6, 2.7, 3.3, and 3.4*. + +* cqlengine component presently supports Python 2.7+ Installation ------------ @@ -32,8 +34,9 @@ A couple of links for getting up to speed: Object Mapper ------------- -The recommended object mapper for CQL is `cqlengine `_, -which utilizes this driver. +cqlengine (originally developed by Blake Eggleston and Jon Haddad, with contributions from the +community) is now maintained as an integral part of this package. Refer to +`documentation here `## UPDATE LINK ##. Reporting Problems ------------------ @@ -54,12 +57,10 @@ you can use `freenode's web-based client true - - # Provision with puppet - config.vm.provision :shell, :inline => "apt-get update" - - config.vm.provision :puppet, :options => ['--verbose', '--debug'] do |puppet| - puppet.facter = {'hostname' => 'cassandraengine'} - # puppet.manifests_path = "puppet/manifests" - # puppet.manifest_file = "site.pp" - puppet.module_path = "modules" - end -end diff --git a/bin/get_changelog.py b/bin/get_changelog.py deleted file mode 100644 index 7844f66c..00000000 --- a/bin/get_changelog.py +++ /dev/null @@ -1,18 +0,0 @@ -from github import Github -import sys, os - -g = Github(os.environ["GITHUB_TOKEN"]) - -milestone = sys.argv[1] -print "Fetching all issues for milestone %s" % milestone -repo = g.get_repo("cqlengine/cqlengine") - -milestones = repo.get_milestones() -milestone = [x for x in milestones if x.title == milestone][0] -issues = repo.get_issues(milestone=milestone, state="closed") - -for issue in issues: - print "[%d] %s" % (issue.number, issue.title) - -print("Done") - diff --git a/bin/test.py b/bin/test.py deleted file mode 100755 index d8d5097b..00000000 --- a/bin/test.py +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env python - -import nose - - -nose.main() diff --git a/changelog b/changelog deleted file mode 100644 index 2eb0ccd6..00000000 --- a/changelog +++ /dev/null @@ -1,279 +0,0 @@ -CHANGELOG - - -0.21.1 - -removed references to create_missing_keyspace - - -0.21.0 - -Create keyspace no longer defaults to SimpleStrategy with 3 replicas. It must be manually specified. -sync_table() no longer has an option to create keyspaces automatically. -cqlengine_test is now the default keyspace used for tests and is explicitly created -all references hardcoded to the "test" keyspace have been removed and use the default instead -instead of testing with bin/nose, use setup_package -improved validation error messages to include column name -fixed updating empty sets -improvements to puppet download script -per query timeouts now supported, see https://cqlengine.readthedocs.org/en/latest/topics/queryset.html?highlight=timeout#per-query-timeouts - -0.19.0 - -Fixed tests with Cassandra version 1.2 and 2.1 -Fixed broken static columns -support for IF NOT EXISTS via Model.if_not_exists().create() - -0.18.1 - -[264] fixed support for bytearrays in blob columns - - -0.18.0 - -[260] support for static columns -[259] docs update - examples for the queryset method references -[258] improve docs around blind updates -[256] write docs about developing cqlengine itself -[254] use CASSANDRA_VERSION in tests -[252] memtable_flush_period_in_ms not in C 1.2 - guard against test failure -[251] test fails occasionally despite lists looking the same -[246] document Batches default behaviour -[239] add sphinx contrib module to docs -[237] update to cassandra-driver 2.1 -[232] update docs w/ links to external tutorials -[229] get travis to test different cassandra versions -[211] inet datatype support -[209] Python 3 support - - -0.17.0 - -* retry_connect on setup() -* optional default TTL on model -* fixed caching documentation - - -0.16.0 - - 225: No handling of PagedResult from execute - 222: figure out how to make travis not totally fail when a test is skipped - 220: delayed connect. use setup(delayed_connect=True) - 218: throw exception on create_table and delete_table - 212: Unchanged primary key trigger error on update - 206: FAQ - why we dont' do #189 - 191: Add support for simple table properties. - 172: raise exception when None is passed in as query param - 170: trying to perform queries before connection is established should raise useful exception - 162: Not Possible to Make Non-Equality Filtering Queries - 161: Filtering on DateTime column - 154: Blob(bytes) column type issue - 128: remove default read_repair_chance & ensure changes are saved when using sync_table - 106: specify caching on model - 99: specify caching options table management - 94: type checking on sync_table (currently allows anything then fails miserably) - 73: remove default 'cqlengine' keyspace table management - 71: add named table and query expression usage to docs - - - -0.15.0 -* native driver integration - -0.14.0 - -* fix for setting map to empty (Lifto) -* report when creating models with attributes that conflict with cqlengine (maedhroz) -* use stable version of sure package (maedhroz) -* performance improvements - - -0.13.0 -* adding support for post batch callbacks (thanks Daniel Dotsenko github.com/dvdotsenko) -* fixing sync table for tables with multiple keys (thanks Daniel Dotsenko github.com/dvdotsenko) -* fixing bug in Bytes column (thanks Netanel Cohen-Tzemach github.com/natict) -* fixing bug with timestamps and DST (thanks Netanel Cohen-Tzemach github.com/natict) - -0.12.0 - -* Normalize and unquote boolean values. (Thanks Kevin Deldycke github.com/kdeldycke) -* Fix race condition in connection manager (Thanks Roey Berman github.com/bergundy) -* allow access to instance columns as if it is a dict (Thanks Kevin Deldycke github.com/kdeldycke) -* Added support for blind partial updates to queryset (Thanks Danny Cosson github.com/dcosson) -* Model instance equality check bugfix (Thanks to Michael Hall, github.com/mahall) -* Fixed bug syncing tables with camel cased names (Thanks to Netanel Cohen-Tzemach, github.com/natict) -* Fixed bug dealing with eggs (Thanks Kevin Deldycke github.com/kdeldycke) - -0.11.0 - -* support for USING TIMESTAMP via a .timestamp(timedelta(seconds=30)) syntax - - allows for long, timedelta, and datetime -* fixed use of USING TIMESTAMP in batches -* clear TTL and timestamp off models after persisting to DB -* allows UUID without dashes - (Thanks to Michael Hall, github.com/mahall) -* fixes regarding syncing schema settings (thanks Kai Lautaportti github.com/dokai) - -0.10.0 - -* support for execute_on_exception within batches - -0.9.2 -* fixing create keyspace with network topology strategy -* fixing regression with query expressions - -0.9 -* adding update method -* adding support for ttls -* adding support for per-query consistency -* adding BigInt column (thanks @Lifto) -* adding support for timezone aware time uuid functions (thanks @dokai) -* only saving collection fields on insert if they've been modified -* adding model method that returns a list of modified columns - -0.8.5 -* adding support for timeouts - -0.8.4 -* changing value manager previous value copying to deepcopy - -0.8.3 -* better logging for operational errors - -0.8.2 -* fix for connection failover - -0.8.1 -* fix for models not exactly matching schema - -0.8.0 -* support for table polymorphism -* var int type - -0.7.1 -* refactoring query class to make defining custom model instantiation logic easier - -0.7.0 -* added counter columns -* added support for compaction settings at the model level -* deprecated delete_table in favor of drop_table -* deprecated create_table in favor of sync_table -* added support for custom QuerySets - -0.6.0 -* added table sync - -0.5.2 -* adding hex conversion to Bytes column - -0.5.1 -* improving connection pooling -* fixing bug with clustering order columns not being quoted - -0.5 -* eagerly loading results into the query result cache, the cql driver does this anyway, - and pulling them from the cursor was causing some problems with gevented queries, - this will cause some breaking changes for users calling execute directly - -0.4.10 -* changing query parameter placeholders from uuid1 to uuid4 - -0.4.7 -* adding support for passing None into query batch methods to clear any batch objects - -0.4.6 -* fixing the way models are compared - -0.4.5 -* fixed bug where container columns would not call their child to_python method, this only really affected columns with special to_python logic - -0.4.4 -* adding query logging back -* fixed bug updating an empty list column - -0.4.3 -* fixed bug with Text column validation - -0.4.2 -* added support for instantiating container columns with column instances - -0.4.1 -* fixed bug in TimeUUID from datetime method - -0.4.0 -* removed default values from all column types -* explicit primary key is required (automatic id removed) -* added validation on keyname types on .create() -* changed table_name to __table_name__, read_repair_chance to __read_repair_chance__, keyspace to __keyspace__ -* modified table name auto generator to ignore module name -* changed internal implementation of model value get/set -* added TimeUUID.from_datetime(), used for generating UUID1's for a specific -time - -0.3.3 -* added abstract base class models - -0.3.2 -* comprehesive rewrite of connection management (thanks @rustyrazorblade) - -0.3 -* added support for Token function (thanks @mrk-its) -* added support for compound partition key (thanks @mrk-its)s -* added support for defining clustering key ordering (thanks @mrk-its) -* added values_list to Query class, bypassing object creation if desired (thanks @mrk-its) -* fixed bug with Model.objects caching values (thanks @mrk-its) -* fixed Cassandra 1.2.5 compatibility bug -* updated model exception inheritance - -0.2.1 -* adding support for datetimes with tzinfo (thanks @gdoermann) -* fixing bug in saving map updates (thanks @pandu-rao) - -0.2 -* expanding internal save function to use update where appropriate -* adding set, list, and map collection types -* adding support for allow filtering flag -* updating management functions to work with cassandra 1.2 -* fixed a bug querying datetimes -* modifying datetime serialization to preserve millisecond accuracy -* adding cql function call generators MaxTimeUUID and MinTimeUUID - -0.1.1 -* fixed a bug occurring when creating tables from the REPL - -0.1 -* added min_length and max_length validators to the Text column -* added == and != equality operators to model class -* fixed bug with default values that would evaluate to False (ie: 0, '') - -0.0.9 -* fixed column inheritance bug -* manually defined table names are no longer inherited by subclasses - -0.0.8 -* added configurable read repair chance to model definitions -* added configurable keyspace strategy class and replication factor to keyspace creator - -0.0.7 -* fixed manual table name bug -* changed model level db_name field to table_name - -0.0.6 -* added TimeUUID column - -0.0.5 -* added connection pooling -* adding a few convenience query classmethods to the model class - -0.0.4-ALPHA -* added Sphinx docs -* changing create_column_family management function to create_table -* changing delete_column_family management function to delete_table -* added partition key validation to QuerySet delete method -* added .get() method to QuerySet -* added create method shortcut to the model class - -0.0.3-ALPHA -* added queryset result caching -* added queryset array index access and slicing -* updating table name generation (more readable) - diff --git a/manifests/default.pp b/manifests/default.pp deleted file mode 100644 index 4b94fc85..00000000 --- a/manifests/default.pp +++ /dev/null @@ -1,66 +0,0 @@ -# Basic virtualbox configuration -Exec { path => "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" } - -node basenode { - package{["build-essential", "git-core", "vim"]: - ensure => installed - } -} - -class xfstools { - package{['lvm2', 'xfsprogs']: - ensure => installed - } -} -class java { - package {['openjdk-7-jre-headless']: - ensure => installed - } -} - -class cassandra { - include xfstools - include java - - package {"wget": - ensure => latest - } - - file {"/etc/init/cassandra.conf": - source => "puppet:///modules/cassandra/cassandra.upstart", - owner => root - } - - exec {"download-cassandra": - cwd => "/tmp", - command => "wget http://download.nextag.com/apache/cassandra/1.2.19/apache-cassandra-1.2.19-bin.tar.gz", - creates => "/tmp/apache-cassandra-1.2.19-bin.tar.gz", - require => [Package["wget"], File["/etc/init/cassandra.conf"]] - } - - exec {"install-cassandra": - cwd => "/tmp", - command => "tar -xzf apache-cassandra-1.2.19-bin.tar.gz; mv apache-cassandra-1.2.19 /usr/local/cassandra", - require => Exec["download-cassandra"], - creates => "/usr/local/cassandra/bin/cassandra" - } - - service {"cassandra": - ensure => running, - require => Exec["install-cassandra"] - } -} - -node cassandraengine inherits basenode { - include cassandra - - package {["python-pip", "python-dev", "python-nose"]: - ensure => installed - } - - exec {"install-requirements": - cwd => "/vagrant", - command => "pip install -r requirements-dev.txt", - require => [Package["python-pip"], Package["python-dev"]] - } -} diff --git a/modules/cassandra/files/cassandra.upstart b/modules/cassandra/files/cassandra.upstart deleted file mode 100644 index 05278cad..00000000 --- a/modules/cassandra/files/cassandra.upstart +++ /dev/null @@ -1,18 +0,0 @@ -# Cassandra Upstart -# - -description "Cassandra" - -start on runlevel [2345] -stop on runlevel [!2345] - -respawn - -exec /usr/local/cassandra/bin/cassandra -f - - - -pre-stop script - kill `cat /tmp/cassandra.pid` - sleep 3 -end script \ No newline at end of file diff --git a/requirements-dev.txt b/requirements-dev.txt deleted file mode 100644 index 748d8bbe..00000000 --- a/requirements-dev.txt +++ /dev/null @@ -1,7 +0,0 @@ --r requirements.txt -nose -nose-progressive -profilestats -pycallgraph -ipdbplugin==1.2 -ipdb==0.7 diff --git a/test-requirements.txt b/test-requirements.txt index 430515c0..e4d2d383 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -1,3 +1,4 @@ +-r requirements.txt blist scales nose @@ -6,3 +7,4 @@ ccm>=2.0 unittest2 PyYAML pytz +sure diff --git a/upgrading.txt b/upgrading.txt deleted file mode 100644 index 95727aa5..00000000 --- a/upgrading.txt +++ /dev/null @@ -1,13 +0,0 @@ -0.15 Upgrade to use Datastax Native Driver - -We no longer raise cqlengine based OperationalError when connection fails. Now using the exception thrown in the native driver. - -If you're calling setup() with the old thrift port in place, you will get connection errors. Either remove it (the default native port is assumed) or change to the default native port, 9042. - -The cqlengine connection pool has been removed. Connections are now managed by the native driver. This should drastically reduce the socket overhead as the native driver can multiplex queries. - -If you were previously manually using "ALL", "QUORUM", etc, to specificy consistency levels, you will need to migrate to the cqlengine.ALL, QUORUM, etc instead. If you had been using the module level constants before, nothing should need to change. - -No longer accepting username & password as arguments to setup. Use the native driver's authentication instead. See http://datastax.github.io/python-driver/api/cassandra/auth.html - -