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

Save local mode jobs #1854

Open
wants to merge 25 commits into
base: main
Choose a base branch
from
Open

Save local mode jobs #1854

wants to merge 25 commits into from

Conversation

kt474
Copy link
Member

@kt474 kt474 commented Aug 12, 2024

Summary

Dependent on making PrimitiveJob serializable (Qiskit PR Qiskit/qiskit#12963)

Now when local jobs are run, they will be pickled and saved in a local_jobs directory as job_id.pkl. These jobs can then be retrieved with job() or jobs() and deleted with delete_job(). Ended up using pickle instead of json encoder/decoder because PrimitiveJob takes a function (sampler/estimator run) as one of it's init parameters.

Details and comments

When to delete the data. This should be user-configurable and the default can be 30 days.

Not sure the best way to auto delete without some sort of cron job

Fixes #1607

@kt474 kt474 marked this pull request as ready for review August 19, 2024 19:32
@kt474 kt474 changed the title [WIP] Save local mode jobs Save local mode jobs Aug 20, 2024
@kt474 kt474 requested a review from ptristan3 August 20, 2024 17:51
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.

Add job related methods to QiskitRuntimeLocalService
2 participants