本文整理了Java中proj.zoie.store.ZoieStore
类的一些代码示例,展示了ZoieStore
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZoieStore
类的具体详情如下:
包路径:proj.zoie.store.ZoieStore
类名称:ZoieStore
暂无
代码示例来源:origin: com.senseidb.zoie/zoie-core
@Override
public String getVersion() {
return _store.getVersion();
}
代码示例来源:origin: senseidb/zoie
@Override
public void stop() {
try {
_store.close();
} catch (IOException e) {
logger.error(e.getMessage(), e);
}
}
代码示例来源:origin: com.senseidb.zoie/zoie-core
@Override
public void start() {
try {
_store.open();
} catch (Exception e) {
logger.error(e.getMessage(), e);
}
}
代码示例来源:origin: senseidb/zoie
public void flushEvents() throws ZoieException {
try {
_store.commit();
} catch (Exception e) {
throw new ZoieException(e.getMessage(), e);
}
}
代码示例来源:origin: senseidb/zoie
@Override
public void consume(Collection<proj.zoie.api.DataConsumer.DataEvent<D>> data)
throws ZoieException {
for (DataEvent<D> datum : data) {
String version = datum.getVersion();
D obj = datum.getData();
try {
byte[] bytes = _serializer.toBytes(obj);
long id = _serializer.getUid(obj);
_store.put(id, bytes, version);
} catch (Exception e) {
logger.error(e.getMessage(), e);
}
}
}
代码示例来源:origin: senseidb/zoie
@Override
public byte[] handleQuery() throws Exception {
long uid = _idArray[_rand.nextInt(_idArray.length)];
return _store.get(uid);
}
代码示例来源:origin: com.senseidb.zoie/zoie-core
public void flushEvents() throws ZoieException {
try {
_store.commit();
} catch (Exception e) {
throw new ZoieException(e.getMessage(), e);
}
}
代码示例来源:origin: com.senseidb.zoie/zoie-core
@Override
public void consume(Collection<proj.zoie.api.DataConsumer.DataEvent<D>> data)
throws ZoieException {
for (DataEvent<D> datum : data) {
String version = datum.getVersion();
D obj = datum.getData();
try {
byte[] bytes = _serializer.toBytes(obj);
long id = _serializer.getUid(obj);
_store.put(id, bytes, version);
} catch (Exception e) {
logger.error(e.getMessage(), e);
}
}
}
代码示例来源:origin: senseidb/zoie
@Override
public String getVersion() {
return _store.getVersion();
}
代码示例来源:origin: senseidb/zoie
@Override
public void start() {
try {
_store.open();
} catch (Exception e) {
logger.error(e.getMessage(), e);
}
}
代码示例来源:origin: com.linkedin.zoie/zoie-core
public void flushEvents() throws ZoieException {
try{
_store.commit();
}
catch(Exception e){
throw new ZoieException(e.getMessage(),e);
}
}
代码示例来源:origin: com.senseidb.zoie/zoie-core
@Override
public void stop() {
try {
_store.close();
} catch (IOException e) {
logger.error(e.getMessage(), e);
}
}
代码示例来源:origin: com.linkedin.zoie/zoie-core
@Override
public void consume(Collection<proj.zoie.api.DataConsumer.DataEvent<D>> data)
throws ZoieException {
for (DataEvent<D> datum : data){
String version = datum.getVersion();
D obj = datum.getData();
try{
byte[] bytes = _serializer.toBytes(obj);
long id = _serializer.getUid(obj);
_store.put(id, bytes, version);
}
catch(Exception e){
logger.error(e.getMessage(),e);
}
}
}
代码示例来源:origin: senseidb/zoie
@Override
public String getCurrentVersion() {
return _store.getVersion();
}
代码示例来源:origin: com.linkedin.zoie/zoie-core
@Override
public void start() {
try{
_store.open();
}
catch(Exception e){
logger.error(e.getMessage(),e);
}
}
代码示例来源:origin: com.linkedin.zoie/zoie-core
@Override
public void stop() {
try {
_store.close();
} catch (IOException e) {
logger.error(e.getMessage(),e);
}
}
代码示例来源:origin: com.linkedin.zoie/zoie-core
@Override
public String getVersion() {
return _store.getVersion();
}
内容来源于网络,如有侵权,请联系作者删除!