71
1 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Oracle ADF Architecture TV - Design - ADF Architectural Patterns

Embed Size (px)

DESCRIPTION

Slides from Oracle's ADF Architecture TV series covering the Design phase of ADF projects, considering the different ADF architectural patterns. Like to know more? Check out: - Subscribe to the YouTube channel - http://bit.ly/adftvsub - Design Playlist - http://www.youtube.com/playlist?list=PLJz3HAsCPVaSemIjFk4lfokNynzp5Euet - Read the episode index on the ADF Architecture Square - http://bit.ly/adfarchsquare

Citation preview

Page 1: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

1 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Page 2: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

2 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Real World ADF Design & Architecture Principles ADF Architectural Patterns

ORACLE PRODUCT

LOGO

15th Feb 2013 v1.0

Page 3: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

3 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Learning Objectives

•  At the end of this module you should be able to:

–  Identify separate ADF architectural patterns • Understand the moving ADF parts within each pattern • How ADF applications can be composed and separated

– Consider the pros and cons of each approach – Acknowledge potential anti-patterns and best practices – Match patterns to your requirements and capabilities

Image: imagerymajestic/ FreeDigitalPhotos.net

Page 4: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

4 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

“Design engineering is more than a mere balancing act between finding the best options among a sea of possibilities, and then implementing those options through the careful orchestration of available resources. To fully manage the challenges of the design process, it is also necessary to develop an instinct for choosing design paths and system configurations that provide some measure of flexibility. This maintains wiggle room as projects advance toward completion, often creating ‘an angel in the architecture’ to serve as a countermeasure for situations in which ‘the devil is in the details.’”

Mark Valentine Courtesy of Defence Electronics (Previously RFDesign.com)

http://rfdesign.com/mag/radio_flexibility_designers_best/

Page 5: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

5 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

ADF Application Architecture Patterns

•  In scope

– Architectural patterns within an ADF application

•  Out of scope

– Architectural patterns across systems – Server, hardware & network topologies

Page 6: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

6 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

ADF Application Architecture Patterns

•  “However beautiful the strategy, you should occasionally look at the results” •  “The best-laid schemes of mice and men” (often go awry) •  “No plan survives first contact with the enemy” •  “One size doesn’t fit all”

•  Oracle is presenting “blueprints” •  Oracle is not dictating end designs •  You are

Page 7: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

7 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

ADF Application Architecture Patterns

•  Take time to discuss merits of each pattern vs. your requirements

•  Consider your

– Processes – Reuse requirements –  Team’s size –  Team’s expertise & capabilities – Organization’s infrastructure

Page 8: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

8 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Program Agenda

•  ADF Application Architecture Patterns •  Anti-Patterns •  A Peek at Oracle’s Fusion Applications

Page 9: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

9 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 9 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Multi-Access Channel Fine Grained

Pattern Genealogy

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Cylinder

Pillar

Page 10: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

10 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Small and Simple Application Architecture

Image Source: http://bit.ly/GzVLDf

Fine Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Multi-Access Channel

Pillar

Cylinder

Page 11: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

11 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Small and Simple Application Architecture

•  One application workspace = one deployment EAR

•  Model: ADF Business Components –  Typically one Application Module –  Transaction support provided by root AMs

•  ViewController – One Unbounded Task Flow – No Bounded Task Flows

Characteristics

Page 12: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

12 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 12 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Small and Simple Application Architecture

Application Workspace

Model

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

ViewController Unbounded Task Flow View

Controller

Extensions

Page Templates

Declarative Components

Skins

Pages

EA

R

Page 13: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

13 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Small and Simple Application Architecture

•  Model: ADF Business Components – Single or multiple root Application Modules

•  ViewController – Design focuses on a page at a time – No need to consider reuse outside of application

Design Considerations

Page 14: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

14 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Small and Simple Application Architecture

•  Very simple architecture – Self contained – Easy to build and deploy

•  Suits small teams and/or beginners and/or small apps – Suits teams moving technical platforms and learning

