Sunday, July 17, 2011

SCEA 5
SCEA 5 part 3 Essay
SCEA 5 part 3 EXAM
Oracle Certified Master PART3 EXAM
Java EE 5 Enterprise Architect PART 3 EXAM
OCMJEA PART 3
OCMJEA 5 PART 3


SCEA 5/
OCMJEA 5
-PART3 - Essay Exam

Earlier we could take part 3 before submitting the part-2 assignment to oracle but now after September 1st 2011 we need to upload part-2 assignment in pearsonvue.com/oracle and then it will allow you to book for part 3 exam.

The part 3 will be based on what you have done in part 2 and why you choose a particular frame work what was the reason etc.
I will list out some topics which if you can correlate to your assignment you will be able to answer most questions in Part3 essay exam.

I personally had prepared notes for each of the questions.
Most importantly make sure you relate this questions to the assignment and ask your self how you have handled in your design.
  1. Why have u chosen framework If any If not why not ?
  2. What technology u have used in presentation and business tier why ?
  3. Set of design patterns on which layer and why ?
  4. Security (network security and application security)
  5. what changes you suggest or how will you handle if the volume increases ?
  6. How you have handled security threats ?
  7. Why you choose EJBS if not why ?
In general prepare for the following.
( I guess I got these below questions from some other blog)
1) How does your design handle Scalability?
2) How does your design handle performance?
3) How does your design handle security?
4) How does your design handle Reliability?
5) How does your design handle Availability?
6) How does your design handle Extensibility?
7) How does your design handle Manageability?
8) How does your design handle Maintainability?

Each of the below question also ask , "Why did you choose?"

1) How does your design support session/state handling?
2) How does your design handle persistence?
3) How does your client tier talk to business tier?
4) How does your design handle Qos 5 Sec in peak time?
5) How does your design handle transactions?
6) How does your design handle authentication and authorization?


I gathered some notes in general for any application which helped a lot. Here are some tips for the above questions.
1) How does your design handle Scalability?
- Scalability by deploying apps on mutiple clusters if Required....??? EXPAND more on this. , The business components and presentation can be deployed on seperate servers if required which supports Scalability.
- Also stateless beans can be more easily load balanced across clusters.
- Use connection pooling for any data base connections to improve Scalability.
- Application is designed to be deployed on mutiple srevers which can be clustered it supports bothe vertical and horizontal scaling.
2) How does your design handle performance?
- One way to improve performance is to reduce the amount of data passed between components. So whereever possible between layers presentation<->business<->Data access layer send or receive only required information and use Data transfer Objects (DTO).
- Use Fast lanereader when browsing the catalog or products as the data is read only and using fast lane reader we can directly access the data using JDBC components.
The improved performance with fast lane reader is due to the fact that the component reads data in a form in which we wnat to use it. Using entity beans will be an over head in such cases.
- Using Service locator to improve performance.Any lookup for remote object (In case if we want to deploy business components on a different server) can be cached and we can eliminate redundant lookups which improves performance.
- If the EJBS are on Same server use Local Interfaces instead of remote interfaces.
- Using Busines Delegate pattern to reduce the number of round trips between presentation and Business logic layer.
- Use connection pooling for any data base connections to improve performance.
- Also the request across server will be evenly distributed by the load balancer to ensure good utilization of resources.

3) How does your design handle security?
- Using HTTPS for all external connections (Explain more)
- The servers itself will be within a DMZ (De militarized Zone)
- For JMs communicataion there are few options.
- Enabling JMS Provider authentication and access control
- JMS Queues and Topics protection, so that the desinations are available for access to privileged applications
- JMS Message-level (Using Encryption and Digital signatures) and Transport-layer security (Using SSL).
These options depends upon JMS provider and not specified by JMS standards.


4) How does your design handle Reliability? (????????????????? correct the numbers here.)
- We have two load balancer so even if one goes down other load balancer can pick and serve the requests.
- If one of the server goes down the loan balancer will ensure the new request will be routed to a server that is running.
- We have total Four clusters on which the application is running and two Hot stand by Databases.
- Session migration will be enabled so that if one server goes down the user will still be able to continue his shopping without any problems as the session will be migrated to the server thats up and running.


