package es.uv.dagarcos.master.repository;

import es.uv.dagarcos.master.domain.Shard;
import es.uv.dagarcos.master.domain.ShardLifecycleEvent;
import es.uv.dagarcos.master.domain.ShardLifecycleEventType;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

public interface ShardLifecycleEventRepository extends JpaRepository<ShardLifecycleEvent, Long> {

    List<ShardLifecycleEvent> findByShardOrderByTimestampDesc(Shard shard);

    List<ShardLifecycleEvent> findByEventType(ShardLifecycleEventType eventType);
}