•  Not essential to have complete development infrastructure (e.g. CI)

Advantages

Page 15: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

15 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Small and Simple Application Architecture

•  Poor mapping of business processes to technical solution

•  Tight coupling, poor modularization & separation of concerns – Developers can break each others’ work – Developers can fight for control of primary code artifacts – Unit testing is difficult – Post re-architecting is difficult

•  As solution grows, building & deploying slows – Build is an all or nothing affair

Disadvantages

Page 16: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

16 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Colossal Architecture

Image source: http://bit.ly/GzDTsR

Find Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Multi-Access Channel

Pillar

Cylinder

Page 17: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

17 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Colossal Architecture

•  Synonyms: uber, monolithic

•  One application workspace = one deployment EAR

•  ViewController – One Unbounded Task Flow – One to many Bounded Task Flows

•  Extreme contrast to the Simple Application Architecture

Characteristics

Page 18: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

18 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 18 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Colossal Architecture Application Workspace

Model

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

ViewController Unbounded Task Flow View

Controller

Extensions

Task Flow Templates

Declarative Components

Skins

Pages Page Templates

Bounded Task Flow

Fragments

Bounded Task Flow

Fragments

Bounded Task Flow

Fragments

EA

R

Page 19: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

19 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Colossal Architecture

•  Granularity of Bounded Task Flows – What are their functional boundaries? – How many Bounded Task Flows? – Do we make them all fine grained (~service)? – Or coarse grained (~complete process)? – Or a mix of both?

•  What makes a suitable declarative component and what is a suitable single view activity Bounded Task Flow?

Design Considerations

Page 20: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

20 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Colossal Architecture

•  Relatively simple architecture still

•  Bounded Task Flows introduce –  Improved business process to design mapping –  Improved modularization but not perfect – Options such as transaction features (vs. root ADF BC AMs) – Programming by contract now possible

•  Improved ability to test modules

Advantages

Page 21: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

21 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Colossal Architecture

•  Developers can still accidentally tightly couple code •  Build is still an all or nothing affair •  Unit testing is still hard •  Regression testing is an all or nothing affair •  Bounded Task Flows aren’t externally reusable •  Bounded Task Flows transaction options can be complicated

Disadvantages

Page 22: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

22 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Sum-of-the-Parts Architecture

Fine Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Multi-Access Channel

Pillar

Cylinder

Page 23: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

23 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Sum-of-the-Parts Architecture

•  One master application workspace with an Unbounded Task Flow

•  Model – Split into separate application workspace – Published and consumed as ADF Library

•  One to many separate “BTF” application workspaces – Each contains one to many Bounded Task Flows – Published and consumed as ADF Libraries

Characteristics

Page 24: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

24 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 24 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

1

Master Workspace ViewController

The Sum-of-the-Parts Architecture Common Workspace

Model

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

Task Flow Templates

Unbounded Task Flow

Pages

BTF Workspace ViewController

Bounded Task Flow

Fragments

Bounded Task Flow

Fragments

Page Templates

Declarative Components

Skins

ViewController Extensions

BTF Workspace ViewController

Bounded Task Flow

Fragments

Bounded Task Flow

Fragments

ADF Libraries

AD

F Libraries

EA

R

Page 25: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

25 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Sum-of-the-Parts Architecture

•  What functionality logically goes in to a BTF application workspace? •  What is the granularity of each BTF? •  Task flow transaction options •  Is reuse a consideration?

•  Deployment considerations – One EAR vs. WLS shared libraries

Design Considerations

Page 26: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

26 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Sum-of-the-Parts Architecture

•  Full power of BTFs – Reuse is now a strong possibility – Excellent separation of concerns –  Loose coupling - each BTF can be self contained – BTFs can be tested standalone – Scope of regression testing can be limited to BTFs

•  Suitable for large projects and teams •  Ownership - developers become responsible for individual BTFs,

team lead for master application

Advantages

Page 27: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

27 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Sum-of-the-Parts Architecture

