com.capitalone.dashboard.repository.HudsonJobRepository Maven / Gradle / Ivy
package com.capitalone.dashboard.repository;
import com.capitalone.dashboard.model.HudsonJob;
import org.bson.types.ObjectId;
import org.springframework.data.mongodb.repository.Query;
import java.util.List;
public interface HudsonJobRepository extends BaseCollectorItemRepository {
@Query(value="{ 'collectorId' : ?0, options.instanceUrl : ?1, options.jobName : ?2}")
HudsonJob findHudsonJob(ObjectId collectorId, String instanceUrl, String jobName);
@Query(value="{ 'collectorId' : ?0, options.instanceUrl : ?1, enabled: true}")
List findEnabledHudsonJobs(ObjectId collectorId, String instanceUrl);
}