Monday, September 9, 2013

How-to: Automated Web Catalog Deployment in OBIEE 11g

3:33 PM

Share it Please
In a previous article I covered the process of how to automatically migrate the repository from a developer environment to production. Equally important is the process of migrating the web catalog.  Most BI Architects are familiar with the ability to archive and unarchive, but there are many unknowns that the Oracle documentation does not cover.

  • What about version control?
  • How do you migrate only select files?
  • How do you migrate object level security?
  • What if there are multiple people editing the web catalog?

A typical web catalog migration path consists of:

  1. Developer checks out or download a local copy of the web catalog from version control
    1. This is only done on an as needed basis
  2. Developer makes changes to specific web catalog files
  3. Developer archives changes
  4. Developer checks out a folder (in this case called archive.zip) from version control that contains all production changes for the specific release
  5. Developer adds their changes to the archive.zip
  6. Developer updates 'change list' within the archive.zip to contain path of changed document
  7. Developer checks-in archive.zip to version control
  8. Deployment script automatically propagates through out each environment as outlined below:

This process uses the 'archive.zip' file as the directory to propagate changes throughout all environments. This is a preferred method because the archive.zip file only contains changes to the web catalog, and not the entire web catalog itself.

What's in the archive.zip?

The archive.zip will contain 
  1. Only the modified web catalog objects for your specific release. 
  2. A csv file that contains the destination path of each web catalog object
    1. This is used as input for the shell script we're going to create for automatic deployment
    2. I call this file 'Catalog_Deployment.csv' but it can be renamed if needed
Your archive.zip file might contain the following:


In the above example I have 5 files:
  1. Financial_Reports.catalog is an archive of the 'Financial Reports' folder which contains multiple reports
  2. Financial_Reports_Dashboard.catalog is an archive of the Financial Reports Dashboard that displays all of the financial reports
  3. HR_Reports.catalog is an archive of the 'HR Reports' folder which contains multiple reports
  4. HR_Reports_Dashboard.catalog is an archive of the HR Reports Dashboard that displays all of the HR reports
  5. Catalog_Deployment.csv is a csv file that contains the target directory path when we unarchive each catalog file (via a shell script)

In the above example, the Catalog_Deployment.csv file would contain the following:


The Catalog_Deployment.csv contains only 2 columns:

  1. The name of the archive file(s) in your archive.zip (Column A)
  2. The unarchive target directory (Column B)

How do you identify the unarchive target directory (Column B)?

The unarchive target directory (column b) can be found in the 'location' section of the' properties' tab for the specific folder you're trying to archive:


Let's cover the steps required in order for the web catalog to make it out of the developer's box and into assembly test

Step 1.  Check out the archive.zip file from your version control software

'Check out' is the correct terminology because this will ensure the file is locked and no one can make any changes except for the specific developer. You should now have a locked version of archive.zip that you can modify.

Step 2. Archive the modified web catalog files

This is a straight forward step that can be achieved through Answers. The archive button can be found in the 'tasks' section as noted below:

Step 3. Modify the archive.zip file & Re upload to Version Control

Your modifications should include:
  1. The addition of the modified .catalog files
  2. Revisions to the Catalog_Deployment.csv 
Once the changes are made, you can upload back to Version Control and 'check the archive.zip' back in so other developers can add their changes. The key here is only one developer modifies the archive.zip file at a time!

Step 4. Pragmatically deploy the web catalog via a deployment shell script

The script we're going to use is going read each row in the Deployment_Catalog.csv file and and use Catalog Manager's runcat.sh script to perform command line based unarchiving.  Oracle has very little documentation on runcat.sh, but think of it as a way to launch Catalog Manager. You can launch Catalog Manager in either GUI mode or command line mode. Using the '.runcat.sh -cmd unarchive' parameters, we're telling Catalog Manager to unarchive in command line mode.

#!/bin/bash
#
# This file will read the archive files that are unzipped in /tmp/webcatmigration
#

/bin/dos2unix /tmp/webcatmigration/archive/Catalog_Deployment.csv /tmp/webcatmigration/archive/Catalog_Deployment.csv1
rm /tmp/webcatmigration/archive/Catalog_Deployment.csv
mv /tmp/webcatmigration/archive/Catalog_Deployment.csv1 /tmp/webcatmigration/archive/Catalog_Deployment.csv
while IFS=, read file path
do
echo ""
echo First Column in Catalog_Deployment - $file
echo Second Column in Catalog_Deployment - $path
echo ""
/export/obiee/11g/instances/instance1/bifoundation/OracleBIPresentationServicesComponent/coreapplication_obips1/catalogmanager/runcat.sh -cmd unarchive -offline /export/obishare/catalog/webcatalog -inputFile /tmp/webcatmigration/archive/$file -folder "$path"
done < /tmp/webcatmigration/archive/Catalog_Deployment.csv
~

This script does the following:

  • Converts the .csv file from binary to unix via dos2unix
  • Reads each row in Catalog_Deployment.csv and passes A(N) and B(N) for each row to the $file and $path parameters
