[FOLIO-1948] PoC preview capability for PRs in a platform-core ui- module Created: 06/Apr/19  Updated: 03/Jun/20  Resolved: 03/May/19

Status: Closed
Project: FOLIO
Components: None
Affects versions: None
Fix versions: None

Type: Task Priority: P3
Reporter: Jakub Skoczen Assignee: John Malconian
Resolution: Done Votes: 0
Labels: platform-backlog
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original estimate: Not Specified

Issue links:
Blocks
blocks FOLIO-2119 Preview capability for PRs (Q2, devel... Closed
blocks UXPROD-1817 Preview capability for PRs (Q3, initi... Closed
blocks UXPROD-2118 Preview capability for PRs (Q4, final... Closed
blocks FOLIO-1596 enable platform builds for all ui-* m... Closed
Relates
relates to FOLIO-2001 host bundles for multiple PRs/reposit... Closed
relates to FOLIO-2002 clean up no longer needed tenants and... Closed
Sprint: CP: sprint 62
Story Points: 8
Development Team: Core: Platform

 Description   

The context for this issue is provided on the epic: UXPROD-1817 Closed

Goal

Provide a quick implementation of the PR preview capability for a selected UI module without introducing new CI processes, new multi-tenant deployment environment and new orchestration tools. It is understood that such implementation will not be optimal from the technical standpoint but it will demonstrate the preview functionality.

Assumptions

  • Enable the functionality for a single module only: [[TBD choose a UI module base on the frequency of PRs -- it can't be too high]]
  • Deploy the module with the entire platform-core, use the release branch of platform-core to provide platform dependencies (stripes) and companion UI modules.
  • Only allow released backend dependencies
  • Use the existing deployment approach which creates a new single-tenant FOLIO system from scratch (as used e.g for FOLIO-1577 Closed )
  • For the PoC it is acceptable that deployment take 15-20 minutes (time it take to provision a FOLIO system from scratch)

Further development

We have discussed an optimisation to the deployment process where the PR preview env is not deployed as a new environment but is created as a new tenant on an already existing multi-tenant FOLIO environment. This will require a new FOLIO environment and new processes in the CI. It likely won't require a new kind of deployment orchestrator.

Further optimisations would rely on a a new approach to deployments and orchestration that would allow running a more flexible and scalable (clustered) FOLIO environment, see UXPROD-1827 Closed and UXPROD-1823 Draft .



 Comments   
Comment by Anton Emelianov (Inactive) [ 09/Apr/19 ]
  1. To provision the system the similar pipeline will be used to build folio-release-core.aws.indexdata.com
  2. System rebuilds itself every night. All changes from yesterday will be wiped out.
  3. This POC will address UI module only.
  4. Only a single UI bundle can be deployed for this system.
  5. UI bundle will be deployed in the original location just like folio-release-core.aws.indexdata.com
  6. Jenkins will have a separate job that can build and deploy UI bundle multiple times per day.
  7. UI bundle will consist of the code included in UI module PR branch + the rest of folio release modules.
Comment by Jakub Skoczen [ 03/May/19 ]

John Malconian gave us a demo of the PoC and it looks really neat (there is a PR in mod-users that shows the functionality). There are some changes (I'd say improvements) compared to the original description of the PoC:

1. There is a dedicated environment for all PR previews (folio-release-pr)
2. This environment is build from released modules only (master branch of platform-core and platform-complete)
3. When a PR is opened the new module code is "injected" into the last released platform (platform-core or platform-complete) a new bundle is build and integration tests (only for that module) are run. Then a new tenant is created on folio-release-pr environmnent, backend modules are enabled and the bundle is deployed
4. The link is reported back to the PR.
5. When more changes are added to the PR the build is repeated and a new tenant created (old tenants are retained).

Comment by John Malconian [ 03/May/19 ]

Here are some links I'll leave up for a short time:

ui-users test PR for POC in Github: https://github.com/folio-org/ui-users/pull/820

ui-users PR job in Jenkins: https://jenkins-aws.indexdata.com/job/folio-org/job/ui-users/view/change-requests/job/PR-820/
Note: This job can be run manually in Jenkins by a FOLIO developer with the correct permissions)

The "preview" system built by the PR is at: https://folio-release-pr.aws.indexdata.com. Login as $

{TENANT}

admin - where TENANT is 'pr$

{PR_NUMBER}

_

{JENKINS_BUILD_NUMBER}

. (The link to the "preview" system and tenant created is posted to the Github PR conversation).

An immediate next step is to figure out how to host bundles for multiple PRs and repositories. This POC hosts the stripes bundle on https://folio-release-pr.aws.indexdata.com. This is not scalable past one repository. Stripes bundles are static, so a simple web service with a unique URL to the bundle is all that is required as well as a clean up process that removes old bundles and services.

Comment by Jakub Skoczen [ 06/May/19 ]

John Malconian I have created FOLIO-2001 Closed and FOLIO-2002 Closed for the follow up work. Please review it.

Generated at Thu Feb 08 23:17:04 UTC 2024 using Jira 1001.0.0-SNAPSHOT#100246-sha1:7a5c50119eb0633d306e14180817ddef5e80c75d.