Showing posts with label Enterprise Manager. Show all posts
Showing posts with label Enterprise Manager. Show all posts

Saturday, December 13, 2014

How To Set EAR Upload Size for Oracle Enterprise Manager

By default, there is a limit for EAR upload size (~40 MB) in Enterprise Manager. If your ADF application is fairly big, you may face this limitation and will not be able to deploy through Enterprise Manager. Deployment for large EAR would work through WebLogic console, WLST script or directly from JDEV, however sometimes you may need to deploy through Enterprise Manager. I will describe in this post, how you could increase the limit - we are going to extract Enterprise Manager application EAR and change maximum file upload size specified in web.xml.

In my case, the requirement was to be able to deploy ~47 MB EAR file:


When trying to deploy this EAR through Enterprise Manager, I would get the error about maximum file upload size exceeded:


You must navigate to the folder, where applications are deployed for your domain (alternatively, double check in WLS for EM application, where EAR file is stored). There must be one called em.ear, this is the deployment for Enterprise Manager application:


Extract this EAR (make sure to create backup), you will find em.war file inside - we need this file:


Extract em.war file now. Navigate to WEB-INF folder, you will find web.xml file there. Open web.xml file for editing:


Search for org.apache.myfaces.trinidad.UPLOAD_MAX_DISK_SPACE parameter in web.xml and change its value to be large enough to accept the size of EAR file you want to deploy. I have set it to 50 MB = 52428800 bytes:


Make sure to pack everything back, and keep original em.war and em.ear files structure:


After all the are changes applied, large EAR file is accepted in Enterprise Manager and we can proceed with the deployment:

Friday, October 1, 2010

Exporting/Importing MDS Metadata and Promoting MDS Labels for Oracle ADF 11g and Oracle WebCenter 11g Applications

In my previous post I was talking how to remove broken personalizations for specific user - Advanced MDS Management for Oracle ADF 11g and Oracle WebCenter 11g Applications. Today I will describe another technique, it enables basic MDS repository partial modifications without removing all user personalizations. This can be useful, when user breaks his page and wants to remove only problematic personalization, without affecting his previous work. Also I will talk about MDS labels, and will explain what MDS label promotion means for MDS repository. In short - MDS label promotion is MDS repository downgrade, because we are reverting repository to previous version.

Download sample application for this post - MDSManagement.zip. This application is deployed to standalone WebLogic server, with Oracle WebCenter libraries. I'm using the same MDS repository as in my previous post:


I will open sample application with two different users to define personalizations through WebCenter Composer. First I login with user - john:


Will add one of the available ADF Task Flows from WebCenter Composer Resource Catalog:


Graph component is added:


Now we login as another user - scott:


Will add another available ADF Task Flow from WebCenter Composer Resource Catalog:


Search area with editable table is added:


Personalizations for users scott and john are done, now we can play with MDS. Let's export MDS repository, same as we were doing in previous post:


We can browse exported folder structure, will see personalizations for both users available:



Additionally, at this step we will create MDS label, so later will be able to revert MDS repository:


Now I will open screen personalized by user scott and will hide three columns - will perform further personalization:


Will do similar thing with user john and will hide another four columns - personalization will be stored in MDS:


Because we did more personalization, let's export MDS repository once again. You can see its 6 documents are exported now, before we had only 4:


Now you can see personalizations for search/edit ADF Task Flow are added, information about hidden columns:


We can assume real life scenario, when user asks to remove part of his personalizations. In the current release of MDS, user can't perform this action from UI - partial MDS revert. However, system administrator can export MDS repository, fix it and import back. In this example, for user scott, I will set two from three columns back to visible again:


We need to archive modified MDS files and import them back to MDS repository - this will apply latest changed:


Updated MDS structure import is done successfully:


User scott personalizations are partially removed - only one column remains hidden:


I have described how to do partial MDS repository changes by exporting and importing MDS structure.

Now I will give quick overview about MDS labels promotion. We have created our own MDS label earlier in this blog - mdslabel_v1:


I will promote this label - will revert MDS repository back to snapshot associated with this label. This means I will loose every user personalizations done after creating label. Its not that useful in general case, but might be good solution when system needs to be reset to specific point in time:


When our MDS label was promoted, all such personalizations done after this label was created are lost. Both users set some of the columns to be hidden, now all columns will be visible again (because MDS label was taken earlier).

