Scaladex: Implement Intermediate Artifacts Page
Introduction
Scaladex is a central repository that indexes and catalogs open-source Scala libraries.
Currently users face difficulties while accessing artifacts in projects with multiple artifacts, as they rely on dropdown menu within the "Versions" tab, making it difficult to quickly view all available artifacts.
Project Goal
Add an Intermediate Artifacts Page, the new Artifacts page will provide users with a convenient way to browse all artifacts of a project, grouped by their latest versions.
Key Project Milestones
Task | Status | Link |
---|---|---|
UI: Implement new Artifacts Page | completed | Link |
Backend: Group Artifacts by Latest Version | completed | Link |
Backend: Implement Filtering | completed | Link |
UI: Modify Versions Page | completed | Link |
Final Merged Pull Request- Link
Detailed Breakdown
UI: Implement New Artifacts Page and Modify Versions Page
Problem
The objective was to improve user experience by creating a dedicated Artifacts page and updating the Versions page, which would display all artifact versions with filtering options, and updating the Versions page to align with new UI standards.
Technical Challenges
Ensuring that the new page layouts were functional and aesthetically pleasing across different devices and screen sizes.
Integrating filters that allow users to filter artifacts by binary versions and pre-releases.
Solution
We used Bootstrap’s grid system to ensure the layouts were responsive.
The filtering functionality was implemented to ensure a seamless experience.
Backend: Group Artifacts by Latest Version and Implement Filtering
Problem
The backend needed to efficiently group artifacts by their latest versions and implement filtering functionality that could handle a variety of query parameters.
Technical Challenges
Grouping artifacts by their latest version required careful consideration of data structures to ensure performance.
Implementing filtering logic to ensure only the relevant artifacts based on the user’s selection are displayed.
Solution
We used Scala's collection methods to group artifacts by their latest version. This was done using a
groupBy
operation followed by filtering.We implemented a filtering mechanism using Scala’s collection methods like
filter
,map
to apply the necessary filters on the grouped artifacts.
val groupedArtifacts = artifactsByName
.groupBy {
case (_, artifacts) =>
artifacts.maxBy(_.version).version
}
.map {
case (latestVersion, artifactsByName) =>
latestVersion -> artifactsByName
.map {
case (name, artifacts) =>
name -> artifacts
.filter(_.version == latestVersion)
}
.filter {
case (_, artifacts) =>
params.binaryVersions.forall(binaryVersion =>
artifacts
.exists(_.binaryVersion == binaryVersion)
)
}
}
Highlights
- User-Friendly Interface: The new Artifacts page is designed with user experience in mind, making it easier to navigate and find what you need.
- Efficient Grouping: Artifacts are now grouped by their latest versions, saving time and effort.
- Filtering: Implemented filtering options to help quickly locate specific artifacts.
Visual Changes
Here are some screenshots showcasing the new UI:
New Artifacts Page
Modified Versions Page
Reflections
Working on the Scaladex project has been a significant professional and personal experience. It wasn’t just about coding—it was about growth, learning, and contributing to an open-source community.
This project sharpened my problem-solving abilities and taught me the importance of writing clean, maintainable code in a collaborative environment.
This project not only enhanced my technical skills but also sharpened my soft skills. Collaborating with mentors and aligning with the project’s vision required clear communication and adaptability. I learned to accept feedback and use it for refining my work.
Personally, this project served as a reminder of my passion for solving complex problems. There were moments of frustration when things didn’t work as expected, but each obstacle overcame fueled my determination to succeed.
I’m deeply grateful to my mentors, Adrien Piquerez and Kannupriya Kalra for their guidance and support, which made this journey truly enriching.