CouchConf-Berlin-Developing-with-Couchbase-Server

750
-1

Published on

Published in: Technology, Design
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
750
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
18
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • CouchConf-Berlin-Developing-with-Couchbase-Server

    1. 1. Developing with Couchbase Server 1
    2. 2. 2
    3. 3. Easy to Easy to Get(Building on) Open 2
    4. 4. LANGUAGE 3
    5. 5. LANGUAGERuby, Java, PHP, C#, Python, 3
    6. 6. LANGUAGERuby, Java, PHP, C#, Python, More soon! 3
    7. 7. SUPPORT ALL COUCHBASE 4
    8. 8. SUPPORT ALL COUCHBASE get, set, add, replace, 4
    9. 9. SUPPORT ALL COUCHBASE get, set, add, replace, touch, gat, getl, sync 4
    10. 10. SUPPORT ALL COUCHBASE get, set, add, replace, touch, gat, getl, sync views 4
    11. 11. BEST PRACTICES ARE BUILT 5
    12. 12. BEST PRACTICES ARE BUILT Data Access Patterns 5
    13. 13. BEST PRACTICES ARE BUILT Data Access Patterns Pagination 5
    14. 14. BEST PRACTICES ARE BUILT Data Access Patterns PaginationAccess to Development and Production 5
    15. 15. THE SERVER 6
    16. 16. THE SERVER(BUCKETS AND VIEWS) 6
    17. 17. THE DATA 7
    18. 18. THE DATA(PRESIDENTS AND U.S. 7
    19. 19. THE VIEWS 8
    20. 20. THE VIEWS(PRESIDENT_NAMES, BY_STATE, PRESIDENT_EVENTS) 8
    21. 21. QUICK RUBY 9
    22. 22. QUICK RUBY(COUCHBASE GEM IN 9
    23. 23. 10
    24. 24. require couchbaserequire uuidDEFAULT_BUCKET_URL = http://localhost:8091/pools/defaultcouchbase = Couchbase.new(DEFAULT_BUCKET_URL) 10
    25. 25. require couchbaserequire uuidDEFAULT_BUCKET_URL = http://localhost:8091/pools/defaultcouchbase = Couchbase.new(DEFAULT_BUCKET_URL)design_doc = couchbase.design_docs[‘design_doc’]design_doc.views[‘president_names’, ‘president_events’, ‘by_party’,‘by_state’] 10
    26. 26. require couchbaserequire uuidDEFAULT_BUCKET_URL = http://localhost:8091/pools/defaultcouchbase = Couchbase.new(DEFAULT_BUCKET_URL)design_doc = couchbase.design_docs[‘design_doc’]design_doc.views[‘president_names’, ‘president_events’, ‘by_party’,‘by_state’]design_doc.president_names(:reduce => false).each { |doc| puts "#{doc[key]}: #{doc[value]}"} 10
    27. 27. CONNECTING TO THEimport net.spy.memcached.CouchbaseClientimport net.spy.memcached.protocol.couch.Queryimport java.util.LinkedListSERVER_URI = "http://127.0.0.1:8091/pools"uris = new LinkedList()uris.add(URI.create(SERVER_URI))couchbase = new CouchbaseClient(uris,"default", "") 11
    28. 28. Aquery = new Query()query.setReduce(false)view = couchbase.getView("design_doc","president_names")future = couchbase.asyncQuery(view, query)viewResponse = future.get()iterator = viewResponse.iterator()while (iterator.hasNext()) { viewRow = iterator.next() println("Key: " + viewRow.key + ", Value:" + viewRow.value)} 12
    29. 29. QUICK PHP 13
    30. 30. QUICK PHP(PHP-COUCHBASE IN 13
    31. 31. include "Couchbase.php";$cb = new Couchbase;$cb->addCouchbaseServer("localhost");$view = $cb->getView("design_doc", "by_state");$result = $view->getResult();foreach($result AS $row) { echo $row->value;} 14
    32. 32. GET 15
    33. 33. GETgem install couchbase 15
    34. 34. GET gem install couchbasehttp://www.couchbase.org/code/couchbase/ 15
    35. 35. GET gem install couchbasehttp://www.couchbase.org/code/couchbase/http://github.com/couchbaselabs/php- 15
    36. 36. HTTP:// 16
    37. 37. HTTP:// DownloadGetting Started Guides In-Depth Tutorials Screencasts 16
    38. 38. QUESTION 17
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×