Hi All,
In UUF, We have three different artifact types. UUF Applications(A), Components(C) and Themes(T). Given that an Application can have UUF dependencies (i.e. Components & Themes) and non-UUF dependencies(i.e. Back-end osgi bundles, jax-rs or p2-features(BE)). Same way, a Component also can have UUF dependencies and non-UUF dependencies. [image: Inline image 3] Diagram 1: sample apps dependency hierarchy When deploying, the *deployable* artifact is an UUF-Application (you cannot deploy a theme or a component alone). Moreover, the source project and built project of the UUF-Application is bit *different*. Hence, we have created uuf-maven-plugin [1] to build the application. [image: Inline image 4] Diagram 2: source project and built app comparison When building the application we are resolving & copying the UUF dependencies into the deployable artifact (i.e. a zip file). As per the above diagram; when resolving non-UUF dependencies, we need a way to carry forward the back-end dependency (BE) information of components( C) and apps(A). For example: A1’s pom.xml will declare T1, C1, C2, C3, and BE1A1 as its dependencies. It will not aware of the dependencies BE1C1, BE1C2 and BE1C3. However, when running the “create-application” goal in uuf-maven-plugin, we need to resolve these BE dependencies as well. This will be more complex; If there’s an App A2 from different product team he will only add T2 and C1 as dependencies. BE1C1 should be resolved when creating the app A2. Problems: 1. How to copy deployed uuf-application and its BE dependencies into a product (delivering app)? 2. How to transfer meta-information of the BE dependencies along with components and apps? Proposed Solution: One solution is to create a new “create-feature” goal to create a *carbon-feature*. [image: Inline image 7] Diagram 3: sample apps dependency hierarchy: BE can be a Bundle(B) or Feature(F) (maven goals on the left) Suppose the application feature is Foo; 1. Plugins (i.e. B1A1, B1C3) need be copied to the /plugins directory in the feature Foo. Those will be copied into the PRODUCT_HOME/components path by carbon-feature-plugin when installing the feature. 2. UUF application (i.e. A1, A2) will be in /features in the feature Foo. It will be copied into PRODUCT_HOME/deployments/uufapps directory. We can declare the copy path of UUF application through p2 touchpoints. 3. Since transitive features(F1C1, F1C2) are not immediate dependencies of the App. It will be added as <importFeature> in the feature Foo. For the second problem; we can allow adding non-UUF dependencies in pom.xml. Since we are using uuf-maven-plugin we can ignore non-uuf dependencies when running goals of create- components, create-themes and create-application. Your comments and suggestions are highly appreciated. Thanks, Rasika [1] https://github.com/rasika/carbon-uuf-maven-plugin/ -- With Regards, *Rasika Perera* Software Engineer M: +94 71 680 9060 E: rasi...@wso2.com LinkedIn: http://lk.linkedin.com/in/rasika90 WSO2 Inc. www.wso2.com lean.enterprise.middleware
_______________________________________________ Architecture mailing list Architecture@wso2.org https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture