How Are Extensions Applied at Runtime?

What happens if two users deploy an extension on top of the same App UI, either from the same project (in other words, the same Git repository) or different projects? How are their changes applied at runtime?

The answer depends on where the changes are made and when. Let's consider three scenarios:
  • Suppose User A and User B are extending the same App UI, each working on separate branches within the same Git repository. User A publishes his changes first. Later, when User B publishes, VB Studio fetches User A's changes, merges them with User B's, and deploys them as a single unit. If for some reason VB Studio cannot perform the merge successfully, User B is presented with a merge conflict, which he must resolve in the process of manually merging the branches before publishing. In this scenario, the extension contains a combination of the changes from User A and User B.
  • Now let's suppose that User A and User B are working on my_App_UI in different projects and repositories, but at different times. That is, first User A publishes an extension to my_App_UI, but later User B creates a new project and Git repository to extend the same App UI. Because VB Studio knows that User A has already created an extension for my_App_UI, VB Studio seeds User B's new Git repo with the latest extension published by User A. User B can then make additional changes on top of User A's extension and publish, without disturbing the changes made by User A.
  • Finally, imagine that User A and User B are working simultaneously on the same App UI, but in different projects and repositories. User A publishes his extension and verifies them. User B then makes a change that effectively overwrites the changes made by User A. Because the date stamp on User B's changes are more recent than User A's, User B's changes take precedence.

To avoid possible conflict between extensions, VB Studio recommends that you always begin your extension work by going to the Oracle Cloud Application you want to extend, then clicking Edit Page in Visual Builder Studio. This gives VB Studio a chance to guide you towards joining a project/Git repository that is already dedicated to extending the App UI, rather than creating duplicate code.