Skip to content

Conversation

wvangeit
Copy link
Contributor

What do these changes do?

This is the final piece to make the MM service job fetching faster. It adds a new endpoint that extends the function job endpoint with also the up to date status of the job.

Related issue/s

ITISFoundation/osparc-issues#1899

How to test

Run MM service with and without
There are also tests in the api and webserver tests

Dev-ops

No changes

@wvangeit wvangeit added this to the Narsil milestone Aug 29, 2025
@wvangeit wvangeit self-assigned this Aug 29, 2025
@wvangeit wvangeit added a:webserver webserver's codebase. Assigning the area is particularly useful for bugs a:apiserver api-server service labels Aug 29, 2025
Copy link

codecov bot commented Sep 1, 2025

Codecov Report

❌ Patch coverage is 87.03704% with 21 lines in your changes missing coverage. Please review.
✅ Project coverage is 87.85%. Comparing base (6836ff2) to head (0f804f6).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #8278      +/-   ##
==========================================
+ Coverage   87.79%   87.85%   +0.06%     
==========================================
  Files        1940     1726     -214     
  Lines       75214    70177    -5037     
  Branches     1309      979     -330     
==========================================
- Hits        66034    61656    -4378     
+ Misses       8787     8219     -568     
+ Partials      393      302      -91     
Flag Coverage Δ
integrationtests 63.97% <41.17%> (+0.31%) ⬆️
unittests 86.43% <87.03%> (-0.08%) ⬇️
Components Coverage Δ
pkg_aws_library ∅ <ø> (∅)
pkg_celery_library ∅ <ø> (∅)
pkg_dask_task_models_library ∅ <ø> (∅)
pkg_models_library 93.13% <100.00%> (+0.01%) ⬆️
pkg_notifications_library ∅ <ø> (∅)
pkg_postgres_database ∅ <ø> (∅)
pkg_service_integration 70.19% <ø> (ø)
pkg_service_library 71.05% <0.00%> (-0.04%) ⬇️
pkg_settings_library ∅ <ø> (∅)
pkg_simcore_sdk 85.03% <ø> (ø)
agent 93.53% <ø> (ø)
api_server 91.93% <88.23%> (-0.01%) ⬇️
autoscaling 95.77% <ø> (ø)
catalog 92.34% <ø> (ø)
clusters_keeper 99.13% <ø> (ø)
dask_sidecar 91.81% <ø> (-0.57%) ⬇️
datcore_adapter 97.94% <ø> (ø)
director 75.90% <ø> (-0.09%) ⬇️
director_v2 90.89% <ø> (+0.55%) ⬆️
dynamic_scheduler 96.27% <ø> (ø)
dynamic_sidecar 90.46% <ø> (ø)
efs_guardian 89.62% <ø> (ø)
invitations 91.44% <ø> (ø)
payments 92.61% <ø> (ø)
resource_usage_tracker 92.18% <ø> (ø)
storage 86.36% <ø> (-0.13%) ⬇️
webclient ∅ <ø> (∅)
webserver 88.00% <82.35%> (-0.03%) ⬇️

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6836ff2...0f804f6. Read the comment docs.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Contributor

mergify bot commented Sep 1, 2025

🧪 CI Insights

Here's what we observed from your CI run for 0f804f6.

🟢 All jobs passed!

But CI Insights is watching 👀

Copy link
Contributor

@GitHK GitHK left a comment

Choose a reason for hiding this comment

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

A few questions

@wvangeit wvangeit requested review from GitHK and pcrespov September 2, 2025 08:29
Copy link
Contributor

@GitHK GitHK left a comment

Choose a reason for hiding this comment

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

Thanks!

@wvangeit wvangeit removed the 🤖-automerge marks PR as ready to be merged for Mergify label Sep 2, 2025
@wvangeit wvangeit requested review from Copilot and pcrespov September 2, 2025 14:36
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds a new endpoint to list function jobs with their status information, completing functionality to make the MM service job fetching faster. The implementation includes a list_function_jobs_with_status endpoint that extends the existing function job listing with up-to-date status data and optimized output fetching.

  • Adds new list_function_jobs_with_status endpoint across multiple service layers
  • Modifies existing list_function_jobs endpoint to use the new status-aware implementation
  • Refactors job output retrieval logic into dedicated service methods for better code organization

Reviewed Changes

Copilot reviewed 21 out of 21 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
services/web/server/src/simcore_service_webserver/functions/_functions_service.py Implements core service logic for listing function jobs with status, including new decoder function
services/web/server/src/simcore_service_webserver/functions/_functions_repository.py Updates repository layer to use status-aware database queries
services/web/server/src/simcore_service_webserver/functions/_controller/_functions_rpc.py Adds RPC endpoint wrapper for the new functionality
services/api-server/src/simcore_service_api_server/api/routes/function_jobs_routes.py Implements REST API endpoint with include_status query parameter
services/api-server/src/simcore_service_api_server/_service_function_jobs.py Adds service layer logic for status-aware job listing and output retrieval
services/api-server/src/simcore_service_api_server/_service_jobs.py Refactors job output methods into JobService class
packages/models-library/src/models_library/functions.py Defines new data models for function jobs with status information
packages/service-library/src/servicelib/rabbitmq/rpc_interfaces/webserver/functions/functions_rpc_interface.py Adds RPC interface method for the new endpoint

Copy link
Member

@pcrespov pcrespov left a comment

Choose a reason for hiding this comment

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

thx

@wvangeit wvangeit added the 🤖-automerge marks PR as ready to be merged for Mergify label Sep 3, 2025
Copy link

sonarqubecloud bot commented Sep 3, 2025

@wvangeit
Copy link
Contributor Author

wvangeit commented Sep 3, 2025

@mergify refresh

Copy link
Contributor

mergify bot commented Sep 3, 2025

refresh

✅ Pull request refreshed

@wvangeit
Copy link
Contributor Author

wvangeit commented Sep 3, 2025

@mergify queue

Copy link
Contributor

mergify bot commented Sep 3, 2025

queue

🛑 Configuration not compatible with a branch protection setting

The branch protection setting Require branches to be up to date before merging is not compatible with max_parallel_checks>1, queue_conditions != merge_conditions and must be unset.

@wvangeit wvangeit merged commit 62244f5 into ITISFoundation:master Sep 3, 2025
94 of 95 checks passed
@wvangeit wvangeit deleted the fj_list_with_status branch September 3, 2025 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🤖-automerge marks PR as ready to be merged for Mergify a:apiserver api-server service a:webserver webserver's codebase. Assigning the area is particularly useful for bugs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants