In the last post Personalization using MDS in Oracle ADF we saw the power of MDS Framework in Oracle ADF using which Users can personalize pages, components etc according to their own need. MDS saves these changes in MDS Store based on every user and applies on the runtime to the base document.
In Personalization, user is at the driver seat , changing things according to the needs. But there are cases where the application is developed and after there is a requirement of two different flavours of the same application. For example, there is a ADF application and there are two clients. One client wants some fields to be visible and some specific color settings while other client wants other fields to be hidden and different color settings. We can also put in this way, that one client want some regions (task flows) to be displayed and other client says other regions to be displayed.
Now in these cases the , making changes to the existing application will be difficult. Most common solution will be we create two versions of application , each version having specific changes required by the client. Hmm that works good for two clients but what will happen if there are hundreds, thousands of clients. One has to create / maintain same number of versions of applications. More to it, what will happen if there will be a common functionality change which needs to go to all versions. Maintenance will become a nightmare.
So by using Seeded Customizations provided by MDS, changes for specific needs / clients can be done on base document. There will be a single Base Application and changes corresponding to all the clients/layers will be done and these changes will be applied on runtime depending upon which client is using it..
Use Case :
There is a requirement that there is a ADF application which has one ADF Form on the page. There are two clients "ABCCorp" and "XYZCorp" which will be going to use this application. ABCCorp does not want to show Salary attribute to its users and want Employee ID to be in color "AQUA":
XYZCorp wants to show salary component to users and wants Employee ID background to be in color "LIME"
Lets get started with this Use Case :
Created a simple ADF Applications in Jdev 11.1.1.7 . Created ADF BC using HR schema with Employee EO and VO and AppModule.
In the VC Project, created a simple jspx page and used EmployeeVO to create a af Form.
Now we have a basic application with a form. We need to start customizing the application for both ABCCorp and XYZCCorp.
First step will be to enable Seeded Customizations in the projects.
This is done by ViewController -> Properties -> ADF View -> Enable seeded customizations.
Now the next and most important step is to create Customization Layer which will return the Name of the client, whether it is ABCCorp or XYZCorp.
So let us create a Customization class ClientCC which extends oracle.mds.cust.CustomizationClass provided by framework.
Now when you extends from CustomizationClass, one has to override these three methods. I will explain these methods and how to implement them in my next post. For now consider that getName method returns the name of CC layer and getValue method returns the current layer value. Here we are reading the value of client Name from Initialization Parameter in web.xml . If that parameter is set to ABCCorp, getValue method returns ABCCorp and so on.
Now we need to add this Customization Layer Class ClientCC to our application. But to make this class available, the project containing it needs to be deployed as ADF Shared jar and placed at <Jdev Home>/jdeveloper/jdev/lib/patches.
So after placing this jar to above path we are good. Now lets add this class to adf-config.xml.
adf-config.xml -> MDS Configuration
Now project is added with ClientCC Layer Class. Our setting in project is done.
Next step is to modify CustomizationLayerValues.xml . This file is available at <JdevHome>/jdeveloper/jdev
This XML file basically defines the design time values which can be returned from getValue method of CC class.
Add below XML to CustomizationLayerValues.xml
<cust-layers xmlns="http://xmlns.oracle.com/mds/dt">
<cust-layer name="client" id-prefix="s">
<cust-layer-value value="ABCCorp" display-name="ABCCorp" id-prefix="ABCCorp_"/>
<cust-layer-value value="XYZCorp" display-name="XYZCorp" id-prefix="XYZCorp_"/>
</cust-layer>
</cust-layers>
In Personalization, user is at the driver seat , changing things according to the needs. But there are cases where the application is developed and after there is a requirement of two different flavours of the same application. For example, there is a ADF application and there are two clients. One client wants some fields to be visible and some specific color settings while other client wants other fields to be hidden and different color settings. We can also put in this way, that one client want some regions (task flows) to be displayed and other client says other regions to be displayed.
Now in these cases the , making changes to the existing application will be difficult. Most common solution will be we create two versions of application , each version having specific changes required by the client. Hmm that works good for two clients but what will happen if there are hundreds, thousands of clients. One has to create / maintain same number of versions of applications. More to it, what will happen if there will be a common functionality change which needs to go to all versions. Maintenance will become a nightmare.
So by using Seeded Customizations provided by MDS, changes for specific needs / clients can be done on base document. There will be a single Base Application and changes corresponding to all the clients/layers will be done and these changes will be applied on runtime depending upon which client is using it..
Use Case :
There is a requirement that there is a ADF application which has one ADF Form on the page. There are two clients "ABCCorp" and "XYZCorp" which will be going to use this application. ABCCorp does not want to show Salary attribute to its users and want Employee ID to be in color "AQUA":
XYZCorp wants to show salary component to users and wants Employee ID background to be in color "LIME"
Lets get started with this Use Case :
Created a simple ADF Applications in Jdev 11.1.1.7 . Created ADF BC using HR schema with Employee EO and VO and AppModule.
In the VC Project, created a simple jspx page and used EmployeeVO to create a af Form.
Now we have a basic application with a form. We need to start customizing the application for both ABCCorp and XYZCCorp.
First step will be to enable Seeded Customizations in the projects.
This is done by ViewController -> Properties -> ADF View -> Enable seeded customizations.
Now the next and most important step is to create Customization Layer which will return the Name of the client, whether it is ABCCorp or XYZCorp.
So let us create a Customization class ClientCC which extends oracle.mds.cust.CustomizationClass provided by framework.
Now when you extends from CustomizationClass, one has to override these three methods. I will explain these methods and how to implement them in my next post. For now consider that getName method returns the name of CC layer and getValue method returns the current layer value. Here we are reading the value of client Name from Initialization Parameter in web.xml . If that parameter is set to ABCCorp, getValue method returns ABCCorp and so on.
Now we need to add this Customization Layer Class ClientCC to our application. But to make this class available, the project containing it needs to be deployed as ADF Shared jar and placed at <Jdev Home>/jdeveloper/jdev/lib/patches.
So after placing this jar to above path we are good. Now lets add this class to adf-config.xml.
adf-config.xml -> MDS Configuration
Now project is added with ClientCC Layer Class. Our setting in project is done.
Next step is to modify CustomizationLayerValues.xml . This file is available at <JdevHome>/jdeveloper/jdev
This XML file basically defines the design time values which can be returned from getValue method of CC class.
Add below XML to CustomizationLayerValues.xml
<cust-layers xmlns="http://xmlns.oracle.com/mds/dt">
<cust-layer name="client" id-prefix="s">
<cust-layer-value value="ABCCorp" display-name="ABCCorp" id-prefix="ABCCorp_"/>
<cust-layer-value value="XYZCorp" display-name="XYZCorp" id-prefix="XYZCorp_"/>
</cust-layer>
</cust-layers>
As one can see, there are two values defined ABCCorp and XYZCorp. This means when Jdev is open for customizations, these two values will be shown and one can select the values and make necessary changes for that value. Same these two values will be returned by getValue method of ClientCC class. Thus changes done to any value will be applied to the Layer returned by ClientCC get value method.
Next step is to open Jdeveloper in Customization Role. For doing this, go to Tools -> Preferences -> Roles -> and select option "Always prompt for role selection on startup".
After OK Restart the Jdev.
On Restarting, you will be prompted for the role. Select Customization Developer.
Jdeveloper will be opened in Customization Developer role and there will be a window , Customization Context in which by default one Value from CustomizationLayerValues.xml will be selected.
Now whatever changes one does, applies to this value returned by the layer. When ABCCorp is selected in Customization Context window -> Tip layer, whatever changes are applied on base application are for ABCCorp client.
Lets open our JSPX page which has Form.
Remember, there will be many things, component which will be read only. One cannot modify things which are core functionality of base document. Only things related to behaviour that can be customize will be editable. Also one can add new component for this particular value
As per the requirement, on clicking on EmployeeId attribute of the form, we set the back ground color as aqua.
And made the Salary attribute of the form Render as false because ABCCorp does not want to show Salary Component.
We are done with change to ABCCorp. Save and close the jspx. Now select XYZCorp from Customization Context window and again open the JSPX.
For EmployeeID, XYZCorp needs background color as Lime, and Salary attribute should be visible.
Great we are all done. The only thing left is setting In Parameter. Lets first set it to ABCCorp. Restart jdeveloper in Default Role. Open Web.xml. Enter ClientName as "ABCCorp".
Now lets run the the JSPX page.
We can see that page comes up according to ABCCorp. Employee Id background is AQUA and Salary attribute is not visible.
Now lets change Parameter in Web.xml to XYZCorp.
Save and run the page again.
Page Comes up according to XYZCorp. EmployeeId background is Lime and Salary attribute is Visible.
Also if we see the project structure , there is a folder MDSSYS created in View Controller project which has two folders ABCCorp and XYZCorp and they consist of CommonCorpPage.jspx.xml which is our JSPX. So these folders contains all the customized artifacts values in form of XML and are applied on runtime to the base document.
Thats it. By using powerful features of MDS provided by ADF, Customizations of the applications can be done according to specific requirements.
Thanks !!
It would be great if you post the sample application.
ReplyDeleteHi Sfti,
ReplyDeleteUpdated the post with link to sample application. You can download the same.
Thanks
Rohan
Thanks Rohan. I get MDS-00035: cannot load the class: view.ClientCC. error when I re-open jdev with Customization Developer role. Also, both the options are disabled in the Customization Context window.
ReplyDeleteHi Sfti, As described in the post, you need to create a jar file of ViewController project and place it in /jdeveloper/jdev/lib/patches. And you in customization role, add values to Customizationlayervalues.xml as described in post.
ReplyDeleteThanks
Hi Rohan, thanks for your post, it is very useful and clear.
ReplyDeleteI have a question about the deploy of this customizations. I have understood that this customizations are packaged in a .MAR file within the EAR. Is it possible deploy new customizations in production environment dynamically without redeploy all the app? Have you ever tried this?
Thanks!
Thanks bro for sharing I was looking for the same
ReplyDeletesnapchat for pc free
Your welcome Ajay !!
ReplyDeleteThanks for the such a Nice and useful post. The way you are putting things are very simple and creating interest to us.
ReplyDeleteThanks dtmrp !! Glad you liked it .
ReplyDeleteA great information regarding Oracle ADF, it is interesting and people should understand easily who are looking to take certification course in Oracle ADF,Job Assistance and find out some more information in the site,Oracle ADF Online Training with free Demo class in USA | UK | INDIA | SINGAPORE | Australia | Canada.
ReplyDeletecan any tell me how to apply seeded customization's to the existing EAR file in weblogic server
ReplyDeleteNeeded to compose you a very little word to thank you yet again regarding the nice suggestions you’ve contributed here.
ReplyDeletejava training in chennai
java training in bangalore
java online training
java training in pune
java training in chennai
java training in bangalore
java training in tambaram
Thanks for the informative article. This is one of the best resources I have found in quite some time. Nicely written and great info. I really cannot thank you enough for sharing.
ReplyDeleterpa training in marathahalli
rpa training in btm
rpa training in kalyan nagar
rpa training in electronic city
rpa training in chennai
rpa training in pune
rpa online training
Nice post. By reading your blog, i get inspired and this provides some useful information. Thank you for posting this exclusive post for our vision.
ReplyDeleteData Science training in btm
Data Science training in rajaji nagar
Data Science training in chennai
Data Science training in kalyan nagar
Data Science training in electronic city
Data Science training in USA
selenium training in chennai
selenium training in bangalore
Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging.
ReplyDeletePython training in usa
Python training in marathahalli
Python training in pune
Really this blog convinced me to know the next updates of this technology.
ReplyDeleteSelenium training in chennai
Selenium training institute in Chennai
iOS Course Chennai
French Classes in Chennai
Big Data Training in Chennai
Automation testing training in chennai
Best QTP Training Institutes in Chennai
Great Article… I love to read your articles because your writing style is too good,
ReplyDeleteits is very very helpful for all of us and I never get bored while reading your article because,
they are becomes a more and more interesting from the starting lines until the end.
data science online training
python online training
uipath online training
data science with python online training
rpa online training
I wanted to thank you for this great read!! I definitely enjoying every little bit of it I have you bookmarked to check out new stuff you post.is article.
ReplyDeleteangularjs online training
apache spark online training
informatica mdm online training
devops online training
aws online training
And indeed, I’m just always astounded concerning the remarkable things served by you. Some four facts on this page are undeniably the most effective I’ve had.
ReplyDeleteData science Course Training in Chennai | No.1 Data Science Training in Chennai
RPA Course Training in Chennai | No.1 RPA Training in Chennai
Thanks for your sharing
ReplyDeleteHadoop Big Data Training
Python Training in Chennai
And indeed, I’m just always astounded concerning the remarkable things served by you. Some four facts on this page are undeniably the most effective I’ve had.
ReplyDeleteJava Training in Chennai |Best Java Training in Chennai
C C++ Training in Chennai |Best C C++ Training Institute in Chennai
Data science Course Training in Chennai |Best Data Science Training Institute in Chennai
RPA Course Training in Chennai |Best RPA Training Institute in Chennai
AWS Course Training in Chennai |Best AWS Training Institute in Chennai
Thanks for sharing very helpful information. I found another OCA Training in Greater Noida, site , they provide very helpful services.
ReplyDeleteReally very happy to say, your post is very interesting to read. I never stop myself to say something about it. You’re doing a great job. Keep it up…
ReplyDeleteStart your journey with SAP S4 HANA Simple Logistics Training in Bangalore and get hands-on Experience with 100% Placement assistance from experts Trainers @Softgen Infotech Located in BTM Layout Bangalore. Expert Trainers with 8+ Years of experience, Free Demo Classes Conducted.
I am happy for sharing on this blog its awesome blog I really impressed. thanks for sharing. Great efforts.
ReplyDeleteBecome an Expert In Python Training in Bangalore ! The most trusted and trending Programming Language. Learn from experienced Trainers and get the knowledge to crack a coding interview, @Softgen Infotech Located in BTM Layout.
very nice information....!
ReplyDeleteinplant training in chennai
inplant training in chennai
inplant training in chennai for it
brunei darussalam web hosting
costa rica web hosting
costa rica web hosting
hong kong web hosting
jordan web hosting
turkey web hosting
gibraltar web hosting
Awesome,Thank you so much for sharing such an awesome blog...
ReplyDeleteInformatica Training in Bangalore
I love reading a post that will make people think. guide Also, thank you for allowing me to comment!
ReplyDeleteThanks for the informative article. This is one of the best resources I have found in quite some time. Nicely written and great info. I really cannot thank you enough for sharing.
ReplyDeleteweb designing training in chennai
web designing training in omr
digital marketing training in chennai
digital marketing training in omr
rpa training in chennai
rpa training in omr
tally training in chennai
tally training in omr
I would definitely thank the admin of this blog for sharing this information with us. Waiting for more updates from this blog admin.
ReplyDeleteweb designing training in chennai
web designing training in tambaram
digital marketing training in chennai
digital marketing training in tambaram
rpa training in chennai
rpa training in tambaram
tally training in chennai
tally training in tambaram
Wonderful blog with great piece of information. Regards to your effort. Keep sharing more such blogs. Looking forward to learn more from you.
ReplyDeletedata science training in chennai
data science training in porur
android training in chennai
android training in porur
devops training in chennai
devops training in porur
artificial intelligence training in chennai
artificial intelligence training in porur
I am glad it is helpful. Hopefully I will be able to release a newer version this month with some updates and improvements.
ReplyDeleteoracle training in chennai
oracle training in velachery
oracle dba training in chennai
oracle dba training in velachery
ccna training in chennai
ccna training in velachery
seo training in chennai
seo training in velachery
Nice post. By reading your blog, i get inspired and this provides some useful information. Thank you for posting this exclusive post for our vision.
ReplyDeleteweb designing training in chennai
web designing training in annanagar
digital marketing training in chennai
digital marketing training in annanagar
rpa training in chennai
rpa training in annanagar
tally training in chennai
tally training in annanagar
Software IT Coaching Center in ChennaiOrganic Chemistry tutor
ReplyDeleteThank you for your post. This is excellent information. It is amazing and wonderful to visit your site
ReplyDeleteBest Oracle ADF Course in Bangalore
Thanks For sharing a nice post about all Course.It is very helpful and for us.
ReplyDeleteOracle ADF training in bangalore
last month he share is herbal medicine in some medical hospital and now he is well recognize as one of the best in West Africa, you don’t have to be sad any more or share your tears any more on this virus when the cure have already be find in 2013 if you want to get in touch with him in private contact him on his email dr.chalaherbalhome@mail.com Or you can visit his website on https://
ReplyDeletedrchalaherbalhome.godaddysites.com or https://mywa.link/dr.chalaherbalhome
Set 3:
ReplyDeleteBest Software Training Institute in Chennai | Infycle Technologies
Title:
Description:
Train yourself in specific modules of any software to brush up your skills & shine in your career growth with the best software training institute in Chennai, Infycle Technologies. Infycle is the only Software Training Center in Chennai equipped with 150+ customized courses to serve the needs of the candidate's job profile requirements inclusive with the top job placements in the MNC's. Rather than just teaching the theories, our entire aim is aligned to make you a master by giving you the live hands-on training. Therefore, individuals will be asked to work on the live tasks & real-time use cases, that brings out the definite coder in you! To grab all these, call 7502633633 for a free demo.
Best training in Chennai
Set 3:
ReplyDeleteGrab Big Data Course in Chennai for making your career as a shining sun with Infycle Technologies. Infycle Technologies is the best software training center in Chennai, providing complete hands-on practical training of professional specialists in the field. It also offers numerous courses in the IT industry such as Oracle, Java, Python, AWS, Hadoop, etc. Once after the training, interviews will be arranged for the candidates, so that, they can set their career without any struggle. Of all that, 200% placement assurance will be given here. To have the best career, call 7502633633 to Infycle Technologies and grab a free demo to know more.
best training institute in chennai
This post on Seeded Customizations using MDS in Oracle ADF is incredibly informative! It makes me think of adam sandler leather jacket—both represent a blend of functionality and style. Just as Sandler’s jacket adds a unique touch to his look while being practical, seeded customizations allow developers to enhance applications while maintaining a solid foundation. Both highlight the importance of making a statement while ensuring everything works seamlessly. Thanks for sharing such valuable insights!
ReplyDelete