A good option for automatic deployment would be to have this script run every Friday after hours as part of the deployment process. You would have one script in each environment for deployment. Ideally the script would be able to read directly from the file server of your version control software.

In summary, we've accomplished the following:
  • Implemented a mechanism to manage web catalog modifications
  • Automated the web catalog deployment process
  • Minimized human error

Notes

How often should I back up the entire web catalog?

Notice that the only component of the web catalog being uploaded to version control are the actual changes to the web catalog objects. It is a good idea to take a back up of the entire web catalog prior to the 'go live' of deployment of each 'new release'

What about object level security?

The runcat.sh and archive/unarchive functionality will automatically migrate object level security of each object, but if the object level security is using new application roles that do not exist in the assembly/system/pre-production/production environments - the application roles must first be created in each environment's Enterprise Manager.

Don't forget about the GUIDs!

If you are migrating to a production environment that has different authentication providers than the non-production environment(s) - you must refresh the GUIDs first. You can read how to refresh the GUIDs in this Oracle note - How to refresh GUIDs for OBIEE 11g ? (Doc ID 1564006.1)


 
keywords: OBIEE 11g, deployment, archive, unarchive, migration, answers, runcat.sh web catalog, webcat

18 comments:

  1. OBIEE , OES , OID integration.I created a dashboard/analysis on obiee analytics. I assigned it some permissions such as read access to particular role. I have configured LDAP based security configuration.Now i want to store the permissions in the connected OID. Currently it stores the permissions/ access control list in .atr file in some hex data format.
    I want to configure OES for setting permissions for my dashboard / analysis which will ultimately store the permissions data into OID. Is it possible.
    For that i want to configure permissions access through OES which will ultimately store the access information into OID.
    There is also a tool known as OBI Catalog manager through which we can configure the permissions/ access control list for our dashborad/analysis, but the problem is it stores these access data in .atr file. I want to store these access data into my OID.

    Please correct me if my understanding is incorrect.

    ReplyDelete
    Replies
    1. An important building block of SEO is to develop your website which can be easily understandable for both Online Visitors (most important) and search engine robots. In the current digital age, seo is important for your online success means to generate leads.

      SEO Services in IndiaSEO Company in India SEO Company in India SEO Services in India

      SEO Company in India SEO Services in India

      Delete
  2. This comment has been removed by the author.

    ReplyDelete
  3. Hey John it was very informative tutorial on automated web catalog deployment. Check out this link to know more.
    http://www.fireboxtraining.com/oracle-business-intelligence-training

    ReplyDelete
  4. Replies
    1. I have read your blog its very attractive and impressive. I like it your blog.

      Java Training in Chennai Core Java Training in Chennai Core Java Training in Chennai

      Java Online Training Java Online Training Core Java 8 Training in Chennai Core java 8 online training JavaEE Training in Chennai Java EE Training in Chennai

      Delete
  5. Thanks for appreciating. Really means and inspires a lot to hear from you guys.I have bookmarked it and I am looking forward to reading new articles. Keep up the good work..Believe me, This is very helpful for me.

    Digital marketing company in Chennai

    ReplyDelete
  6. It’s really amazing that we can record what our visitors do on our site. Thanks for sharing this awesome guide. I’m happy that I came across with your site this article is on point,thanks again and have a great day. Keep update more information..

    Corporate Training in Chennai

    ReplyDelete
  7. Superb. I really enjoyed very much with this article here. Really it is an amazing article I had ever read. I hope it will help a lot for all. Thank you so much for this amazing posts and please keep update like this excellent article.thank you for sharing such a great blog with us. expecting for your.
    Digital Marketing Company in India
    seo Company in India

    ReplyDelete
  8. This blog explains the details about changing the ways of doing that business. That is understand well and doing some different process. Provides he best output of others. Thanks for this blog.
    Digital Marketing Company in Chennai
    SEO Company in Chennai

    ReplyDelete
  9. I’m not sure where you’re getting your information, but good topic. I need to spend some time learning more or understanding more. Thanks for fantastic info I was looking for this information for my mission.

    SEO Company in India

    ReplyDelete
  10. CALFRE is the local search engine where you can find various training institutes that provide training for Oracle Fusion HCM through online in Hyderabad.
    Oracle Fusion Financial Training Institute

    ReplyDelete
  11. You are doing a great job. You inspire me to write for other. Thank you very much. I would like to appreciate your work for good accuracy and got informative knowledge from here.
    Oracle Fusion HCM Technical Online Training

    ReplyDelete
  12. Wonderful blog.. Thanks for sharing informative blog.. its very useful to me..

    iOS App Development Company

    ReplyDelete
  13. Nice article with useful information. The concept of web catalog migration path was really superb., Software Testing Training in Chennai | Selenium Training in Chennai | ALM Training in Chennai

    ReplyDelete
  14. Interesting blog which attracted me more.Spend a worthful time.keep updating more.
    Digital marketing company in Chennai

    ReplyDelete