All columns are visible for user john:


And for user scott:

Wednesday, September 29, 2010

Advanced MDS Management for Oracle ADF 11g and Oracle WebCenter 11g Applications

MDS functionality in Oracle Fusion 11g is really cool, and it makes Oracle ADF very competitive comparing to other development frameworks. You can read about personalization and customization support - Applying Personalization and Customization in Oracle ADF 11g and Oracle WebCenter 11g. However, most of the customers are asking, how they can manage MDS metadata repository effectively. In the current release of Oracle Fusion 11g, we don't have MDS metadata repository browser, its not easy to track who and when did MDS personalizations or customizations. Because of lack of MDS browser/editor, people sometimes can see a risk to implement systems with MDS functionality, no one wants to have black box as part of IT infrastructure. I have provided this feedback to Oracle Product Managers, I'm sure in the future we will have MDS browser/editor tool. I will explain, what functionality we can use today, for MDS repository management.

As a sample application for this post, I will use one application from my OOW'10 session - MDSManagement.zip. This sample contains WebCenter 11g application and two separate applications with ADF Regions, these regions are consumed from WebCenter 11g Composer component.

I'm deploying sample application on standalone WebLogic server, with WebCenter framework libraries installed. Also I have created my own MDS repository in database - mds-customapp. I'm using this repository for current blog post article:


First I will test WebCenter personalization scenario and login into application as user john:


You can use WebCenter Composer to add one of available custom ADF Task Flows - Employees Graph:


Graph is rendered fine, personalization information is stored in MDS repository:


Let's do MDS test now - I will refactor Employees Graph ADF Task Flow path and redeploy the same application. This should break my application for user john personalizations. It will happen, because MDS will store old ADF Task Flow path and will fail to load it from refactored application - we will see it now. This is valid real life scenario, it might happen that we will need to do refactoring for custom ADF Task Flow:


We can refactor it into another folder and redeploy application:


Now when we try to open redeployed application for user john, it breaks and generates exception - funny one (its because this user have personalized refactored ADF Task Flow):


I'm sure you saw this exception while developing applications with WebCenter Composer - oracle.adf.share.exceptionViewScopeException. This exception may happen, if MDS repository metadata is out of synch with application structure, its what happened in my example.

Now we need to open Oracle Enterprise Manager and navigate to MDS repository screen for our sample application:


The main goal is not to break personalizations of other users, so we don't want to clear entire MDS repository, but we want only to remove corrupted personalizations of user john. Because we don't have MDS browser/editor, its a bit complicated, but still possible. I will describe MDS repository recovery for specific user through series of steps:

1. MDS export

We need to know MDS repository structure, in order to know it - we need to export MDS repository and browse it folder structure. Export MDS repository into archive file:


Export is done successfully - 3 documents were exported:


2. MDS Labels

It is a good practice to create MDS label. This will allow us to revert MDS repository in the future, if there will be a need. However, it reverts complete repository for every user, so its not really useful in practice, when multiple users have different personalizations - these personalizations will be lost. Anyway, its a good practice to create MDS repository back up, before changing it - let's do it.

You should open Runtime MDS Browser (its not really a browser, just set of MDS commands, we can't see real MDS repository structure):


Go to Operations tab and select createMetadataLabel command:


Provide meaningful name and create MDS label:


You can invoke listMetadataLabels command to see all labels available:


List of labels we could revert in the future:


3. MDS repository structure

We don't want to revert our MDS repository blindly to initial MDS label and loose all users personalizations. We want only to clean broken personalization for one user - john. So, we need to know what MDS documents we should delete. Because there is no MDS browser, we need to check this manually through exported MDS folder structure. There are two places available with user john personalizations. First one is page definition:


And then page itself:


Remember both paths, you will need them for the next step.

4. WLST Script for MDS Management

In previous step, we have identified two MDS documents to be deleted. Will run WLST command - deleteMetadata, to delete them. Need to provide three parameters - application name, server and document to be deleted names:


Make sure you delete both documents related to user john:


MDS repository was cleaned up, now application should work for user john as well. Of course all user john personalizations are lost, but at least we didn't lost every user personalizations:


In my next post, I will describe how you can use MDS labels to revert your MDS repository in case of global system failure.