5) How does your design handle Availability?
- Application is designed for high avaibility. This is made possible by having two load balancers so that if one goes down the other load balancer will serve the requests/
- We have two clusters each with two nodes and each node can have multiple servers. To start with, each node has one server.
Since Cluster itself is on a seperate physcial machine at any given point of time we will have a server up and running all times even if the physcial machine has issues

6) How does your design handle Extensibility?
- The applicataion is designed with seperation of concerns- Presentation layer, Business layer, Data access layer.
Each layer is loosely coupled with each other with good usage of design patterns, interfaces and best practices of Object oriented design like encapsulation, inheritance.
So any change to sub systems will have less impact on systems which are using it as long the interfaces remain same. Even if there are changes the impact will be minimal for adpating new changes.


7) How does your design handle Manageability?
- Since application uses J2ee we can pluging in any JMX based tools for application and network management and monitoring. In addition we can also have good logging mechanism to indicate any Fatal or Error conditions.
Using JMX we can also trun on different logging levels at run time if required. (Eg: Say if there is some error that happens only in production we can trun on debug levels for a while using JMX modules)

8) How does your design handle Maintainability?
- Due to the layered architecrture each layer address a particular need so any enhancement can be made easily. Also each layer is loosely coupled with best deisgn practices which makes understanding functionality and making changes easier.
This can also be supported with good documentation of the application (Architecture diagrams, Interface agreements with extenal systems, Class diagrams, Sequence diagrams, Java doc etc)


1) How does your design support session/state handling?
- For maintaining the shopping cart application uses stateful session bean.

2) How does your design handle persistence?
- Using JPA and Entity Beans. The access is through Data Access Object (DAO).

3) How does your client tier talk to business tier?
- The presentation tier call's Business Facade <--> Business Delegate <---> DAO. The business facade is used to make sure there is less coupling between
presentation and business layer.The business delegate uses Service locator for invoking any EJB (RMI/IIOP) and DAO's.

4) How does your design handle Qos 5 Sec in peak time?


5) How does your design handle transactions?
- Using EJBs CMT through JPA.

6) How does your design handle authentication and authorization?
- When user completes his shopping we can give a provision to check out as guest or the user can create a profile in which case the the future logins will involve FORM based authentication mechanism.
- For internal users who maintian the applicataion in production, run reports for future projections or analysis etc we have LDAP based authentication mechanism.Here users can be put to different roles
so that not every internal user is authorized to run reports or view some critical data (eg: related to orders placed and payment relatred data)



NOTE/WARNING: After completing part-3 exam I got a message saying completed successfully and that I will get the results in 4-6 weeks with a print out at the exam center. But when I logged into pearson vue account the status for part-3 was showing as error. When I called Pearson initially they said its not an issue but later of my continuous questioning I was informed that the part 3 essay was not uploaded to oracle site due to net work error in Pearson application. Frankly I went though such a pain calling pearson, oracle. Pearson support doesnt have any mail access so the only way is to call them and each time they would tell some story. Finally after 21 days they resolved the problem. (yes it took them 21 days to upload my essay to oracle. I am hoping they have submitted what I have answered and not an empty file).
Hope no one will have this trouble.

Good luck and after September 1st all folks need to take a mandatory Part-4 which is a training from oracle. My personal opinion is it will be to expensive for any one to pay entire certification cost and it may discourage more people. As the Part-4 training I heard is very expensive.

Resources:




SCEA 5/
OCMJEA 5
part 2 assignment or

SCEA 5 part 2 documentation or
Oracle Certified Master or
Java EE 5 Enterprise Architect or
OCMJEA Part2 assign ment or Documentation
OCMJEA 5 Part2 Assigment
Big Smoke Cigar Shop SCEA5 part II Assignment
Big Smoke Cigar Shop OCMJEA 5 part II Assignment

