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

Migration to the latest version of SaaS #479

Open
JaladJhamb opened this issue Feb 9, 2023 · 5 comments
Open

Migration to the latest version of SaaS #479

JaladJhamb opened this issue Feb 9, 2023 · 5 comments
Labels
question Further information or guidance required

Comments

@JaladJhamb
Copy link

The Question

So we have been asked to migrate our exisitng running tenants from SaaS v1 version to the latest version.

Environment

  • AWS SaaS Boost Version:

Other information

@JaladJhamb JaladJhamb added the triage Needs categorization and prioritization label Feb 9, 2023
@brtrvn
Copy link
Contributor

brtrvn commented Feb 9, 2023

@JaladJhamb please identify the fields you need from the SaaS Boost tenant service to operate your application.

@brtrvn brtrvn added question Further information or guidance required and removed triage Needs categorization and prioritization labels Feb 9, 2023
@JaladJhamb
Copy link
Author

@brtrvn, I have actually made a diff between the DynamoDB created by old and new SaaS. These were the attributes which were mentioned in the old but not in the new DynamoDB : computeSize, onboarding , overrideDefaults, planID, ALB, ECS_CLUSTER_LOG_GROUP, CODE_PIPELINE
And I have even attached the excel file which I used fo documenting the difference between both the tables.
DynamoDB_Schema.xlsx

@brtrvn
Copy link
Contributor

brtrvn commented Feb 17, 2023

I would not look at the DynamoDB table items. They are subject to change even more than the API. Here's a comparison of the tenant objects returned by the Tenant Service API in v1 vs. v2.

Data Type Tenant v1 Tenant v2
uuid id id
timestamp created created
timestamp modified modified
boolean active active
boolean provisioned provisioned
string onboardingStatus onboardingStatus
string name name
string subdomain subdomain
string planId billingPlan
boolean overrideDefaults ...replaced by tier, see below
string computeSize ...replaced by tier, see below
int memory ...replaced by tier, see below
int cpu ...replaced by tier, see below
int minCount ...replaced by tier, see below
int maxCount ...replaced by tier, see below
string tier
string hostname
map attributes
map resources resources
resources[CLOUDFORMATION] resources[CLOUDFORMATION][consoleUrl]
resources[VPC] resources[VPC][consoleUrl]
resources[ECS_CLUSTER] resources[ECS_CLUSTER][consoleUrl]
resources[ECS_CLUSTER_LOG_GROUP]
resources[LOAD_BALANCER_DNSNAME] ...replaced by hostname
resources[ALB] resources[LOAD_BALANCER][consoleUrl]
resources[CODE_PIPELINE] resources[SERVICE_?_CODE_PIPELINE][consoleUrl]
resources[RDS_INSTANCE] resources[SERVICE_?_DB_HOST][consoleUrl]

As you can see, much of the tenant object stayed the same between v1 and v2, but v2 adds more properties and renamed a couple of things to make it easier to understand and use. SaaS Boost v1 did not have a true concept of packaging your SaaS application by Tier. You could emulate some of what tiering represents by "overriding the default" compute settings when you onboarded a tenant. In v2, all of these compute settings (and more) are modeled as part of the app config for each service you define.

Code Pipelines and RDS resources are created per service in v2, so the naming has changed to include the service name you enter in app config. For example, if you named your service frontend, the CodePipeline resource would be called SERVICE_FRONTEND_CODE_PIPELINE.

Using Tiers
v1 if overrideDefaults == false would be similar to onboarding a tenant in v2 to whichever tier you've marked as "default"
v1 if overrideDefaults == true would mean onboarding a tenant into a tier that configures service settings and limits represented by the compute and scaling choices from v1

Also note that in the future billingPlan will move to be an attribute of the tier the tenant onboarded into.

And, just to be clear, because I know this is something your team is struggling with
tenant.resources[LOAD_BALANCER_DNSNAME] == tenant.hostname

@JaladJhamb
Copy link
Author

hello @brtrvn, sorry I wasn't able to respond back due to some personal reason I wasn't active,
We were actually going through the code of SaaS and we wanted to know what is this file in s3 bucket which is actually in unreadable format actually coming from.
image

@brtrvn
Copy link
Contributor

brtrvn commented Jun 9, 2023

It's hard to say for certain from your screenshot, but CodePipeline uses S3 as a source action. The files in the CodePipeline artifact bucket are ZIP files containing the source material expected by the pipeline's build action(s). In the case of a tenant workload pipeline, the file inside the ZIP archive will be an ECS image definitions JSON file used by ECS to perform a rolling deployment of a new Task Definition for the Services.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information or guidance required
Projects
None yet
Development

No branches or pull requests

2 participants