-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
[OldMongo FC-0004] ADR for migrate certificate signatures #31171
Conversation
Thanks for the pull request, @UvgenGen! Please note that it may take us up to several weeks or months to complete a review and merge your PR. Feel free to add as much of the following information to the ticket as you can:
All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here. Please let us know once your PR is ready for our review and all tests are green. |
96140a6
to
ace63fa
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have a good grasp on what the data models and views are for this today, and whether the signature data canonically belongs in this app or in the Credentials service. I'd love to get more clarity on exactly what's going where as part of this ADR.
@@ -0,0 +1,45 @@ | |||
|
|||
Transfer certificate signatures from Mongo |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The title should specify where they're being transferred to.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, updated
|
||
Context | ||
******* | ||
As a part of Old Mongo Deprecation work https://github.com/openedx/public-engineering/issues/62 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use the link syntax for rST here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The links were changed
|
||
* credentials API must be extended to provide endpoints for adding and retrieving signatures | ||
|
||
* `CourseCertificateViewSet` API |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a viewset from the Credentials service, right? Is this going to involve the certificates app in edx-platform at all then?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that's a viewset from the Credentials service. For now we planning transfer only certificate signatures but get other certificate data from mongo.
|
||
* `CourseCertificateViewSet` API | ||
|
||
* added signal to copy signatures from Mongo to Credentials on course publish, certificate or signature update |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* added signal to copy signatures from Mongo to Credentials on course publish, certificate or signature update | |
* add a new `OpenEdxPublicSignal` that is emitted from Studio whenever certificate-related data is changed (e.g. certificate image upload, course import). The signature image can be exposed as a URL. | |
* signal receiver will copy the signature image to [????] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated
|
||
* added signal to copy signatures from Mongo to Credentials on course publish, certificate or signature update | ||
* added management command to copy signatures from (OLD or both?) Mongo to Credentials | ||
* updated certifecate views for getting signatures from Credentials |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* updated certifecate views for getting signatures from Credentials | |
* update certificate views for getting signatures from Credentials |
* `CourseCertificateViewSet` API | ||
|
||
* added signal to copy signatures from Mongo to Credentials on course publish, certificate or signature update | ||
* added management command to copy signatures from (OLD or both?) Mongo to Credentials |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would strongly push for copying signatures out of both Old and Split Mongo. The deprecation of Old Mongo is prompting this work, but Credentials should have its own copy of this data since it's needed for serving certificate information. Also, it'd be weird to special case it for only Old Mongo courses (which are very rare), while having a different code path for Split.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ormsbee Course certs are served out of LMS not Credentials, so are you proposing that we should serve Course Certs out of LMS but globally serve the signatures out of Credentials (for both course and program certs) prior to migrating the Course Certs themselves?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@hurtstotouchfire in the ADR we stated that signatures and certificate configurations will be copied to Credentials, but the signatures will be used only when signature from MongoDB is not available (right now this case is specific for Old Mongo courses). The certificate configurations will be pushed to credentials using the management command (planned only for Old Mongo courses), and based on new course certificate update signal (for Split courses).
In the future, we would like to move certificate rendering logic from LMS to Credentials+MFEs, as was proposed in BD-11.
I hope the intermediate step, when we need to get certificates configuration from MongoDB, but signatures from Credentials for Split courses, wouldn't be required.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@hurtstotouchfire We are proposing that the complete migration of course certificates is out of scope for this project. The driver here is to unblock the full deprecation of the Old Mongo Modulestore. Achieving full deprecation requires moving signature assets and we want to do it in a way aligned with the future vision for all certificates living in the Credentials IDA.
b2a9309
to
211706b
Compare
|
||
Decision | ||
******** | ||
To keep access to the certificate signatures will be used external signatures from credentials on WEB/PDF |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's something garbled in this sentence.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, we have updated it to be more specific
|
||
* credentials API must be extended to provide endpoints for adding and retrieving signatures | ||
|
||
* `CourseCertificateViewSet` API must be updated with possibility uploading signature |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
by "possibility", do you mean "optionally"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's right, the signature create/update should be optional when pushing a certificate configuration to Credentials from LMS
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated
211706b
to
de7ae25
Compare
8c5602a
to
3c9550e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am adding my approval, but I would like to hear if @ormsbee has any additional feedback before it is merged.
3c9550e
to
4434031
Compare
@ormsbee I have changed the ADR's status to |
Ack, sorry, forgot to merge this. But will do so once checks finish running. |
@UvgenGen 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future. |
EdX Release Notice: This PR has been deployed to the staging environment in preparation for a release to production. |
EdX Release Notice: This PR has been deployed to the production environment. |
Description
ADR about certificate signatures migration.
Other information