SCEA 5 / OCMJEA 5 PART- 2 Assignment - Designing and Documenting the solution using UML.

Well the assignment I got was designing Big Smokes Cigar Factory.A friend of mine started with class diagrams first and then with component , deployment and Sequence diagram.

I started with Sequence diagram as I felt It would give the list of all possible classes along with there methods. So I drafted these sequence diagrams on paper and then started documenting then with Enterprise Architect tool. Its pretty good. Always import images as .png files as the size is less and clarity is good.
You ca use the java jar command

jar cvf scea-SRxxxxxx.jar index.html part3html

where xxxx is your oracle id and part3html is the sub folder which had all images and remaining html pages.

I Will give you a brief description of Do's and Dont's in each set of diagrams

1. Class Daigram :
  • Don't show any DTO/VO (Data Transfer Objects) as it will pollute your diagram and will divert the digram focus from the actual business problem your are trying to solve. Eg: When I wanted to show payment Information I used paymentInfoDTO which is obvious and also I had an entity bean which was representing PaymentInfo. In this case there is no need to show paymentInfoDTO class but PaymentInfo(@Entity) is a must.
  • I included Business Facades as part of class diagram but not Business Delegate. The reason was most of my methods in Business Facades and Delegates had same names and parameters. (Well you may think then there is no point to include Business Facades as that too may pollute class diagram). But I wanted to highlight the methods so added this.
  • At the top of class diagram I added one controller to indicate front end controller (I did not add any Managed Beans or Backing Beans from JSF Frame work to the Class Diagram)
  • Please make sure your entities all are included and should include all entities as specified in the assignment and feel free to add any entities which you feel are important.Make sure the cardinality is maintained as specified in the assignment. This is very important.
  • In fact I had a separate section to explain the relation ship between entities in the final documentation. (Eg: One Order can have multiple payments. One payment can be made by multiple Credit cards etc)
  • Do not show any DAO'S in class diagram instead put all DAO's and Business Delegates in to component Diagram.
2. Component Diagram:
  • I added UI components and listed the JSF pages in each UI component. Eg: I had Search component and listed the following JSF pages (CategorySearch.xhtml, CategoryResults.xhtml, CiagarProductDetails.xhtml). Similarly I had other UI components like Checkout component, Admin UI component.
  • List all DAOS and any message Driven beans, any webservice components here. (However also mention any integration classes that you need for external systems in class diagram). eg: For payment Web service I had web service helper class called PaymentWebsserviceHelper in class diagram and a Component in called Payment Authorization component in component diagram.
  • List all sub systems at the bottom like - Email server, Ldap server, Database and components representing external APIs (like Merchant Bank, Freight Movers, International Shippers)
  • I had divided entire component diagram in to 3 layers - UI layer, Business Logic Tier and Integration Tier.
3. Deployment Diagram :
  • Show two fire walls - Primary and Back up.
  • Two load balancers
  • Two seperate hard ware device and each device having two clusters (So we can have 4 clusters)
  • Each cluster will have the application deployed. (Show Web container and EJB container in Each cluster) and with in each container show how your war or ear or jar files are deployed. Eg: You can package the WAR file as BIGCigarPresentation.WAR, BigCigInventoryProcessorMDB.JAR - as EJB jar file). So show these deployed artifacts in each container as that helps a lot for the evaluator.
  • Have two hard ware profiles for Databases and have two clusters on each server for Database. So in total you will have 4 instances of DB - 2 primary and 2 as back up.
  • Also explain hardware you want to use for deploying each application (Go to Oracle Website and look for Applicataion and DB hardware servers) . Then explain how memory you need for each applicataion. Start with some assumption like we will process 500 users per day - each user may need around 5mb space on server at run time (Considering thats the amount of data you hold in session bean) and for processing each user server may need another 5mb for book keeping - So in total per user you may need 10 mb.So for 500 users its 10 mb * 500= 5000 Mb or approx 5GB RAM. Since you dont want each server to be overloaded 100% its better you have some buffer and say we can have 8 GB RAM. With this analogy calculate the amount of data you will store in DB each day and how much memory you need for DB storage in a year.
