Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only Show Distinct Artifact Log Ids on Search Results Page #38

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

puru-khedre
Copy link
Contributor

closes #27
This PR addresses the issue of multiple entries for the same Artifact log ID displayed in the search results due to various Artifact events for a particular Artifact Log ID.

Changes Made

  1. Showing the latest entry for an Artifact Log ID on the find Page
  2. Remove the Artifact Event Id field from UI and instead show the anchor link over the Artifact Log Id

Note

Removal of Pagination: Due to limitations with OpenSearch’s support for aggregation with pagination, pagination has been removed from the Find page. This change was necessary to ensure we could retrieve the most recent events for Artifact log IDs by applying aggregations.

From now on, the find page only shows 20 Results by default, and if the user searches on the find page then it shows all the records without any pagination.

@puru-khedre puru-khedre requested a review from dt2patel January 8, 2025 15:24
@@ -20,7 +20,7 @@ along with this software (see the LICENSE.md file). If not, see
</transition>
<actions>
<set field="queryString" from="anyField ?: '*' "/>
<service-call name="co.hotwax.alc.SearchServices.search#ArtifactLogIndexes" in-map="[queryString:queryString, additionalQueryMap:[artifactLogTypeId: artifactLogTypeId], pageIndex:pageIndex, pageSize:pageSize, pageNoLimit:pageNoLimit]" out-map="context"/>
<service-call name="co.hotwax.alc.SearchServices.search#DistantArtifactLogs" in-map="[queryString:queryString, additionalQueryMap:[artifactLogTypeId: artifactLogTypeId], pageNoLimit:!anyField]" out-map="context"/>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Spelling

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Spelling

Updated to RecentArtifactLogs

<set field="queryString" from="queryString ? elasticQueryAutoWildcard(queryString, true) : '*'"/>
<if condition="queryString"><set field="queryString" from="'(' + queryString + ')'"/></if>

<script><![CDATA[
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we're writing the whole service in script tag, why not just write service in that language directly instead of minilang?

Copy link
Contributor Author

@puru-khedre puru-khedre Jan 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I prefer the minilang due to in most of the services would mostly perform database operations through an entity facade, Here in search services we cannot use it. So, I continued using minilang and didn't think of using the Groovy scripts.

Should we starts to use the groovy files, I don't have any concrete reason for it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Only show distinct artifact log Ids
2 participants