Partner Webcast – Weblogic for Developers - 12 July 2012


Published on

Oracle Weblogic Server is the industry’s leading application server for deploying Java EE applications with support for new features for lowering cost of operations, improving performance and enhancing scalability.

But it’s also a great choice for the Java developers because of the differentiating capabilities that facilitate integration with other tools and frameworks, promote reusability and rapid redeployment of your applications.

During the webinar we’re explore these differentiation features in more detail.
Find out more at

Published in: Spiritual, Technology, Education
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Partner Webcast – Weblogic for Developers - 12 July 2012

  1. 1. “This slide format serves to call attention to a quote from a prominent customer, executive, or thought leader• Name• in regards to a particular topic.” Title, Company Name CUSTOMER LOGO
  2. 2. <Insert Picture Here>Oracle Weblogic Server: the differentiationfeatures for the developersDmitry NefedkinOracle ISV Migration Center FMW
  3. 3. ISV Migration Center Team• Who we Are ISV Migration Center Team is a team of senior technical consultants based in Eastern and Central Europe and represents Oracles technical investment for partners.• Mission Statement Enable partners to rapidly and successfully adopt and implement Oracle latest technology• What do we Offer Whether you are selling Oracle technology, building business solutions, including hosted Internet solutions or providing system integration and implementation services for Oracle technology, IMC Team can help you succeed.• How can we assist We offer a wide range of free services for partners such as one2one assistance, webinars, seminars and hands-on workshops.Our blog: Terentes Printzios ( )ISV Migration Center Manager, ECEMEA
  4. 4. Agenda <Insert Picture Here>• Weblogic for Developers Overview• Java standards supported by Oracle Weblogic• Classloading in Weblogic• Weblogic integration with Apache Maven• Advanced deployment features• Spring Framework support in Weblogic• Useful links
  5. 5. Oracle Cloud Application FoundationFoundation for Oracle Fusion Middleware in the Cloud Web Social Mobile Exalogic Oracle Public Elastic Cloud Cloud User Engagement Traffic Director Business Process Content Business Management Management Intelligence WebLogic Coherence Tuxedo Server Service Integration Data Integration Cloud Application Foundation Identity Management & SecurityDevelopment Cloud Application Enterprise Tools Foundation Management
  6. 6. Modern Development with WebLogic Server 12c Development Tooling, Maven, Spring, Classloading, Open Source …• Java EE 6 Full Profile Certified• Standard Java IDE Support• Deeper Maven Integration• Built in Java VM Flight Recorder/Diagnostics• GlassFish DD Support on WebLogic• Latest Spring Framework 3.0.x Support• Built in Classloading Analysis Tool (CAT) CAT
  7. 7. Agenda <Insert Picture Here>• Weblogic for Developers Overview• Java standards supported by Oracle Weblogic• Classloading in Weblogic• Weblogic integration with Apache Maven• Advanced deployment features• Spring Framework support in Weblogic• Useful links
  8. 8. WebLogic Server 11g – standards supportedJava Java EE Standard 5.0 and Java SE 6.0 Support • Standards CompliantJava SE 6.0 • Certified JEE 5.0 CompatibleJava EE 5.0 • Latest version: JPA 2.0 & JSF 2.0 compliantJSP 2.1 √JSF 1.2, 2.0 √ • High PerformanceServlet 2.5 √ • Advanced SecurityEJB 3.0 √JAX-WS 2.1 √ • Enterprise MessagingJMS 1.1 √ • Web ServicesJNDI 1.2 √JCA 1.5 √ • Integrated Operations &JTA 1.1 √ AdministrationJMX 1.2 √ • Integrated, ProductiveJava EE Deployment 1.2 √ Development ToolsJava EE Management 1.1 √JDBC 4.0 √ • Open Source Certified 8
  9. 9. Weblogic Server 11g – limited Java EE6 Support (since 10.3.4)• Support for JSF 2.0• Support for JPA 2.0 • Uses the JPA 2.0 reference implementation via Oracle TopLink /EclipseLink • Supported by Oracle Enterprise Pack for Eclipse • Adds more mapping capabilities and options • Optimistic AND pessimistic locking • Criteria API for Java API-based queries• Support for JAX-RS 1.1 • Uses the Jersey 1.1 reference implementation • RESTful Web Services support - simple client/server Web Services using stateless protocol (HTTP) • Update web.xml to delegate requests to Jersey Servlet, add JAX-RS annotations and the REST is easy 9
  10. 10. Weblogic 12c – full Java EE 6 support Flexible & Lightweight Extensible• API Pruning • Embrace open source frameworks• Standards-based • Enable Drag & Drop dependency injection framework installation• Handle simple to complex with • Standards-based DI extensions no external dependencies don’t create proprietary lock-in Developer Productivity • POJO Programming Model • More annotations, better IDE support • Less XML configuration, more convention • Annotations, not deployment descriptors 10
  11. 11. Major New Updates in Java EE 6 Java Classes* Lines of Code* Lines of XML* 25% 50% 80% Less Less Less• Less XML, Less Code • Simplification, Productivity • Modernization • Java Server Faces 2.0 • Managed Beans 1.0 • Context & Dependency • Java Servlets 3.0 • Bean Validation 1.0 Injection 1.0 • Java Persistence 2.0 • JAX-WS 2.2 • Bean Validation 1.0 • Enterprise Java Beans • Java API for RESTful 3.1 & Interceptors 1.1 Web Services * Based on a Sample POJO/JPA/REST Based Application Built for JavaOne 11
  12. 12. Java SE 7: Cleaner, More Maintainable Code• Oracle WebLogic Server 12c supports Java SE 7 (and Java SE 6) • Java language optimizations • Client and server support • Internationalization • SSL/TLS 1.2 in JSSE • Converged Java VM 12
  13. 13. Try Java EE6 - pre-built Weblogic VM 13
  14. 14. Agenda <Insert Picture Here>• Weblogic for Developers Overview• Java standards supported by Oracle Weblogic• Classloading in Weblogic• Weblogic integration with Apache Maven• Advanced deployment features• Spring Framework support in Weblogic• Useful links 14
  15. 15. How Java loads classes Is Class Ask Parent Check my loaded? Classloader classpath
  16. 16. WebLogic ClassLoader Hierarchy Top-Down Class Loading (Default) SYSTEM ClassLoader loads: •WebLogic Implementation classes SYSTEM •Classes on the System Classpath •PRE_CLASSPATH and EXT_PRE_CLASSPATH DOMAIN ClassLoader loads: •Classes from <domain_dir>/lib DOMAIN APPLICATION ClassLoader loads: •Java EE Shared Libraries referenced in weblogic-application.xml •Any Modules defined in the application •Libraries from Java EE 5 <library-directory> directive or /lib ifAPPLICATION none configured •Libraries from <EAR>/APP-INF/lib WEB APP ClassLoader loads: •Java EE Shared Libraries referenced in weblogic.xml WEB APP •WEB-INF/classes •WEB-INF/lib •Enables Servlets and JSPs to see EJB classes •Enables redeployment of Web Apps w/o redeploying EJBs
  17. 17. WebLogic Filtering ClassLoader Force classes to be loaded from the APPLICATION • The FilteringClassLoader mechanism allows you to specify classes that should always be loaded from the application (not the SYSTEM SYSTEM ClassLoader) • This allows you to use alternate versions of applications, such DOMAIN as Xerces and Ant, than those that are packed with WebLogic FILTERING • Enables resources from the child of the FilteringClassLoader (an Application classloader) down to the calling classloader are returnedClassLoader before the ones from the system classloaderAPPLICATION • The FilteringClassLoader is configured with a list of packages specified in weblogic-application.xml or weblogic.xml (introduced in 10.3.3) files. WEB APP
  18. 18. Filtering ClassLoader Configuration Specify Packages to load from APP-INF/lib & WEB-INF/lib• Specify the packages that should be loaded by the Application including: • Java EE Shared Libraries • EAR: /lib (preferred) • EAR: APP-INF/lib • WAR: WEB-INF/lib• Overrides the classes that are loaded with WebLogic allowing you to use libraries that may conflict with those included in WebLogic
  19. 19. Web Filtering ClassLoader Configuration Load Classes from WEB-INF• There are two options for configuring the classloader in at the Web Application level • <container-descriptor> / <prefer-application-packages> • <container-descriptor> / <prefer-web-inf-classes>• Only one of these options can be used at a time• Oracle recommends using <prefer-application-packages> to configure the FilteringClassLoader<prefer-application-packages> <prefer-web-inf-classes>(Recommended)Allows a Web Application to use its Allows a Web application to use itsown third-party libraries from WEB- own version third-party classesINF/lib by specifying certain from WEB-INF/classes, whichpackages that should always be might also be part of WebLogicloaded from the Web Application Server
  20. 20. Custom ClassLoader StructureAdvanced Configuration for Reloading Classes• Defined in weblogic-application.xml• Custom classloader hierarchies allow better control over class visibility and reload-ability• The ability to create custom module ClassLoaders provides a mechanism to declare alternate classloader organizations that allow the following: • Reloading individual EJB modules independently • Reloading groups of modules to be reloaded together • Reversing the parent child relationship between specific Web modules and EJB modules • Namespace separation between EJB modules
  21. 21. WebLogic ClassLoader Analysis ToolNEW in WebLogic 11gR1 (10.3.4)• Available at http://<wls_host>:<wls_port>/wls-cat• Application provided libraries can collide with 3rd party CAT libraries used by WebLogic Server • Hard to diagnose class and library conflicts• Filtering Classloader feature enables applications to use their own libraries • Correctly configuring it can be a challenge• Classloader Analysis Tool Helps Identify and Resolve Conflicts Quickly • CAT cracks open the classloader black box • Displays classloaders’ hierarchies and sources • Allows you to search for a class/resource on a classloader • Views class definitions, interfaces • Analyzes classpath conflicts, generates corresponding filtering classloader configuration
  22. 22. Analyze Classpath Conflicts WebLogic 10.3.4 ClassLoader Analysis Tool• The ClassLoader Analysis tool shows you where the class conflicts are• This allows you to see the conflicting libraries, where they are located and allows you to decide how to resolve it
  23. 23. ClassLoader Configuration Suggestion WebLogic 10.3.4 ClassLoader Analysis Tool• The ClassLoader Analysis tool provides the XML configuration necessary for configuring the Filtering ClassLoader• This significantly eases the configuration required to take advantage of this advanced feature• Only available in WebLogic 10.3.4 and later
  24. 24. Library Packaging vs Referencing/LinkingEnterprise Archives and Shared Libraries• Packaging: • Include JAR files in WEB-INF/lib • Include EJB-JAR and WAR files in EAR • Include JAR files in APP-INF/lib • Or in <library-directory> specified in application.xml• Referencing / Linking • Java EE Shared Libraries
  25. 25. Java EE Shared LibrariesPackaging• Shared Libraries can be packaged as EAR, WAR or JAR files• META-INF/MANIFEST.MF must contain: • Extension-Name • Specification-Version • Implementation-Version
  26. 26. Java EE Shared LibrariesShared Library Deployment
  27. 27. Java EE Shared LibrariesReferencing from the application Referencing Application uses Deployment Descriptors to link the shared libraries to the JAR/WAR Modules JAR Libraries application at deployment time application.xml weblogic- application.xml
  28. 28. Classloading in WeblogicAdditional links on the topic•Oracle Weblogic Documentation •Oracle® Fusion Middleware Developing Applications for Oracle WebLogic Server 12c Release 1 (12.1.1), chapters 10, 11•Oracle Weblogic YouTube Channel •WebLogic ClassLoaders and ClassLoader Analysis Tool •Java EE Shared Libraries with WebLogic
  29. 29. Agenda <Insert Picture Here>• Weblogic for Developers Overview• Java standards supported by Oracle Weblogic• Classloading in Weblogic• Weblogic integration with Apache Maven• Advanced deployment features• Spring Framework support in Weblogic• Useful links 29
  30. 30. What is Maven• An Apache open source project• Maven is: • An automated build system + • A project management system + • A library and dependency handling system + • A project description system + • A site generation system + • …• Mature Maven is a project management tool which encompasses a project object model, a set of standards, a project lifecycle, a dependency • Maven 1.0 2004 management system, and logic for executing plugin goals at defined phases in a lifecycle. • Maven 2.0 2005 When you use Maven, you describe your project using a well-defined project object model, Maven can then • Maven 3.0 end 2010 apply cross-cutting logic from a set of shared (or custom) plugins. Jason Van Zyl, Sonatype 30
  31. 31. Primary Maven ConceptsUnderstanding Apache Maven• Project Object Model (POM) • A project is the fundamental unit of work in the Maven universe • The POM describes the project, its name/version, type, dependencies, etc. • Portable!• Convention over Configuration • Sensible default behaviours for projects • Standard directory layout for project, no configuration necessary, no path settings required • Enables automation of build and packaging process • Use default directories to locate resources, sources, tests, generate classes, packages • Well defined project lifecycle 31
  32. 32. Maven Build Lifecycle, Phases and GoalsUnderstanding Apache Maven• Maven 2.0 is based around the central concept of a build lifecycle • The process for building and distributing a particular artifact (project) is clearly defined • Only necessary to learn a small set of commands to build any Maven project, the POM ensures the project is built correctly • default, clean, site• Build lifecycles are further defined by a set of build phases • A build phase represents a stage in the lifecycle • Executed sequentially to complete the default lifecycle• Build phase made up of goals • Phases are composed of goals that perform actual tasks • Default goal bindings for standard lifecycle phases • Plugins contribute additional goals to project 32
  33. 33. Maven Default Lifecycle test: test the compiled validate: ensure the source code using a compile: compile the project is correct and all suitable unit testing source code of the necessary information is framework; tests should project available not require the code be packaged or deployed integration-test: package: take the verify: run checks to process and deploy the compiled code and verify the package is package if necessary package it in its valid and meets quality into an environment distributable format, criteria where integration tests such as a JAR, WAR, can be run etc. install: install the deploy: for final release, package into the local copies the final package repository, for use as a to the remote repository dependency in other for sharing with other projects locally developers and projects. 33
  34. 34. Primary Maven Concepts - RepositoriesLocating Dependencies and Plugins• A Maven repository holds: • Build artifacts, Dependencies & Plugins• Two strict types of repositories • Local • Remote• Maven automatically looks in remote repositories for missing dependencies/plugins declared in a project• Default PUBLIC repository is Maven Central •• Additional PUBLIC repositories can be easily defined • Java repository: 34
  35. 35. Primary Maven Concepts - DependenciesDependency Specification & Management• Maven looks for dependencies using: • Group Id / Artifact Id / Version <dependencies>• Dependencies can be scoped for: <dependency> • Compile / Test / Packaging / Runtime <groupId> </groupId>• Maven automatically manages the <artifactId>weblogic- download of declared dependencies full</artifactId> in a project <version>12.1.1</version> <scope>compile</scope> • Obtained from public and/or </dependency> corporate repositories • Stored in local repository for next ... use• Declare dependencies, no need to </dependencies> ship libraries with project 35
  36. 36. Primary Maven Concepts - PluginsExtending Maven Behaviour with Plugins• Plugins perform the work in the Maven ecosystem <plugins>• Default set of plugins exists from Apache <plugin> • Bound to lifecycles and phases <groupId>org.apache.maven.plugins </groupId> • Examples: Compile, JAR, WAR, etc. <artifactId>maven-compiler- plugin</artifactId>• Declaratively configured <version>2.0.2</version> <configuration> • Similar model to Project dependencies/libraries <source>1.6</source> <target>1.6</target> • Automated download if hosted in public repository </configuration> • Can be manually installed </plugin> …• Can be executed as standalone goals </plugins> • mvn wls:deploy• Can be bound to execute for a given lifecycle/phase • mvn deploy 36
  37. 37. WebLogic Server Maven Support Overview • Introduced with WebLogic Server 11g R1 PS3 (10.3.4) supporting Application Deployment operations • Maven Mojo + WebLogic Deployer + WebLogic Client • Supported Deployment Lifecycle operations: list-apps, deploy/undeploy, start, stop and update • WebLogic 12c (12.1.1) provides additional functionality since the 11g release • Installation of Weblogic ZIP Distribution onto a machine where WebLogic has not been installed • WebLogic Domain Creation • Start/Stop WebLogic Servers • Execute WLST Scripts 37
  38. 38. Installing the WebLogic Maven PluginWebLogic-Maven Plugin• Use Maven install:install-file goal to install the wls-maven- plugin.jar library• Use $WL_HOME/server/lib/pom.xml to specify Group ID, Artifact ID and Version• The install:install-file will install the plugin into your local repository• Alternatively deploy:deploy-file can be used to deploy the plugin to a remote repository$ mvn install:install-file –Dfile=$WL_HOME/server/lib/wls-maven-plugin.jar –DpomFile=$WL_HOME/server/lib/pom.xml 38
  39. 39. Configure WebLogic Maven Plugin Maven pom.xml Configuration • WebLogic Maven Plugin needs to be configured as a plugin for a project to enable it to be used <project> <build> <plugins> <plugin> • Specify WebLogic Server Credentials – defaults can be used for the rest!<build> <plugins> Parameter Default Value <plugin> adminURL t3://<groupId></groupId> <artifactId>wls-maven- name ${}plugin</artifactId> <version></version> ${}/ <configuration> source ${}.${project.packaging} <user>weblogic</user> <password>welcome1</password> </configuration> domainHome ./Oracle/domains/mydomain </plugin> </plugins> middlewareHome ./Oracle/Software</build> 39
  40. 40. Deploying Applications with MavenWebLogic-Maven Plugin• Deploy applications after they are packaged. Defaults: • Application Name: ${} (ArtifactId-Version) • Source: ${}/${}.${project.packa ging} • Target: AdminServer• Common weblogic.Deployer properties used: • stage / nostage • remote • upload • userConfigFile / userKeyFile (for obfuscating the login password)$ mvn wls:deploy 40
  41. 41. Re-Deploying Applications with MavenWebLogic-Maven Plugin• Redeploy already deployed applications to same or new targets• Key Defaults: • Application Name: ${} (ArtifactId- Version) • Target: AdminServer$ mvn wls:redeploy 41
  42. 42. Un-Deploying Applications with MavenWebLogic-Maven Plugin• Un-Deploy applications• Key Defaults: • Application Name: ${} (ArtifactId- Version)• Common weblogic.Deployer parameters: • timeout • verbose • graceful$ mvn wls:undeploy 42
  43. 43. WebLogic Zip Distribution &WLS:INSTALL goal164MB WebLogic Distribution• The WebLogic Zip Distribution can be downloaded from OTN• The WebLogic Zip distribution is required to use the wls:install goal• Can be made available via: • A local/remote Maven Repo • A filesystem • An HTTP URL 43
  44. 44. Installing the WebLogic Zip Distributioninto your Local Repository• The WebLogic ZIP Distribution must be available in your local repository or a remote repository• Install the WebLogic ZIP Distribution into your local repository using the Maven install:install-file goal$ mvn install:install-file -DartifactId=wls-dev -Dpackaging=zip -Dversion= 44
  45. 45. Installing WebLogic using the ZIP DistributionWebLogic-Maven Plugin• Install WebLogic Zip Distribution using: • A Maven repository ( dev:zip: • An HTTP URL • A filesystem path• Key Defaults: • Middleware Home: ${}/Oracle/Software$ mvn wls:install –DartifactLocation=[Maven Artifact | HTTP URL | File Path] 45
  46. 46. Creating a WebLogic DomainWebLogic-Maven Plugin• Create a WebLogic Domain • Using the default template • OR Specify a custom template• Key Defaults • Domain Home: ${}/Oracle/Domains/myDomain • Domain Template: none – default Domain with Admin Server$ mvn wls:create-domain –DdomainTemplate=src/main/wls/myTemplate.jar –DdomainHome=target/domain 46
  47. 47. Start a WebLogic Server InstanceWebLogic-Maven Plugin• Starts the AdminServer for a WebLogic Domain • Can Start Managed Servers by overriding the ‘command’ parameter• Key Defaults: • Domain Home: ${}/Oracle/Domains/myDomain • Middleware Home: ${}/Oracle/Software $ mvn wls:start-server 47
  48. 48. Execute WLST using MavenWebLogic-Maven Plugin• Execute a WLST script • propertiesFile – optional Java properties file passed as command-line Java parameters • Online or Offline• Execute multiple scripts using multiple plugin declarations or commands $ mvn wls:wlst –DfileName=src/main/wlst/ –DpropertiesFile=src/main/resources/ 48
  49. 49. Stop a WebLogic Server InstanceWebLogic-Maven Plugin• Stops the AdminServer for a WebLogic Domain • Can Stop Managed Servers by overriding the ‘command’ parameter• Key Defaults: • Domain Home: ${}/Oracle/Domains/myDomain • Middleware Home: ${}/Oracle/Software $ mvn wls:stop-server 49
  50. 50. Associating WebLogic tasks w/Maven Phases• Maven plugin goals can be bound to a Maven phase to execute during that phase• Useful for automating deployment of target application to a server for testing as part of Maven lifecycle• Use the <executions> section of the <plugin> tag to specify the target phase and the goal(s) to executePre-Integration-Test: install, create-domain, start-server, deploy Integration-Test: <exec tests> Post-Integration-Test: undeploy, stop-server, clean 50
  51. 51. Apache Maven IntegrationAdditional links on the topic•Oracle Weblogic Documentation •Oracle® Fusion Middleware Developing Applications for Oracle WebLogic Server 12c Release 1 (12.1.1), chapter 3•Oracle Weblogic YouTube Channel •WebLogic 11g Maven Plugin •WebLogic 12c Maven Plugin Demo 51
  52. 52. Agenda <Insert Picture Here>• Weblogic for Developers Overview• Java standards supported by Oracle Weblogic• Classloading in Weblogic• Weblogic integration with Apache Maven• Advanced deployment features• Spring Framework support in Weblogic• Useful links 52
  53. 53. FastSwap• WebLogic’s FastSwap feature is: • Enabled using the WebLogic deployment descriptors • Available only if the domain is not running in production mode • Applicable only to Web applications that are not archived• When enabled: • WebLogic automatically reloads the modified Java class files within applications • Developers can perform iterative development without an explicit redeployment• FastSwap configuration: • weblogic.xml: <fast-swap>true</fast-swap> 53
  54. 54. Production Redeployment Side by Side Deployment• Multiple application versions can co-exist • New client requests are routed to active version; • Existing client requests can finish up with existing version• Automatic Retirement Policy: Graceful, Timeout• Test application version before opening up for business• Rollback to previous application version• Two versions of the application can be active at any given point of time 54
  55. 55. Production Redeployment• To support the production redeployment strategy, Oracle WebLogic Server now recognizes a unique version string entry (max 215 characters long) in the Enterprise MANIFEST file. Manifest-Version: 1.0 Weblogic-Application-Version: v1• When a redeployment operation is requested, Oracle WebLogic Server checks the version string to determine whether to deploy a new version of the application.• Weblogic Domain must be running in Production Mode 55
  56. 56. Advantages of Production Redeployment• Saves the trouble of: • Scheduling application down time • Setting up redundant servers to host new application versions • Managing client access to multiple application versions manually • Retiring older versions of an application manually 56
  57. 57. Advanced deploymentAdditional links on the topic•Oracle Weblogic Documentation •Oracle® Fusion Middleware Deploying Applications to Oracle WebLogic Server 12c Release 1 (12.1.1), chapters 3, 4, 8•Oracle Weblogic YouTube Channel •WebLogic Server Side-by-Side Deployment 57
  58. 58. Agenda <Insert Picture Here>• Weblogic for Developers Overview• Java standards supported by Oracle Weblogic• Classloading in Weblogic• Weblogic integration with Apache Maven• Advanced deployment features• Spring Framework support in Weblogic• Useful links 58
  59. 59. Spring Support in WebLogicEnabling Spring Support in WLS• Deploy weblogic-spring.jar as a Library file in your WebLogic domain• Add the following to your application’s file • Extension-List: WeblogicSpring • WeblogicSpring-Extension-Name: weblogic-spring • WeblogicSpring-Specification-Version: • WeblogicSpring-Implementation- Version:• For WLS 11g library versions are different 59
  60. 60. Spring Support in WebLogicSpring MBeans• For Spring application Weblogic automatically Generates a set of Spring Mbeans off the WebLogic ApplicationRuntimeMBeans • SpringApplicationContextRuntimeMBean • SpringBeanDefinitionRuntimeMBean • SpringRuntimeMBean • SpringTransactionManagerRuntimeMBean • SpringTransactionTemplateRuntimeMBean • SpringViewResolverRuntimeMBean • SpringViewRuntimeMBean• Read-Only Mbeans providing better visibility into what’s happening inside Spring applications running in the WLS container• Accessible via WLST or JMX Browser 60
  61. 61. Spring Support in WebLogicWebLogic Admin Console Spring Extension• Set of pages added to Admin Console• Need to enable the extension in the Admin Console • Requires a restart of the server 61
  62. 62. Spring Support in WebLogicWebLogic Admin Console Spring Extension• Provides a view of the WebLogic generated Mbeans 62
  63. 63. Spring Support in WebLogicWebLogic Admin Console Spring Extension• Provides runtime metrics • Types and amounts of Spring beans that have been created for the deployed applications Application Context • Scope and performance metrics of Spring Application beans • WebLogic managed transactions that have been initiated via the Spring library code in the deployed application 63
  64. 64. Spring Support in WebLogicWebLogic Injected Spring Beans• WebLogic adds a “parent” context to a Spring Application Context during the startup of a spring-enabled Web Application• Context is pre-populated with the following 3 WebLogic specific beans • A WebLogic Transaction Manager bean (ref="transactionManager") • A WebLogic Edit Server MBean Connection bean (ref="editMBeanServerConnection") • A WebLogic Runtime Server MBean Connection bean (ref="runtimeMBeanServerConnection")• Developers can refer to these WebLogic-specific beans (using the ref ids shown above) and have them injected into application code.• Example: a developer may want to inject a reference to the WebLogic ServerRuntime JMX Server into a piece of code, to enable the code to then use JMX to inspect the host servers runtime MBeans, using a Spring declaration similar to the following: <bean id="myTestBean" class="com.acme.MyTestBean"> <property name="mbeanSvrConn" ref="runtimeMBeanServerConnection"/> </bean> 64
  65. 65. Spring SupportAdditional links on the topic•Oracle Weblogic Documentation •Oracle® Fusion Middleware Spring Support in Oracle WebLogic Server 12c Release 1 (12.1.1)•Blogs •Paul Done on Weblogic and Spring integration •Middleware Magic: Enabling Spring Console Extension 67
  66. 66. Agenda <Insert Picture Here>• Weblogic for Developers Overview• Java EE standards supported by Oracle Weblogic• Classloading in Weblogic• Spring Framework support in Weblogic• Weblogic integration with Apache Maven• Advanced deployment features• Useful links 68
  67. 67. Useful linksWeblogic Virtual Developer Day• day/virtual-dev-day-wls-310924.html 69
  68. 68. Useful linksWeblogic DevCast Series••Java Message Service on WebLogic Server: Deep Dive•Web Services with JAX* and Spring on Oracle WebLogic•Distributed Grid Data Cache, JPA and Enterprise Java Scale•Developing a Data Access Layer with JPA•Unveiling Oracle WebLogic Server 12c – Developer Deep Dive•Java Message Service with Java and Spring Framework on OracleWebLogic 70
  69. 69. Useful linksWebLogic Examples on• 71
  70. 70. Questions & AnswersDmitry NefedkinOracle ISV Migration Center FMW ConsultantDmitry.Nefedkin@oracle.comWebinar slides and recording will be placed to IMC Team blog:
  71. 71. “This slide format serves to call attention to a quote from a prominent customer, executive, or thought leader• Name• in regards to a particular topic.” Title, Company Name CUSTOMER LOGO