Please Help


#1
  1. Do you mean conneting to both MySQL and CB on the Application Level and having a persistent connection to both?
    2.Do mean have CB on a one node cluster and adding more nodes? or having a small 3 - 5 node cluster and scaling from there with adding more nodes and XDCR?

#2
  1. Yes. i asked because we are looking at possbility of writing a java program to Migrate a university’s portal records from Mysql to Cauchbase.
  2. I mean how can i demonstrate scalability claim of CauchBase on a single/distributed system?

#3

Hi,

  1. is it possible to connect to Mysql database while working with CouchBase from a java application
  2. is it possible to demonstrate the scalability claim of CouchBase on a single system?

#4

One system to another including CauchBase to Mysql?


#5

Hello,

  1. Sure you can connect to your MySQL instance and Couchbase cluster from the same Java program. Nothing special here.
    You have to create a singleton to get your Couchbase connection, see for example this part of the beer sample application:
    https://github.com/couchbaselabs/beersample-java/blob/master/src/main/ja
    then use it
    https://github.com/couchbaselabs/beersample-java/blob/master/src/main/ja
    And in the same application you can connect to your RDBMS and manipulate the data as you want
  2. You can easily add new nodes to your cluster, you can for example follow these steps from the documentation:
    http://www.couchbase.com/docs/couchbase-manual-2.0/couchbase-admin-tasks
    Note:
    Couchbase has now a plugin for Talend ETL, this will help you to migrate data from one system to another.
    Regards

#6

Sainadeyi,
1.Moving from MySQL to Couchbase does take a little work. I would first recommend that you take advantage of the Memecached part and start storing data encoded in json. From there you can play around with doing map/reduce views. Then next using the Couchbase -> ElasticSearch(XDCR).
2. Its easy to start off with 3 - 5 nodes in one cluster. I would not add more nodes after the 3-5, but set up a new 3 - 5 node cluster with XDCR two have two master-master replicated system.


#7

Hi,
Thanks for your response. I want to design a java GUI application that can transform data from a given mysql database table into couchbase JSON document. So i can continue using cauchbase view for querying the data. How ever, i am not that strong using java but have strong passion to do this task. 1. Do i use J2SE or must it be java web application? 2. I will o much appreciate if you can break down some few steps or offer some advice on how to go about this.
Regards,


#8

Saniadeyi,

  1. It depends on the way you structure the documents in Couchbase. there are two way of doing it.
    1a. Direct Migration(MySQL) Table->Row = Document. Usually there is normalization data referring to other tables.
    1b. Denormalized structure, Bring sources from multiple MySQL tables in to one JSON document.
    Once you figure how you want to sturucture your data. Then its a simple matter storing the document into Couchbase with ---- SET(key,json_encode(your_document)) ----- from here you can use any application to do a simple set.
    Checkout the core JAVA SDK operations on CB. www.couchbase.com/docs/couchbase-sdk-java-1.1/api-reference-summary.html

#9

if i have for laptops running windows 7 O.S, there is a wireless network within, do i still need to install cauchbase server on all the system to form a clauster/distribution? At what point are the username/password required by the cauchbase server2.0 for participating nodes created on those node?
Regards.


#10

Hi.
Ok. thanks for your response. Adding a server to a cluster gives warning message “Warning – Adding a server to this cluster means all data on that server will be removed”. What does that imply? When i proceed to add, i get a message “Attention - Prepare join failed. Authentication failed. Verify username and password. Got HTTP status 401 from REST call post to http://192.168.137.1:8091/engageCluster2. Body was: []”.
what am i not getting right?
Regards?


#11

“Warning – Adding a server to this cluster means all data on that server will be removed”. What does that imply?"
It will NOT eraser data in your current cluster. But rather prep your new node that you want to add by wiping the slate clean on the server.
The second machine 192.168.137.1:8091 sounds like you are pointing to a machine in your local enviroment (under your own router / switch). The 401 response is it saying I can connect but you gave me bad password.www.couchbase.com/docs/couchbase-manual-2.1.0/couchbase-admin-restapi-key-concepts-httpstatus.html

  1. I would recommend since you are just testing the system to reinstall couchbase into machine2. and add the new machine through the ADMIN CONSOLE in machine 1.