Interface SystemGraphRepository

All Superinterfaces:
org.springframework.data.repository.CrudRepository<SystemGraph,UUID>, org.springframework.data.jpa.repository.JpaRepository<SystemGraph,UUID>, org.springframework.data.repository.ListCrudRepository<SystemGraph,UUID>, org.springframework.data.repository.ListPagingAndSortingRepository<SystemGraph,UUID>, org.springframework.data.repository.PagingAndSortingRepository<SystemGraph,UUID>, org.springframework.data.repository.query.QueryByExampleExecutor<SystemGraph>, org.springframework.data.repository.Repository<SystemGraph,UUID>

@Repository public interface SystemGraphRepository extends org.springframework.data.jpa.repository.JpaRepository<SystemGraph,UUID>
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    void
    updateGraphDataAndFingerprintIfFingerprintChanged(String systemName, byte[] graphData, String fingerprint)
     

    Methods inherited from interface org.springframework.data.repository.CrudRepository

    count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, save

    Methods inherited from interface org.springframework.data.jpa.repository.JpaRepository

    deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlush

    Methods inherited from interface org.springframework.data.repository.ListCrudRepository

    findAll, findAllById, saveAll

    Methods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository

    findAll

    Methods inherited from interface org.springframework.data.repository.PagingAndSortingRepository

    findAll

    Methods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor

    count, exists, findAll, findBy, findOne
  • Method Details

    • existsBySystemName

      boolean existsBySystemName(String systemName)
    • updateGraphDataAndFingerprintIfFingerprintChanged

      @Modifying @Transactional @Query(value="UPDATE system_graph SET graph_data = :graphData, fingerprint = :fingerprint, modified_at = CURRENT_TIMESTAMP WHERE system_name = :systemName AND fingerprint != :fingerprint", nativeQuery=true) void updateGraphDataAndFingerprintIfFingerprintChanged(String systemName, byte[] graphData, String fingerprint)