Skip to content

Commit

Permalink
Merge pull request #473 from kubero-dev/fix/race-condition-in-app-form
Browse files Browse the repository at this point in the history
fix race condition in app form
  • Loading branch information
mms-gianni authored Nov 4, 2024
2 parents e8dfc2d + b1c6cef commit c117aab
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions client/src/components/apps/form.vue
Original file line number Diff line number Diff line change
Expand Up @@ -1646,15 +1646,12 @@ export default defineComponent({
},
},
mounted() {
this.loadPipeline();
this.loadPipelineAndApp();
this.loadStorageClasses();
this.loadPodsizeList();
this.loadBuildpacks();
this.loadClusterIssuers();
this.getDomains();
if (this.app != 'new') {
this.loadApp(); // this may lead into a race condition with the buildpacks loaded in loadPipeline
}
if (this.$route.query.template && this.$route.query.catalogId) {
const catalogId = this.$route.query.catalogId as string;
Expand Down Expand Up @@ -1762,7 +1759,7 @@ export default defineComponent({
changeName(name: string) {
this.ingress.hosts[0].host = name+"."+this.pipelineData.domain;
},
loadPipeline() {
loadPipelineAndApp() {
axios.get('/api/pipelines/'+this.pipeline).then(response => {
this.pipelineData = response.data;
Expand Down Expand Up @@ -1803,6 +1800,11 @@ export default defineComponent({
this.buildpack.run.readOnlyAppStorage = true;
}
if (this.app != 'new') {
this.loadApp();
}
});
},
loadStorageClasses() {
Expand Down

0 comments on commit c117aab

Please sign in to comment.