public class PersistenceCouchDB
extends org.gcube.documentstore.persistence.PersistenceBackend
| Modifier and Type | Field and Description |
|---|---|
static String |
DB_NAME |
protected org.gcube.common.couchdb.connector.HttpCouchClient |
httpCouchClient |
static String |
PASSWORD_PROPERTY_KEY |
static String |
URL_PROPERTY_KEY |
static String |
USERNAME_PROPERTY_KEY |
| Constructor and Description |
|---|
PersistenceCouchDB() |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
protected void |
closeConnection() |
protected void |
createItem(org.codehaus.jackson.JsonNode node,
String id) |
protected static org.gcube.documentstore.records.Record |
jsonNodeToUsageRecord(org.codehaus.jackson.JsonNode jsonNode) |
void |
openConnection() |
protected void |
prepareConnection(org.gcube.documentstore.persistence.PersistenceBackendConfiguration configuration) |
protected void |
reallyAccount(org.gcube.documentstore.records.Record record) |
static org.codehaus.jackson.JsonNode |
usageRecordToJsonNode(org.gcube.documentstore.records.Record record) |
protected org.gcube.common.couchdb.connector.HttpCouchClient httpCouchClient
public static final String URL_PROPERTY_KEY
public static final String USERNAME_PROPERTY_KEY
public static final String PASSWORD_PROPERTY_KEY
public static final String DB_NAME
public void close()
throws Exception
close in class org.gcube.documentstore.persistence.PersistenceBackendExceptionprotected void prepareConnection(org.gcube.documentstore.persistence.PersistenceBackendConfiguration configuration)
throws Exception
prepareConnection in class org.gcube.documentstore.persistence.PersistenceBackendExceptionpublic void openConnection()
throws Exception
openConnection in class org.gcube.documentstore.persistence.PersistenceBackendExceptionprotected void createItem(org.codehaus.jackson.JsonNode node,
String id)
throws Exception
Exceptionprotected void closeConnection()
throws Exception
closeConnection in class org.gcube.documentstore.persistence.PersistenceBackendExceptionprotected void reallyAccount(org.gcube.documentstore.records.Record record)
throws Exception
reallyAccount in class org.gcube.documentstore.persistence.PersistenceBackendExceptionpublic static org.codehaus.jackson.JsonNode usageRecordToJsonNode(org.gcube.documentstore.records.Record record)
throws Exception
ExceptionCopyright © 2017. All Rights Reserved.