4. Sequence Diagram (The most time consuming )
  • Include any class thats in Class Diagram and component diagram and references to any DTO's that you feel are required to explain a flow.
  • So here you can show any JSF page, Business Delegates, Facades, Entity beans, MDBs' Session beans , Adapters etc
  • Make sure you number each line that you draw (The numbering can be done by the tool which automatically updates the number when we add or remove)
  • Then at the end before final documentation you can explain each diagram by referring these numbers.
TIPS for Part-2 documentation:
I had an index page which had the following details

NAME: RamXXXXXXXXXXX
Prometric Tetsing ID: SRxxxxxx
SCEA Assignment:To Design retail shop for Big Smokes Cigar Shop

1. Back Ground
2. Objective
3. Business Domain Model Interpretation
4. Architecture Overview
5. Design Patterns Used
6. Session Management
7. Security
8. Persistence and Transactions Mechanism
9. Assumptions
10. UML Diagrams
· Class Diagram
· Component Diagram
· Deployment Diagrams
· Sequence Diagrams
10. Top Three Risks and mitigation plan


Now I will give little info about each section (though I am not supposed explain in detail, I wish I could)

Back Ground: Explain what the project is about - Eg Big Smokes Cigar shop is to sell cigars and we need to automate bla bla.

Objective: To Design and represent an online system for Big Smokes using UML Diagrams. Integrate Big Smokes application with third party sub systems ...................etc
The system designed should allow the Customers to
  • Search Catalog
  • Add products to Cart
  • Select shipping method
  • To make payment online and Checkout.
The system designed must meet the following criteria
  • 90% of all transactions to be under 5 seconds and no transaction exceeding 10 seconds.
  • Should support 200 concurrent users
  • 99.99% availability during core working hours.
  • A Minimum of 128 bit encryption for security.
(Basically get information from the Exam objective)

Business Domain Model Interpretation (Explains the multiplicity):
  • 1 customer can have many payments
  • 1 customer can have many orders
  • 1 order has 1 payment
  • ...... and so on......
Architecture Overview:
The proposed solution is based on Java EE 5 technology stack. And explain why you chose j2ee (Becoz of security , Txn management ....etc features)
Then list what frame wrok you are using in each layer (I will mention 3 points here though i had 8-9 bullets in my assignment)
  • EJB 3.0 entity beans and JPA for persistence.
  • JDBC API for connecting to Database
  • Java Mail API for email notification.
  • Then You mention about which layer and what frame work you are using - (hints: JSF, HTTPS, JSSE, etc)

List all design patterns used - like Factory, DTO, DAO etc. I had around 8 design patterns in my assignment
JPA for persistence mechanism and used container managed transactions where ever applicable.
9. Assumptions:
I had around 22 assumptions listed. From the beginning of the project I maintained notes for any assumption that I was making which helped a lot.Also mention any assumption or expectation that you have from the external system
To mention a few
  • The “BigCigFramework” as shown in class diagram will take care of any logging, exception handling, resource injection, authentication, and customer profile maintenance tasks.
  • If a user doesn’t check out and closes the browser the cart will not be saved.
  • The average response time in 99% of cases for Merchant bank payment web service should be within 2 seconds and in 1% of cases cannot be beyond 5 seconds.


Here I added link for each of the UML diagram. I had each diagram in a separate html and some explanation for each diagram.
Here just list out what are the top three problems you can see in the application once its deployed in production and once that problem occurs how you are going to resolve.
An Example:
Risk: Say suppose when a message is dropped in to message queue say the sub system fails to process the message due to database being down in which case we will loose the message.
Mitigation: In case of any exception when a sub system is processing a message and if it cannot complete it should write to a temporary queue. We can monitor the queue depth and alert production support team.
I had identified  4 risks and gave the solution for each to solve. I will given an hint  to find risk in your assignment.Thin on these lines 
- What if sub systems are down ??
- And how do you handle each sub system being down ?? 
-What if  subsytem sends wrong data ?