Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion project-properties.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ project.ext {
dependencyRepos = ["commons", "commons-rules", "commons-model", "commons-bom"]
releaseMode = project.hasProperty("releaseMode") ? project.releaseMode.toBoolean() : false
hasDBSchema = project.hasProperty("DB_SCHEMA_POSTGRES")
scriptsUrl = commonScriptsUrl + (releaseMode ? getProperty('scripts.version') : '01231cd')
scriptsUrl = commonScriptsUrl + (releaseMode ? getProperty('scripts.version') : '5.14.0')
migrationsUrl = migrationsScriptsUrl + (releaseMode ? getProperty('migrations.version') : 'EPMRPP-111517')

//TODO refactor with archive download
Expand Down
4 changes: 0 additions & 4 deletions src/main/java/com/epam/ta/reportportal/dao/LogRepository.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,6 @@ public interface LogRepository extends ReportPortalRepository<Log, Long>, LogRep

List<Log> findLogsByLogTime(Timestamp timestamp);

long countLogsByTestItemItemIdIn(List<Long> testItemIds);

long countLogsByLaunchId(Long launchId);

@Query(value = """
WITH ParentPath AS (
SELECT path
Expand Down
46 changes: 0 additions & 46 deletions src/main/java/com/epam/ta/reportportal/dao/TestItemRepository.java
Original file line number Diff line number Diff line change
Expand Up @@ -179,17 +179,6 @@ Slice<TestItem> findTestItemsByAttributeAndStatuses(@Param("projectId") Long pro
@Param("value") String attributeValue, @Param("statuses") List<String> statuses,
Pageable pageable);

/**
* Retrieve list of test item ids for provided launch
*
* @param launchId Launch id
* @return List of test item ids
*/
@Query(value = "SELECT item_id FROM test_item WHERE launch_id = :launchId UNION "
+ "SELECT item_id FROM test_item WHERE retry_of IS NOT NULL AND retry_of IN "
+ "(SELECT item_id FROM test_item WHERE launch_id = :launchId);", nativeQuery = true)
List<Long> findIdsByLaunchId(@Param("launchId") Long launchId);

/**
* Retrieve the {@link List} of the {@link TestItem#getItemId()} by launch ID,
* {@link StatusEnum#name()} and {@link TestItem#isHasChildren()} == false
Expand Down Expand Up @@ -525,41 +514,6 @@ Optional<Long> findLatestIdByTestCaseHashAndLaunchIdAndParentId(
@Query(value = "SELECT t.name FROM test_item t WHERE t.item_id = :itemId", nativeQuery = true)
Optional<String> findItemNameByItemId(Long itemId);

/**
* Count items by launch id
*
* @param launchId Launch id
* @return Number of {@link TestItem}
*/
long countTestItemByLaunchId(Long launchId);

/**
* Select items with provided parent ids
*
* @param parentIds Parent test items id
* @return List of item ids
*/
@Query(value = "SELECT t.item_id FROM test_item t WHERE t.parent_id IN (:parentIds)", nativeQuery = true)
List<Long> findIdsByParentIds(@Param("parentIds") Long... parentIds);

/**
* Select item paths by provided parent ids
*
* @param parentIds Parent test items id
* @return List of item paths
*/
@Query(value = "SELECT CAST(t.path AS VARCHAR) FROM test_item t WHERE t.parent_id IN (:parentIds)", nativeQuery = true)
List<String> findPathsByParentIds(@Param("parentIds") Long... parentIds);

/**
* Select items ids with provided retry of
*
* @param retryOf Retry of test item id
* @return List of item ids
*/
@Query(value = "SELECT t.item_id FROM test_item t WHERE t.retry_of = :retryOf", nativeQuery = true)
List<Long> findIdsByRetryOf(@Param("retryOf") Long retryOf);

/**
* Returns IDs (from itemIds) that have nested steps.
*
Expand Down