Post on 03-Jan-2016
transcript
Introducing WebLogic Server 8.1
Delaware Valley BEA User Group
Aaron MulderChief Technical OfficerChariot Solutions
March 18 Copyright © 2003 Chariot Solutions DVBUG
Tonight, we’ll take a look at…
• New features in WebLogic Server 8.1– Support for J2SE 1.4 (yes) & J2EE 1.4 (no)
– UI improvements
– New tools & J2EE features
• Performance improvements “under the hood”
• Timeline for the 8.1 release
• Bonus Slide
March 18 Copyright © 2003 Chariot Solutions DVBUG
About Aaron Mulder
• Chief Technical Officer of Chariot Solutions
• Published author (Professional EJB, BEA WebLogic 7.0 Server Deployment and Administration Handbook)
• Presented at JavaOne 2001-2003, the Philadelphia Java Users Group, local seminars, etc.
• Member of the JSR-88 Expert Group (J2EE Application Deployment)
• Contributed to open-source projects such as JBoss, OpenEJB, and PostgreSQL
March 18 Copyright © 2003 Chariot Solutions DVBUG
About Chariot Solutions
• Information Technology provider focused on automating business processes
• Team of leading Java architects on staff
• Technical expertise in software architecture, development, and systems integration
• Proven track record with companies such as ExxonMobil, Midas, Rosenbluth International, UGI Utilities, and the State of New Jersey
March 18 Copyright © 2003 Chariot Solutions DVBUG
The Bottom Line
• WebLogic Server 8.1 is an improved version of 7.0 (same code base, better product)
• Goal: Improve developer productivity– Workshop, JBuilder WebLogic Edition, new tools, fewer restarts,
faster startup time, etc.
• Goal: Standards-based Integration– JMS, J2CA, Web Services
• But vendor lock-in is profitable too (did I say that out loud?)– Lots of proprietary extensions, some even useful
• Goal: Reduce cost of ownership/management– Improved admin tools– Improved monitoring
• Goal: Performance enhancements
WLS 8.1 J2SE and J2EE Support
March 18 Copyright © 2003 Chariot Solutions DVBUG
J2EE Support
• Supports J2EE 1.3
• Minimal J2EE 1.4 support– Some JSR-77/JSR-88 features
– Web Services implementation is still proprietary
– No EJB 2.1/JSP 2.0 features yet
• J2EE 1.4 support may debut in “Diablo” (2004)
March 18 Copyright © 2003 Chariot Solutions DVBUG
J2SE Support
• WebLogic Server 8.1 runs on J2SE 1.4– Ships with Sun & JRockit implementations
• Includes new features such as:– new logging API
– NIO (though WebLogic does not use this currently)
– JDBC 3 (includes JDBC 2 Optional Package/Data Sources)
– Enhanced printing support
– Built-in extensions include JAAS, JCE, XML, etc.
– Better thread dumps & debugging support
– Improved garbage collector
• JRockit adds more monitoring features
WLS 8.1 UI Improvements
March 18 Copyright © 2003 Chariot Solutions DVBUG
(Domain) Configuration Wizard
• Domains are the same as before– One admin server, zero or more managed servers
– Multiple servers can be in one or more clusters, or may just be individual
• Configuration wizard doesn’t divide domains based on number of servers any more
• Still need to select a domain type for the services to include (Workshop, Examples, Platform, etc.)
• Wizard lets you configure services such as JDBC, JMS, etc.
• Can use the wizard to update existing domains
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Configuration Wizard Screen Shots
March 18 Copyright © 2003 Chariot Solutions DVBUG
Administration Console
• All screens split out and hide the “advanced” options
• Right-mouse works right in navigation applet
• Still some options buried in right-mouse menus
• Help is included on the main console screens
• New wizard for SSL/Keystore configuration
• Wizards for JDBC pools, data sources, etc.
• Can test a JDBC pool from the console
• Data sources use a drop-down to select JDBC pools!!!
• No more Data Sources vs. TX Data Sources… mostly
• Network channels rolled into server configuration
March 18 Copyright © 2003 Chariot Solutions DVBUG
WebLogic Workshop
• Now possible to use Workshop for:– Web Services (as before)– Web applications– EJBs– Connectors– Workflow/BPM (for Integration product)– etc.
• Targeted at J2EE developers with less experience and an incomplete understanding of important J2EE concepts
• The “VB-killer” (of course, is it really easier to learn Java, HTML, XML, JSP, JSP expression language, SQL, JSP tags, and all the relevant J2EE properties than it is to learn Basic?)
• It’s not clear who wants their least-skilled developers working on distributed enterprise applications
WLS 8.1 New Tools & J2EE Features
March 18 Copyright © 2003 Chariot Solutions DVBUG
Server Changes
• Error messages and suggested actions are indexed on the WebLogic documentation web site, and available via:
java weblogic.GetMessage -detail -id BEA-010202
• JCE is supported for application-level SSL, etc.
• Admin tool supports batch mode, JDBC & cluster tests, always returns 0/1 on success/failure
• appc precompiler/validator replaces ejbc & jspc
• Smaller client JARs for EJB/RMI clients & JMS clients
• Can install Node Manager during basic server install
• Server archives a preset number of config.xml files
March 18 Copyright © 2003 Chariot Solutions DVBUG
JDBC Enhancements
• JDBC Connection pools can be tested in config wizard, console, admin tool, etc.
• Can set a timeout for clients to wait for a connection from a full pool (previously only limited by TX timeout)
• Can set a retry interval for creating connections (if the DB is down, etc.)
• Can test connections as they are created
• Better support for vendor extensions, including the method getVendorConnection()
• Support for JDBC RowSets
March 18 Copyright © 2003 Chariot Solutions DVBUG
Development Tool Enhancements
• New recommended development directory structure, lays out all source code like the EAR, builds to a separate directory
• 3 new tools compile, package, and deploy projects structured like this
src/META-INF/application.xml (& weblogic-application.xml)src/APP-INF/lib/3rdparty.jarsrc/ejbjar/META-INF/ejb-jar.xml (& weblogic DDs)src/ejbjar/com/somewhere/SomeBean.javasrc/ejbjar/com/somewhere/SomeHome.java (etc)src/webwar/WEB-INF/web.xml (& weblogic.xml)src/webwar/WEB-INF/lib/3rdparty.jarsrc/webwar/WEB-INF/classes/com/somewhere/Servlet.javasrc/webwar/index.jsp…
March 18 Copyright © 2003 Chariot Solutions DVBUG
Applications: Class Loading
• Can add common application libraries to an APP-INF/lib directory in the EAR
• Can specify how individual EJBs are loaded, to make redeployment faster– If EJB Home/Remote interfaces are loaded in the normal CL,
and the impl is loaded in a child CL, the impl can be redeployed without redeploying the entire EJB JAR
– Not recommended for production use
• Can manually arrange an entire hierarchy of class loaders involving individual EJB JARs and WARs in the weblogic-application.xml deployment descriptor
March 18 Copyright © 2003 Chariot Solutions DVBUG
Applications: Class Loading Example
<classloader-structure> <module-ref> <module-uri>parent-ejb.jar</module-uri> </module-ref> <module-ref> <module-uri>parent-web.war</module-uri> </module-ref> <classloader-structure> <module-ref> <module-uri>child-ejb.jar</module-uri> </module-ref> <module-ref> <module-uri>child-web.war</module-uri> </module-ref> </classloader-structure></classloader-structure>
March 18 Copyright © 2003 Chariot Solutions DVBUG
Applications: Lifecycle Classes& Listeners• Startup & shutdown classes are similar to server startup &
shutdown classes, but for individual applications• Listeners extend
weblogic.application.ApplicationLifecycleListener • Packaged in a JAR in the EAR, or in APP-INF/classes• Activated with weblogic-application.xml like this:
<weblogic-application> <listener> <listener-class>com.test.AppListener</listener-class> <listener-uri>listeners.jar</listener-uri> </listener> <startup><startup-class …><startup-uri …></startup> <shutdown><shutdown-class …><shutdown-uri …></shutdown></weblogic-application>
March 18 Copyright © 2003 Chariot Solutions DVBUG
EJB Enhancements
• J2EE 1.3 compliant defaults– parameters by value for remote interfaces
• MDBs can be assigned to execute queues using the dispatch-policy element in weblogic-ejb-jar.xml (previously only sessions & entities could do this)
• There are some new warnings (EJB loaded from server classpath, etc.) and the disable-warning element in weblogic-ejb-jar.xml
March 18 Copyright © 2003 Chariot Solutions DVBUG
CMP Entity Bean Enhancements
• “Better performance”
• More monitoring information on EJB instance pool/cache
• WLS supports bulk updates & deletes as well as bulk inserts, with appropriate drivers (addBatch(), etc.)
• Auto-detects DB type for EJB QL optimization, DDL, etc.
• Auto-create tables will replace tables when CMP/CMR fields change
• J2EE 1.3 compliant defaults– EJB existence checked on every method call (not end of TX)
– Pending changes written before finders/selectors execute
• CMP support for DB2
March 18 Copyright © 2003 Chariot Solutions DVBUG
JMS Enhancements
• 3rd-party JMS objects can be included in JNDI via the console
• JMS objects declared in an EJB deployment descriptor:– register in transactions automatically (the JMS provider must
support XA transactions if the EJB method uses one)
– Support application or container authentication to JMS
– Periodically test JMS connections for errors
– Restrict methods which shouldn’t be called in J2EE apps
– Use pooled JMS sessions
March 18 Copyright © 2003 Chariot Solutions DVBUG
JTA Enhancements
• A single non-XA resource can be enlisted in a transaction. The XA resources support 2-phase commit (prepare then commit) while the non-XA resource doesn’t. The logic looks like this:1. Prepare all XA resources. If any fail, roll back the TX.
2. Commit the non-XA resource. If it fails, roll back the TX.
3. If everything got this far, commit the XA resources and the TX.
March 18 Copyright © 2003 Chariot Solutions DVBUG
Web Services Enhancements
• Uses SOAP 1.2
• Implements a pre-release version of WS-Security for message integrity and confidentiality– Current spec drafts already differ from WebLogic
implementation
• Includes proprietary features for reliable delivery, only usable between WebLogic clients/servers
• Includes proprietary features for Web Services over JMS (not HTTP[s]), only usable between WebLogic clients/servers
• Not clear why we’d want to take advantage of any of this
WLS 8.1: Under the Hood
March 18 Copyright © 2003 Chariot Solutions DVBUG
Network & Clustering Enhancements
• Reduces sockets required for typical operations– New client to server load-balancing algorithms can favor a
server for which the client already has open sockets
– Servers can preferentially back up to other servers which they already have open sockets to
• Console is only available on admin server– can use dedicated admin port as before
• Node Manager installation and enhancements make managed server operation easier
March 18 Copyright © 2003 Chariot Solutions DVBUG
Queues (part 1)
• Queues have a queue of pending tasks, and a group of threads to consume them and do the work
• Most queues are only created when they’re necessary• One admin queue
– JMX– weblogic.Admin– console (HTTP)– Admin server to managed server traffic
• One non-blocking queue (used to be several)– In-memory replication– Transactions– Stateful session bean replication
March 18 Copyright © 2003 Chariot Solutions DVBUG
Queues (part 2)
• Multicast queue– JNDI announcements System queue
– Internal tasks such as HTTP session invalidation
– Development mode poller for application updates
– Transaction timeouts
• JMS dispatcher queue– Sends JMS messages
• JMSStore IO queue– Reads/writes persistent messages, etc.
• JMS Timer queue– Delivery timeouts, etc.
March 18 Copyright © 2003 Chariot Solutions DVBUG
Queues (part 3)
• Default queue– Handles user requests
• User-defined queues– In 8.1, can define on:
• EJB (including MDB)• EJB JAR• Servlet (including JSP)• WAR
– Used for performance management for apps
– Used to defeat deadlocks on multi-hop requests
• A request only switches threads/queues on remote calls (to another server, or servlet to EJB)
March 18 Copyright © 2003 Chariot Solutions DVBUG
Threads (part 1)
• Listen threads– plain text (t3, http, etc.)
– secure (t3s, https, etc.)
– admin port (used to be mixed with secure)
– network channels
• Health monitor thread– More information available when using JRockit
• Timed event generator (1 thread only)– Cluster heartbeat
– Scheduled jobs
– Only high priority thread in the whole server
March 18 Copyright © 2003 Chariot Solutions DVBUG
Threads (part 2)
• Socket Reader threads– % of threads in the default queue– Synchronous reading when using Java IO (haven’t got all the kinks
worked out for NIO)• Would like to have 1 thread per socket• OK for a client, not so good for a server
– Asynchronous when using a performance pack– Fewer threads are necessary due to improved affinity and
conservation of sockets
• Thread dumps– weblogic.Admin … THREAD_DUMP– kill -3– Ctrl-Break– JRockit management console– J2SE 1.4 has better deadlock detection then most J2SE 1.3 VMs
March 18 Copyright © 2003 Chariot Solutions DVBUG
JDBC
• No JDO support planned
• RowSet support introduced in 8.1– Supports disconnected operation (get data, manipulate, send
back and apply and lose any intervening changes)
– Supports disconnected optimistic operation (get data, manipulate, send back, server checks for intervening updates)
– Can serialize as objects or to XML
– WLS aggregates changes and uses bulk updates
– Supports arbitrary SQL, some support for updating a multi-table query
• RowSets will likely be expanded in future releases– caching, explicit PKs/FKs, Object/XML wrappers, QL, etc.
WebLogic 8.1 Platform Timeline
March 18 Copyright © 2003 Chariot Solutions DVBUG
Timeline
• WebLogic Server 8.1 final and JRockit 8.1 final due at the end of March
• WebLogic Platform 8.1 final due by the end of “Q2” (JavaOne?)
• Next release is “Diablo”– beta Q1 2004
– final Q2 2004
March 18 Copyright © 2003 Chariot Solutions DVBUG
Bonus Slide
If you haven’t heard:
• It is now free to develop on WebLogic– You can download a 1-year, 20-connection license
• For $599, you get quarterly CD releases, support, “education materials”, and WebLogic Developers Journal
• For $4659 you get all that plus a copy of JBuilder 8 WebLogic Edition with JBuilder Enterprise support
Questions?
March 18 Copyright © 2003 Chariot Solutions DVBUG
• Download slides at:
http://www.chariotsolutions.com/presentations.html
• Presentation feedback at:
http://www.chariotsolutions.com/feedback.html