•  Complex architecture, not suitable for beginners – Dependency management is now an issue – Build management is now an issue – Designing BTFs for reuse can be difficult

•  Within model layer ability to apply ADF BC security out of the box is lost

Disadvantages

Page 28: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

28 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 28 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

1

Master Workspace ViewController

The Sum-of-the-Parts "Alternative" Common Workspace

Model

Entity Objects

View Objects

Task Flow Templates

Unbounded Task Flow

Pages

BTF Workspace

ViewController Bounded Task Flow

Fragments

Page Templates

Declarative Components

Skins

ViewController Extensions

BTF Workspace

ViewController Bounded Task Flow

Fragments

ADF Libraries

AD

F Libraries

EA

R

Model View Objects

AppModule

Framew

ork E

xtensions

Model View Objects

AppModule

Framew

ork E

xtensions

AppModule

Framew

ork E

xtensions

Page 29: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

29 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Two-for-One-Deal Architecture

Image source: http://bit.ly/GzDTsR

Fine Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Multi-Access Channel

Pillar

Cylinder

Page 30: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

30 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Two-for-One-Deal Architecture

•  Extension of Sum-of-the-Parts pattern •  Reuse means BTFs can be used across applications

Characteristics

Page 31: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

31 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 31 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Two-for-One-Deal Architecture

BTF Workspace ViewController

Bounded Task Flows

Master Workspace

Master Workspace

BTF Workspace ViewController

Bounded Task Flows

BTF Workspace ViewController

Bounded Task Flows

ADF Library

ADF Library

ADF Library

ADF Library

Page 32: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

32 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Two-for-One-Deal Architecture

•  What are the requirements of the BTF now vs. the future? •  What BTFs are already available? •  Should all BTFs be designed for reuse?

Design Considerations

Page 33: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

33 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Two-for-One-Deal Architecture

•  All the benefits of “Sum of the parts” +

•  Reuse initially feels “cool” •  It’s like reaching nirvana after learning and much hard work

Advantages

Page 34: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

34 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Two-for-One-Deal Architecture

•  Repeated: –  What functionality logically goes into a BTF application workspace? –  What is the granularity of each BTF?

•  Dependency management can become a nightmare – Different versions of BTFs between applications need to be

managed – Different versions of BTFs running on different version of ADF

need to be managed – Potential solutions: tools such as Maven & Ivy

Disadvantages

Page 35: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

35 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Cylinder Architecture

Image source: http://yhoo.it/GzStM7

Fine Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Multi-Access Channel

Pillar

Cylinder

Page 36: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

36 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Cylinder Architecture

•  Similar in nature to Sum-of-the-Parts patterns

•  Application is made up of many cylinders – Cylinder is self contained business/functional area – Each cylinder is an application workspace

•  Model layer isn’t separated into ADF Library – Each cylinder has it’s own Model layer – ADF BC framework extensions are an exception

Characteristics

Page 37: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

37 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 37 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

1

Master Workspace ViewController

The Cylinder Architecture

Common Workspace

Task Flow Templates

Unbounded Task Flow

Cylinder Workspace 1 Model

Page Templates

Declarative Components

Skins

ViewController Extensions

Cylinder Workspace 2 Model

ADF Libraries

AD

F Libraries

ViewController Bounded Task Flows

ViewController Bounded Task Flows

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

EA

R

Page 38: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

38 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Cylinder Architecture

•  How fat or thin should the cylinders be? •  What functions should each cylinder contain? •  Where’s the logical line drawn for a cylinder?

•  This is not just about BTF granularity; •  What is the granularity of the cylinder?

Design Considerations

Page 39: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

39 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Cylinder Architecture

•  Reduces dependencies on most actively changing Model layer •  Logically groups related BTFs together •  From team and project point of view:

– Related BTFs are worked on together –  Independent cylinders are worked on separately – Aligns well to project phases – Regression testing can focus on one cylinder at a time

Advantages

Page 40: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

40 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Cylinder Architecture

•  Duplicated functionality across cylinder “Model” projects – Creates a maintenance issue

•  Application parts must be versioned separately •  Doesn’t isolate you from database changes •  No separation of concerns within a cylinder •  One massive application which may overwhelm the JVM resources

Disadvantages

Page 41: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

41 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 41 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

If our cylinders end up as massive applications in their own right, the

single deployed EAR and its resource requirements are going to overwhelm even the largest JVM.

What’s the solution?

Image: imagerymajestic/ FreeDigitalPhotos.net

Page 42: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

42 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Pillar Architecture

Fine Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Multi-Access Channel

Pillar

Cylinder

Page 43: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

43 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Pillar Architecture

•  Extension of the cylinder pattern •  Each application is an application in its own right •  Each “pillar” results in its own EAR •  But to the user it feels like one application

Characteristics

Page 44: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

44 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 44 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Pillar Workspace 1 Model

Pillar Workspace 2 Model

ViewController Bounded Task Flows

ViewController Bounded Task Flows

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

Unbounded Task Flow Unbounded Task Flow

The Pillar Architecture

Common Workspace

Task Flow Templates

Page Templates

Declarative Components

Skins

ViewController Extensions

AD

F Libraries

EAR #1 EAR #2

Page 45: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

45 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Pillar Architecture

•  A number of separate WLS servers to deploy your application •  To provide a seamless user experience, you’ll need to consider:

–  SSO –  A common UI Shell or equivalent –  Find a mechanism for sharing state between disparate applications

Design Considerations

Page 46: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

46 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Pillar Architecture

•  A flexible change control procedure: –  Patching can focus on fixing affected cylinders only –  Changes to one pillar doesn’t require a redeployment of the whole application –  Result in less downtimes for the other pillars

•  Performance of one application isn’t affected by another

Advantages

Page 47: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

47 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Pillar Architecture

•  Implementing SSO •  Implementing state sharing mechanism

Disadvantages

Page 48: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

48 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

The Multi-Access Channel Architecture

Fine Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Image source: Salvatore Vuono / freedigitalphotos.net

Multi-Access Channel

Pillar

Cylinder

Page 49: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

49 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 49 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

ADF Mobile and other solutions can make reuse of our ADF BC projects remotely via SDO web service calls.

Let's consider the following picture....

Exercise

Image: imagerymajestic/ FreeDigitalPhotos.net

Page 50: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

50 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 50 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Master Workspace

ViewController

The Multi-Access Channel Architecture? Common

Workspace

Unbounded Task Flow

Cylinder Workspace

Model

ViewController

Bounded Task Flows

Entity Objects

View Objects

AppModule

Framew

ork E

xtensions

SOAP - HTTP

HTML - HTTP

Page 51: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

51 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 51 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Is this architecture suitable for multi-access?

Should we directly reuse all of our ADF BC components for

web services?

What are the advantages and disadvantages?

Exercise

Image: imagerymajestic/ FreeDigitalPhotos.net

Page 52: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

52 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Program Agenda

•  ADF Application Architecture Patterns •  Anti-Patterns •  A Peek at Oracle’s Fusion Applications

Page 53: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

53 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Anti-Patterns

•  Everything is a template •  Fine grained architecture

Page 54: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

54 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Fine Grained Architecture

Fine Grained

Small and Simple

Application

Colossal

Two for One Deal

Sum of the Parts

Multi-Access Channel

Pillar

Cylinder

Page 55: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

55 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Fine Grained Architecture

•  Granularity of BTFs is reduced to its smallest size –  The goal is reuse of totally everything

•  BTFs can be wrapped in BTFs to create composites of functionality •  Reuse must be a mindset, not just a nice to have •  Reuse must be considered at every phase of the project

Characteristics

Page 56: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

56 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 56 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Service BTF

Service BTF

Service BTF

Service BTF

Service BTF

Composite BTF

Page 57: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

57 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Fine Grained Architecture

•  Extreme reuse (like an extreme sport) •  Patterns start to appear in patterns

•  If you love “pain” this pattern is for you

Advantages

Page 58: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

58 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Fine Grained Architecture

•  Not for the feint hearted •  Performance issues – lots of re-querying of data •  Overcomplicates even simple applications •  House of cards – requires strong team discipline •  “Worst case” dependency management

Disadvantages

Page 59: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

59 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Program Agenda

•  ADF Application Architecture Patterns •  Anti-Patterns •  A Peek at Oracle’s Fusion Applications

Page 60: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

60 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

A Peek at Oracle’s Fusion Applications Some Statistics

Product   Tables   EO   VO   AM   Services   Task  Flows  CRM   996   1137   2520   341   377   2122  Financials   1310   1534   4867   563   119   2329  GRC   170   173   405   86   57   764  HCM   1269   1597   4038   558   130   2872  Incen:ve  Comp   169   171   230   46   8   167  

Procurement   211   285   953   113   14   428  PPM   480   523   1775   207   21   691  SCM   932   1028   3336   512   439   1422  Setup   73   86   261   45   50   162  

Total   5,610   6,534   18,385   2,501   1,215   10,957  

Source: OOW 2010

Page 61: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

61 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

A Peek at Oracle’s Fusion Applications

•  Made up of multiple Java EE applications (not 1) –  Financials, CRM etc. plus a Common application

•  One app would result in a massive JVM heap •  Growing problem as more applications are added •  No one customer will install and run all applications

Overview

Page 62: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

62 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

A Peek at Oracle’s Fusion Applications

•  Each application is designed to – Be sold separately – Run standalone if need be – Presents itself as a self contained page with overall FA

•  Applications are divided into functional areas –  Financials: payable, receivables – Division of functions per application is up to the respective teams

Overview

Page 63: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

63 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

A Peek at Oracle’s Fusion Applications

•  There is no single composite “Fusion Apps” Java EE application

•  Each application has –  Its own WLS domain/cluster (and by inference URL) – Served in a page with its own UI Shell

•  UI Shell is present in each EE application –  Feels like one application to users, really many – Runtime applications do not share state via Java EE – All state is shared via database and FMW infrastructure

Overview

Page 64: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

64 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 64 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

A Peek at Oracle’s Fusion Applications

Page 65: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

65 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

•  1 to1 relationship with Java EE application and JDev workspaces •  There are no non-runnable workspaces (common workspaces) •  All projects for application are contained in the 1 workspace

JDeveloper Workspaces A Peek at Oracle’s Fusion Applications

Page 66: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

66 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

•  Projects can have broad or fine granular functionality •  Projects can be divided by following dimensions:

–  Functional – e.g. Expenses could have Entry, Auditing and Approval projects

–  Technology – e.g. ADF BC vs. UI –  Internal or common/shared

•  Common projects are designed to: – Be reused by other applications through ADF Libraries – Have few/zero dependencies from other workspace projects

Workspaces and Projects A Peek at Oracle’s Fusion Applications

Page 67: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

67 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

A Peek at Oracle’s Fusion Applications

•  The granularity of task flows takes all sizes •  Many common fragments = 1 to 1 with task flow •  e.g. Customer header, customer popups •  Other more “complex” task flows have many fragments/activities

Task Flows

Page 68: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

68 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 68 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

What pattern does Fusion Applications

use?

Exercise

Image: imagerymajestic/ FreeDigitalPhotos.net

Page 69: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

69 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Conclusion

•  There is no perfect solution – live with your decisions •  Reuse is good but shouldn’t be taken to its extreme •  You must consider your team and organization’s capabilities &

infrastructure when picking a pattern •  Don’t create solutions that work against the overall framework •  Consider all your options, what are you hoping to achieve?

Page 70: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

70 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.

Further Reading

•  Section 38 Reusing Application Components of the Fusion Developer's Guide for Oracle Application Development Framework 11.1.2.3.0 –  http://bit.ly/adfdevguide11123sect38

Page 71: Oracle ADF Architecture TV - Design - ADF Architectural Patterns

71 Copyright © 2013, Oracle and/or its affiliates. All rights reserved.