~ubuntu-branches/ubuntu/trusty/python-happybase/trusty

« back to all changes in this revision

Viewing changes to doc/index.rst

  • Committer: Package Import Robot
  • Author(s): Thomas Goirand
  • Date: 2013-05-30 13:56:42 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20130530135642-tveld2y1dbkhmuv3
Tags: 0.6-1
* New upstream release (Closes: #712971).
* Ran wrap-and-sort.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
*********
 
1
=========
2
2
HappyBase
3
 
*********
4
 
 
5
 
**HappyBase** is a developer-friendly `Python <http://python.org/>`_ library to
6
 
interact with `Apache HBase <http://hbase.apache.org/>`_.
7
 
 
8
 
 
9
 
.. rubric:: Contents of this documentation
 
3
=========
 
4
 
 
5
.. py:currentmodule:: happybase
 
6
 
 
7
**HappyBase** is a developer-friendly Python__ library to interact with `Apache
 
8
HBase`__. HappyBase is designed for use in standard HBase setups, and offers
 
9
application developers a Pythonic API to interact with HBase. Below the surface,
 
10
HappyBase uses the `Python Thrift library`__ to connect to HBase using its
 
11
Thrift__ gateway, which is included in the standard HBase 0.9x releases.
 
12
 
 
13
__ http://python.org/
 
14
__ http://hbase.apache.org/
 
15
__ http://pypi.python.org/pypi/thrift
 
16
__ http://thrift.apache.org/
 
17
 
 
18
 
 
19
.. note::
 
20
 
 
21
   **Do you enjoy HappyBase?** Please consider making a small donation__ to let
 
22
   me know you appreciate my work. Thanks!
 
23
 
 
24
   __ https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ZJ9U8DNN6KZ9Q
 
25
 
 
26
 
 
27
Example
 
28
=======
 
29
 
 
30
The example below illustrates basic usage of the library. The :doc:`user guide
 
31
<user>` contains many more examples.
 
32
 
 
33
::
 
34
 
 
35
   import happybase
 
36
 
 
37
   connection = happybase.Connection('hostname')
 
38
   table = connection.table('table-name')
 
39
 
 
40
   table.put('row-key', {'family:qual1': 'value1',
 
41
                         'family:qual2': 'value2'})
 
42
 
 
43
   row = table.row('row-key')
 
44
   print row['family:qual1']  # prints 'value1'
 
45
 
 
46
   for key, data in table.rows(['row-key-1', 'row-key-2']):
 
47
       print key, data  # prints row key and data for each row
 
48
 
 
49
   for key, data in table.scan(row_prefix='row'):
 
50
       print key, data  # prints 'value1' and 'value2'
 
51
 
 
52
   row = table.delete('row-key')
 
53
 
 
54
 
 
55
Core documentation
 
56
==================
10
57
 
11
58
.. toctree::
12
 
   :maxdepth: 1
 
59
   :maxdepth: 2
13
60
 
14
 
   introduction
15
61
   installation
16
 
   tutorial
 
62
   user
17
63
   api
 
64
 
 
65
 
 
66
Additional documentation
 
67
========================
 
68
 
 
69
.. toctree::
 
70
   :maxdepth: 1
 
71
 
18
72
   news
19
73
   development
20
74
   todo
 
75
   faq
21
76
   license
22
77
 
23
78
 
24
 
.. rubric:: External links
 
79
External links
 
80
==============
25
81
 
26
 
* `Documentation <http://happybase.readthedocs.org/>`_ (readthedocs.org)
 
82
* `Online documentation <http://happybase.readthedocs.org/>`_ (Read the Docs)
27
83
* `Downloads <http://pypi.python.org/pypi/happybase/>`_ (PyPI)
28
84
* `Source code <https://github.com/wbolster/happybase>`_ (Github)
29
85
 
30
86
 
31
 
.. rubric:: Indices and tables
 
87
Indices and tables
 
88
==================
32
89
 
33
90
* :ref:`genindex`
34
91
* :ref:`modindex`