use of com.hortonworks.registries.storage.StorableKey in project streamline by hortonworks.
the class StreamCatalogService method removeBranchRule.
public TopologyBranchRule removeBranchRule(Long topologyId, Long id, Long versionId) throws Exception {
TopologyBranchRule topologyBranchRule = getBranchRule(topologyId, id, versionId);
if (topologyBranchRule != null) {
topologyBranchRule = dao.remove(new StorableKey(TOPOLOGY_BRANCHRULEINFO_NAMESPACE, topologyBranchRule.getPrimaryKey()));
topologyBranchRule.setVersionTimestamp(updateVersionTimestamp(versionId).getTimestamp());
}
return topologyBranchRule;
}
use of com.hortonworks.registries.storage.StorableKey in project streamline by hortonworks.
the class StreamCatalogService method getStreamInfo.
public TopologyStream getStreamInfo(Long topologyId, Long streamId, Long versionId) {
TopologyStream topologyStream = new TopologyStream();
topologyStream.setId(streamId);
topologyStream.setVersionId(versionId);
TopologyStream result = dao.get(new StorableKey(STREAMINFO_NAMESPACE, topologyStream.getPrimaryKey()));
if (result == null || !result.getTopologyId().equals(topologyId)) {
return null;
}
result.setVersionTimestamp(getVersionTimestamp(versionId));
return result;
}
Aggregations