package com.cameleer.server.core.storage;

import com.cameleer.common.graph.RouteGraph;
import com.cameleer.server.core.ingestion.TaggedDiagram;

import java.util.List;
import java.util.Map;
import java.util.Optional;

public interface DiagramStore {

    void store(TaggedDiagram diagram);

    Optional<RouteGraph> findByContentHash(String contentHash);

    Optional<String> findContentHashForRoute(String routeId, String instanceId);

    Optional<String> findContentHashForRouteByAgents(String routeId, List<String> instanceIds);

    Map<String, String> findProcessorRouteMapping(String applicationId, String environment);
}
