KEMBAR78
Haj 4328-java ee 7 overview | PDF
InterConnect
2017
HAJ-4328:
Java EE 7 Overview
Kevin Sutter, STSM
Java EE Architect
1 3/21/17
Please note
IBM’s statements regarding its plans, directions, and intent
are subject to change or withdrawal without notice at IBM’s
sole discretion.
Information regarding potential future products is intended to
outline our general product direction and it should not be
relied on in making a purchasing decision.
The information mentioned regarding potential future
products is not a commitment, promise, or legal obligation to
deliver
any material, code or functionality. Information about
potential future products may not be incorporated into any
contract.
The development, release, and timing of any future features
or functionality described for our products remains at our
sole discretion.
Performance is based on measurements and projections
using standard IBM benchmarks in a
controlled environment. The actual throughput or
performance that any user will experience will vary
depending upon many factors, including considerations such
as the amount of multiprogramming in
the user’s job stream, the I/O configuration, the storage
configuration, and the workload processed. Therefore, no
assurance can be given that an individual user will achieve
results similar to those stated here.
Java: Broadest Industry Adoption
10,000,000
JAVA DEVELOPERS and growing…
DEPLOYING TO 18 COMPLIANT APPLICATION SERVERS
2
Java EE 7 Platform
3
The Year of Java EE 7
Note: Unsupported Platforms
Note: Unsupported platforms“WebLogic 12.2.1 with full support for Java EE 7 is
slated to be released in just months (the officially
sanctioned timeline states calendar year 2015
which means the end of this year at the very
latest)”
https://blogs.oracle.com/reza/entry/the_ghosts
_of_java_ee, 8 June 2015
IBM Marketing Announce
WAS V8.0 – First fully-supported Java EE 6 Server
WAS V8.5.5.6 – First fully-supported Java EE 7 Server
4
Java EE 7 Themes
§ Batch
§ Concurrency
§ Simplified JMS
§ More annotated POJOs
§ Less boilerplate code
§ Cohesive integrated
platform
DEVELOPER
PRODUCTIVITY
§ WebSockets
§ JSON
§ Servlet 3.1 NIO
§ REST
MEETING
ENTERPRISE
DEMANDS
Java EE 7
5
Top Ten Features in Java EE 7
1. WebSocket client/server endpoints
2. Batch Applications
3. JSON Processing
4. Concurrency Utilities
5. Simplified JMS API
6. @Transactional and @TransactionScoped
7. JAX-RS Client API
8. Default Resources
9. CDI Managed Beans
10. More annotated POJOs
6
Java API for WebSocket 1.0/1.1
• Server and Client WebSocket Endpoint
– Annotated: @ServerEndpoint, @ClientEndpoint
– Programmatic: Endpoint
• Lifecycle events support
• Standard Packaging and Deployment
@ServerEndpoint("/chat")
public class ChatServer {
@OnMessage
public void chat(String m) {
. . .
}
}
Available Liberty v8.5.5.6 and WAS v9!
7
Java API for WebSocket 1.0
@ServerEndpoint("/chat")
public class ChatBean {
static Set<Session> peers = Collections.synchronizedSet(...);
@OnOpen
public void onOpen(Session peer) {
peers.add(peer);
}
@OnClose
public void onClose(Session peer) {
peers.remove(peer);
}
. . .
Chat Server
8
Java API for WebSocket 1.0
. . .
@OnMessage
public void message(String message) {
for (Session peer : peers) {
peer.getRemote().sendObject(message);
}
}
}
Chat Server (contd.)
9
JSON Processing 1.0
• API to parse and generate JSON
• Streaming API
– Low-level, efficient way to parse/generate JSON
– Similar to StAX API in XML world
• Object Model API
– Simple, easy to use high-level API
– Similar to DOM API in XML world
Available Liberty v8.5.5.6 and WAS v9!
10
{
"firstName": "John", "lastName": "Smith", "age": 25,
"phoneNumber": [
{ "type": "home", "number": "212 555-1234" },
{ "type": "fax", "number": "646 555-4567" }
]
}
JsonParser p = Json.createParser(...);
JsonParser.Event event = p.next(); // START_OBJECT
event = p.next(); // KEY_NAME
event = p.next(); // VALUE_STRING
String name = p.getString(); // "John”
Java API for JSON Processing 1.0
Streaming API
11
Batch Applications for Java Platform 1.0
• Suited for non-interactive, bulk-oriented, and long-running tasks
• Batch execution: sequential, parallel, decision-based
• Processing Styles
– Item-oriented: Chunked (primary)
– Task-oriented: Batchlet
Available Liberty v8.5.5.6 and WAS v9!
12
Batch Applications 1.0
Concepts
Metadata for jobs
Manage
batch
process
Batch
process
Independent
sequential
phase of job
Chunk
13
<step id="sendStatements">
<chunk item-count="3">
<reader ref="accountReader"/>
<processor ref="accountProcessor"/>
<writer ref="emailWriter"/>
</step>
...implements ItemReader {
public Object readItem() {
// read account using JPA
}
...implements ItemProcessor {
Public Object processItems(Object account) {
// read Account, return Statement
}
...implements ItemWriter {
public void writeItems(List statements) {
// use JavaMail to send email
}
Batch Applications 1.0
Chunked Job Specification
14
Concurrency Utilities for Java EE 1.0
• Extension of Java SE Concurrency Utilities API
• Provide asynchronous capabilities to Java EE application components
• Provides 4 types of managed objects
– ManagedExecutorService
– ManagedScheduledExecutorService
– ManagedThreadFactory
– ContextService
• Context Propagation
Available Liberty v8.5.5.6 and WAS v9!
15
Concurrency Utilities for Java EE 1.0
public class TestServlet extends HttpPServlet {
@Resource(name="java:comp/DefaultManagedExecutorService")
ManagedExecutorService executor;
Future future = executor.submit(new MyTask());
class MyTask implements Runnable {
public void run() {
. . . // task logic
}
}
}
Submit Tasks to ManagedExecutorService using JNDI
16
Java Message Service 2.0
• New JMSContext interface
• AutoCloseable JMSContext, Connection, Session, …
• Use of runtime exceptions
• Method chaining on JMSProducer
• Simplified message sending
Get More from Less
Java EE 7
Available Liberty v8.5.5.6 and WAS v9!
17
@Resource(lookup = "myConnectionFactory")
ConnectionFactory connectionFactory;
@Resource(lookup = "myQueue")
Queue myQueue;
public void sendMessage (String payload) {
Connection connection = null;
try {
connection = connectionFactory.createConnection();
Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
MessageProducer messageProducer = session.createProducer(myQueue);
TextMessage textMessage = session.createTextMessage(payload);
messageProducer.send(textMessage);
} catch (JMSException ex) {
//. . .
} finally {
if (connection != null) {
try {
connection.close();
} catch (JMSException ex) {
//. . .
}
}
}
}
Application Server
Specific Resources
Boilerplate Code
Exception Handling
Java Message Service 2.0
Sending a Message using JMS 1.1
18
Java Message Service 2.0
@Inject
JMSContext context;
@Resource(lookup = "java:global/jms/demoQueue")
Queue demoQueue;
public void sendMessage(String payload) {
context.createProducer().send(demoQueue, payload);
}
Sending a Message
19
Java API for RESTful Web Services 2.0
• Client API
• Message Filters and Entity Interceptors
• Asynchronous Processing – Server and Client
• Common Configuration
Available Liberty v8.5.5.6 and WAS v9!
20
Java API for RESTful Web Services 2.0
// Get instance of Client
Client client = ClientBuilder.newClient();
// Get customer name for the shipped products
String name =
client.target("../orders/{orderId}/customer")
.resolveTemplate("orderId", "10")
.queryParam("shipped", "true")
.request()
.get(String.class);
Client API
21
Contexts and Dependency Injection 1.1/1.2
• Automatic enablement for beans with scope annotation and EJBs
– “beans.xml” is optional
• Bean discovery mode
– all: All types
– annotated: Types with bean defining annotation (default)
– none: Disable CDI
• @Vetoed for programmatic disablement of classes
• Global ordering/priority of interceptors and decorators
Available Liberty v8.5.5.6 and WAS v9!
22
Bean Validation 1.1
• Alignment with Dependency Injection
• Method-level validation
– Constraints on parameters and return values
– Check pre-/post-conditions
• Integration with JAX-RS
Java EE 7
Available Liberty v8.5.5.6 and WAS v9!
23
Built-in
Custom
@Future
public Date getAppointment() {
//. . .
}
public void placeOrder(
@NotNull String productName,
@NotNull @Max("10") Integer quantity,
@Customer String customer) {
//. . .
}
Bean Validation 1.1
Method Parameter and Result Validation
24
Java Persistence API 2.1
• Schema Generation
– javax.persistence.schema-generation.* properties
• Unsynchronized Persistence Contexts
• Bulk update/delete using Criteria
• User-defined functions using FUNCTION
• Stored Procedure Query
• Entity Graphs
Available Liberty v8.5.5.6 and WAS v9!
25
Servlet 3.1
• Non-blocking I/O
• Protocol Upgrade
– HttpUpgradeHandler – necessary for Web Sockets
• Security Enhancements
– <deny-uncovered-http-methods>: Deny request to HTTP methods
not explicitly covered by specified constaints
Available Liberty v8.5.5.6 and WAS v9!
26
Servlet 3.1
public class TestServlet extends HttpServlet
protected void doGet(HttpServletRequest request,
HttpServletResponse response)
throws IOException, ServletException {
ServletInputStream input = request.getInputStream();
byte[] b = new byte[1024];
int len = -1;
while ((len = input.read(b)) != -1) {
. . .
}
}
}
Non-blocking I/O Traditional
27
Servlet 3.1
AsyncContext context = request.startAsync();
ServletInputStream input = request.getInputStream();
input.setReadListener(
new MyReadListener(input, context));
Non-blocking I/O: doGet
28
Servlet 3.1
@Override
public void onDataAvailable() {
try {
StringBuilder sb = new StringBuilder();
int len = -1;
byte b[] = new byte[1024];
while (input.isReady() && (len = input.read(b)) != -1) {
String data = new String(b, 0, len);
System.out.println("--> " + data);
}
} catch (IOException ex) {
. . .
}
}
. . .
Non-blocking read
29
JavaServer Faces 2.2
• Faces Flow
• Resource Library Contracts
• HTML5 Friendly Markup Support
– Pass through attributes and elements
• Cross Site Request Forgery Protection
• Loading Facelets via ResourceHandler
• h:inputFile: New File Upload Component
Available Liberty v8.5.5.6 and WAS v9!
30
Java Transaction API 1.2
§ @Transactional: Define transaction boundaries on CDI managed
beans
• @TransactionScoped: CDI scope for bean instances scoped to the
active JTA transaction
Java EE 7
Available Liberty v8.5.5.6 and WAS v9!
31
EJB 3.2
Servlet 3.1
CDI
Extensions
BeanValidation1.1
Batch 1.0
Web
Fragments
Java EE 7 JSRs
JCA 1.7JMS 2.0JPA 2.1
Managed Beans 1.0
Concurrency 1.0
Common
Annotations 1.1
Interceptors
1.2, JTA 1.2
CDI 1.1
JSF 2.2,
JSP 2.3,
EL 3.0
JAX-RS 2.0,
JAX-WS 2.2
JSON 1.0
WebSocket
1.0
32
WebSphere Application Server
Java EE 7 Roadmap
Liberty features – including Java EE 7
zOS
ND
Core
Base
scalingController-1.0
scalingMember-1.0
dynamicRouting-1.0
collectiveController-1.0 clusterMember-1.0
healthManager-1.0healthAnalyzer-1.0
Java EE 6
subset
couchdb-1.0
mongodb-2.0
wsSecurity-1.1
javaee-7.0
batchManagement-1.0
rtcomm-1.0 rtcommGateway-1.0
sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0
wsAtomicTransaction-1.2cloudant-1.0
zosConnect-1.2
zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0
zosRequestLogging-1.0batchSMFLogging-1.0
New in
1Q17
New in
4Q16
New in
2Q16
New in
3Q16
webProfile-6.0
distributedMap-1.0
productInsights-1.0
openidConnectServer-1.0
openidConnectClient-1.0
osgiAppIntegration-1.0
spnego-1.0
collectiveMember-1.0
restConnector-2.0
sessionDatabase-1.0
ldapRegistry-3.0
webCache-1.0
javaMail-1.5
osgiConsole-1.0
json-1.0
timedOperations-1.0transportSecurity-1.0
oauth-2.0
serverStatus-1.0
wab-1.0
blueprint-1.0
webProfile-7.0
eventLogging-1.0
requestTiming-1.0
adminCenter-1.0concurrent-1.0
bells-1.0
samlWeb-2.0
httpWhiteboard-1.0
federatedRepository-1.0
constrainedDelegation-1.0
osgiBundle-1.0
passwordUtilities-1.0
bluemixUtility-1.0
apiDiscovery-1.0logstashCollector-1.0
scim-1.0
microProfile-1.0 openid-2.0
monitor-1.0
Liberty features – Java EE 6 Web Profile
zOS
ND
Core
Base
zosConnect-1.2
zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0
zosRequestLogging-1.0batchSMFLogging-1.0
scalingController-1.0
scalingMember-1.0
dynamicRouting-1.0
collectiveController-1.0 clusterMember-1.0
healthManager-1.0healthAnalyzer-1.0
Java EE 6
subset
couchdb-1.0
mongodb-2.0
wsSecurity-1.1
javaee-7.0
batchManagement-1.0
rtcomm-1.0 rtcommGateway-1.0
sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0
wsAtomicTransaction-1.2cloudant-1.0
webProfile-6.0
distributedMap-1.0
productInsights-1.0
openidConnectServer-1.0
openidConnectClient-1.0
osgiAppIntegration-1.0
spnego-1.0
collectiveMember-1.0
restConnector-2.0
sessionDatabase-1.0
ldapRegistry-3.0
webCache-1.0
javaMail-1.5
osgiConsole-1.0
json-1.0
timedOperations-1.0transportSecurity-1.0
oauth-2.0
serverStatus-1.0
wab-1.0
blueprint-1.0
webProfile-7.0
eventLogging-1.0
requestTiming-1.0
adminCenter-1.0concurrent-1.0
bells-1.0
samlWeb-2.0
httpWhiteboard-1.0
federatedRepository-1.0
constrainedDelegation-1.0
osgiBundle-1.0
passwordUtilities-1.0
bluemixUtility-1.0
apiDiscovery-1.0logstashCollector-1.0
scim-1.0
microProfile-1.0 openid-2.0
monitor-1.0
servlet-3.0
jsp-2.0
jsf-2.0
ejbLite-3.1 jdbc-4.0
jndi-1.0
appSecurity-2.0
managedBeans-1.0
ssl-1.0
beanValidation-1.0
cdi-1.0
jpa-2.0
New in
1Q17
New in
4Q16
New in
2Q16
New in
3Q16
Liberty features – Java EE 7 Web Profile
zOS
ND
Core
Base
zosConnect-1.2
zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0
zosRequestLogging-1.0batchSMFLogging-1.0
scalingController-1.0
scalingMember-1.0
dynamicRouting-1.0
collectiveController-1.0 clusterMember-1.0
healthManager-1.0healthAnalyzer-1.0
Java EE 6
subset
couchdb-1.0
mongodb-2.0
wsSecurity-1.1
javaee-7.0
batchManagement-1.0
rtcomm-1.0 rtcommGateway-1.0
sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0
wsAtomicTransaction-1.2cloudant-1.0
webProfile-6.0
distributedMap-1.0
productInsights-1.0
openidConnectServer-1.0
openidConnectClient-1.0
osgiAppIntegration-1.0
spnego-1.0
collectiveMember-1.0
restConnector-2.0
sessionDatabase-1.0
ldapRegistry-3.0
webCache-1.0
javaMail-1.5
osgiConsole-1.0
json-1.0
timedOperations-1.0transportSecurity-1.0
oauth-2.0
serverStatus-1.0
wab-1.0
blueprint-1.0
webProfile-7.0
eventLogging-1.0
requestTiming-1.0
adminCenter-1.0concurrent-1.0
bells-1.0
samlWeb-2.0
httpWhiteboard-1.0
federatedRepository-1.0
constrainedDelegation-1.0
osgiBundle-1.0
passwordUtilities-1.0
bluemixUtility-1.0
apiDiscovery-1.0logstashCollector-1.0
scim-1.0
microProfile-1.0 openid-2.0
monitor-1.0
servlet-3.1
jsp-2.3
jsf-2.2
ejbLite-3.2 jdbc-4.1
jndi-1.0
appSecurity-2.0
managedBeans-1.0
ssl-1.0
beanValidation-1.1
cdi-1.2
jpa-2.1
el-3.0websocket-1.1
websocket-1.0
jsonp-1.0
jaxrs-2.0 jaxrsClient-2.0
New in
1Q17
New in
4Q16
New in
2Q16
New in
3Q16
Liberty features – Java EE 6
zOS
ND
Core
Base
zosConnect-1.2
zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0
zosRequestLogging-1.0batchSMFLogging-1.0
scalingController-1.0
scalingMember-1.0
dynamicRouting-1.0
collectiveController-1.0 clusterMember-1.0
healthManager-1.0healthAnalyzer-1.0
Java EE 6
subset
couchdb-1.0
mongodb-2.0
wsSecurity-1.1
javaee-7.0
batchManagement-1.0
rtcomm-1.0 rtcommGateway-1.0
sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0
wsAtomicTransaction-1.2cloudant-1.0
webProfile-6.0
distributedMap-1.0
productInsights-1.0
openidConnectServer-1.0
openidConnectClient-1.0
osgiAppIntegration-1.0
spnego-1.0
collectiveMember-1.0
restConnector-2.0
sessionDatabase-1.0
ldapRegistry-3.0
webCache-1.0
javaMail-1.5
osgiConsole-1.0
json-1.0
timedOperations-1.0transportSecurity-1.0
oauth-2.0
serverStatus-1.0
wab-1.0
blueprint-1.0
webProfile-7.0
eventLogging-1.0
requestTiming-1.0
adminCenter-1.0concurrent-1.0
bells-1.0
samlWeb-2.0
httpWhiteboard-1.0
federatedRepository-1.0
constrainedDelegation-1.0
osgiBundle-1.0
passwordUtilities-1.0
bluemixUtility-1.0
apiDiscovery-1.0logstashCollector-1.0
scim-1.0
microProfile-1.0 openid-2.0
monitor-1.0
servlet-3.0
jsp-2.2
jsf-2.0
jdbc-4.0
jndi-1.0
appSecurity-2.0
managedBeans-1.0
ssl-1.0
beanValidation-1.0
cdi-1.0
jpa-2.0
jaxrs-1.1
jca-1.6
jms-1.1
jaxws-2.2
jaxb-2.2
wmqJmsClient-1.1
wasJmsClient-1.1
mdb-3.1
New in
1Q17
New in
4Q16
New in
2Q16
New in
3Q16
Liberty features – Java EE 7 Full Platform
zOS
ND
Core
Base
zosConnect-1.2
zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0
zosRequestLogging-1.0batchSMFLogging-1.0
scalingController-1.0
scalingMember-1.0
dynamicRouting-1.0
collectiveController-1.0 clusterMember-1.0
healthManager-1.0healthAnalyzer-1.0
Java EE 6
subset
couchdb-1.0
mongodb-2.0
wsSecurity-1.1
javaee-7.0
batchManagement-1.0
rtcomm-1.0 rtcommGateway-1.0
sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0
wsAtomicTransaction-1.2cloudant-1.0
webProfile-6.0
distributedMap-1.0
productInsights-1.0
openidConnectServer-1.0
openidConnectClient-1.0
osgiAppIntegration-1.0
spnego-1.0
collectiveMember-1.0
restConnector-2.0
sessionDatabase-1.0
ldapRegistry-3.0
webCache-1.0
javaMail-1.5
osgiConsole-1.0
json-1.0
timedOperations-1.0transportSecurity-1.0
oauth-2.0
serverStatus-1.0
wab-1.0
blueprint-1.0
webProfile-7.0
eventLogging-1.0
requestTiming-1.0
adminCenter-1.0concurrent-1.0
bells-1.0
samlWeb-2.0
httpWhiteboard-1.0
federatedRepository-1.0
constrainedDelegation-1.0
osgiBundle-1.0
passwordUtilities-1.0
bluemixUtility-1.0
apiDiscovery-1.0logstashCollector-1.0
scim-1.0
microProfile-1.0 openid-2.0
monitor-1.0
servlet-3.1
jsp-2.3
jsf-2.2
ejbLite-3.2
jdbc-4.1
jndi-1.0
appSecurity-2.0
managedBeans-1.0
ssl-1.0
beanValidation-1.1
cdi-1.2
jpa-2.1
el-3.0
websocket-1.1
websocket-1.0
jsonp-1.0
jaxrs-2.0 jaxrsClient-2.0
concurrent-1.0
appClientSupport-1.0
ejbPersistentTimer-1.0
ejbHome-3.2
ejbRemote-3.2
ejb-3.2
mdb-3.2
j2eeManagement-1.1
jacc-1.5
jaspic-1.1
jca-1.7
jms-2.0
wmqJmsClient-2.0
wasJmsClient-2.0
jaxws-2.2
jaxb-2.2
batch-1.0 javaMail-1.5
New in
1Q17
New in
4Q16
New in
2Q16
New in
3Q16
• WebSphere Application Server Liberty
– v8.5.5.6 – Full Java EE 7 platform support
– Available since 2Q2015
– https://developer.ibm.com/wasdev/downloads/#asset/runtimes-8.5.5-wlp-javaee7
• WebSphere Application Server traditional
– V9.0 – Full Java EE 7 platform support
– Available since 2Q2016
– https://www-01.ibm.com/support/docview.wss?uid=swg27048323
– Bluemix:
https://console.ng.bluemix.net/docs/services/ApplicationServeronCloud/index.html
WebSphere Support for Java EE 7
39
Overview
Java EE 8 Introduction
• Java EE 8 Platform (JSR 366)
– Development cycling fast
– Most child specifications have early draft reviews available
– Target date is 3Q2017 for GA of platform specifications
Java EE 8 Introduction
41
• JSON-B 1.0 (JSR 367)
– Binding complement to JSON-P in Java EE 7
• Java EE Security 1.0 (JSR 375)
– Modernization of security-related JSRs
• Servlet 4.0 (JSR 369)
– HTTP/2 support
• CDI 2.0 (JSR 365)
– CDI Core, CDI Java SE, CDI Java EE
• Bean Validation 2.0 (JSR 380)
– Container element validation via annotations on type arguments of generics
• JAX-RS 2.1 (JSR 370)
– Server sent events
• JSF 2.3 (JSR 372)
– Better integration with CDI and JSON via Ajax API
• JSON-P 1.1 (JSR 374)
– Complementary support for JSON-B 1.0
Java EE 8 – Major New Specifications
42
Resources
Java EE Samples
• WASDev GitHub site
– https://github.com/WASdev?utf8=%E2%9C%93&q=sample.javaee7&type=&language=
– Java EE 7 samples with instructions on deploying to both WebSphere Liberty and WebSphere traditional v9 Beta
– The README.md file (as well as the GitHub page) have helpful configuration information
– Following technologies are currently available with complete instructions for WebSphere
• Web Sockets 1.0/1.1
• Concurrency 1.0
• JTA 1.2
• JMS 2.0
• Servlet 3.1
• EL 3.0
• JSON-P 1.0
• JAX-RS 2.0
• Java Batch 1.0
• PlantsByWebSphere
– https://github.com/WASdev/sample.plantsbywebsphere
• WASDev Posts to help you get started
– https://developer.ibm.com/wasdev/docs/running-java-ee-7-samples-liberty-using-eclipse/
– https://developer.ibm.com/wasdev/docs/running-the-java-ee-7-samples-on-was-liberty/
44 44
Sampling of Related Sessions…
• HAJ-4308: OpenJPA, EclipseLink, and the WebSphere Migration Toolkit
– Monday, Mar 20, 1:00pm-1:45pm, Mandalay Bay South, Level 2 – Reef B
• HAM-4393: MicroProfile, Java EE, and the Application Server
– Monday, Mar 20, 2:00-2:45pm, Mandalay Bay North, Level 0 – Islander F
• 1842: Technical Deep-Dive into IBM WebSphere Liberty
– Tuesday, Mar 21, 1:30-2:15pm, Mandalay Bay North, Level 0 – Islander G
– Tuesday, Mar 21, 4:45-5:30pm, Surf D
• 7014: Roundtable Discussion on Building Java Microservices with WebSphere Liberty
– Monday, Mar 20, 2:00-2:45pm, Tropics A
– Wednesday, Mar 22, 8:00-8:45am, Tropics A
• HAJ-4328: Java EE 7 Overview
– Wednesday, Mar 22, 8:00-8:45am, Mandalay Bay South, Level 2 – Reef B
• BAS-5676: Java EE 8 Introduction
– Wednesday, Mar 22, 2:00-2:45pm, Mandalay Bay North, Level 0 – South Pacific A
• BMC-4286: MicroProfile: A Programming Model for Microservices-Based Applications
– Wednesday, Mar 22, 4:15-5:00pm, Mandalay Bay North, Level 0 – South Pacific A
• HAJ-4344: Java SE 9 and the Application Server
– Thursday, Mar 23, 10:30-11:15am, Mandalay Bay South, Level 2 – Reef B
• 1835: Agile Development Using MicroProfile and IBM WebSphere Liberty (Lab)
– Thursday, Mar 23, 10:30-12:15pm, South Seas D
45 45
Questions?
47 3/21/17
Notices and disclaimers
Copyright © 2017 by International Business Machines Corporation
(IBM). No part of this document may be reproduced or transmitted in
any form without written permission from IBM.
U.S. Government Users Restricted Rights — use, duplication or
disclosure restricted by GSA ADP Schedule Contract with IBM.
Information in these presentations (including information relating to
products that have not yet been announced by IBM) has been
reviewed for accuracy as of the date of initial publication and could
include unintentional technical or typographical errors. IBM shall have
no responsibility to update this information. This document is
distributed “as is” without any warranty, either express or
implied. In no event shall IBM be liable for any damage arising
from the use of this information, including but not limited to, loss
of data, business interruption, loss of profit or loss of
opportunity. IBM products and services are warranted according to
the terms and conditions of the agreements under which they are
provided.
IBM products are manufactured from new parts or new and used parts.
In some cases, a product may not be new and may have been
previously installed. Regardless, our warranty terms apply.”
Any statements regarding IBM's future direction, intent or
product plans are subject to change or withdrawal without notice.
Performance data contained herein was generally obtained in a
controlled, isolated environments. Customer examples are presented
as illustrations of how those customers have used IBM products and
the results they may have achieved. Actual performance, cost, savings
or other results in other operating environments may vary.
References in this document to IBM products, programs, or services
does not imply that IBM intends to make such products, programs or
services available in all countries in which IBM operates or does
business.
Workshops, sessions and associated materials may have been
prepared by independent session speakers, and do not necessarily
reflect the
views of IBM. All materials and discussions are provided for
informational purposes only, and are neither intended to, nor shall
constitute legal or other guidance or advice to any individual participant
or their specific situation.
It is the customer’s responsibility to insure its own compliance
with legal requirements and to obtain advice of competent legal
counsel as to the identification and interpretation of any relevant laws
and regulatory requirements that may affect the customer’s business
and any actions
the customer may need to take to comply with such laws. IBM does
not provide legal advice or represent or warrant that its services or
products will ensure that the customer is in compliance with any law.
48 3/21/17
Notices and disclaimers
continued
Information concerning non-IBM products was obtained from the
suppliers of those products, their published announcements or other
publicly available sources. IBM has not tested those products in
connection with this publication and cannot confirm the accuracy of
performance, compatibility or any other claims related to non-IBM
products. Questions on the capabilities of non-IBM products should be
addressed to the suppliers of those products. IBM does not warrant the
quality of any third-party products, or the ability of any such third-party
products to interoperate with IBM’s products. IBM expressly
disclaims all warranties, expressed or implied, including but not
limited to, the implied warranties of merchantability and fitness
for a particular, purpose.
The provision of the information contained herein is not intended to,
and does not, grant any right or license under any IBM patents,
copyrights, trademarks or other intellectual property right.
IBM, the IBM logo, ibm.com, Aspera®, Bluemix, Blueworks Live, CICS,
Clearcase, Cognos®, DOORS®, Emptoris®, Enterprise Document
Management System™, FASP®, FileNet®, Global Business Services®,
Global Technology Services®, IBM ExperienceOne™, IBM
SmartCloud®, IBM Social Business®, Information on Demand, ILOG,
Maximo®, MQIntegrator®, MQSeries®, Netcool®, OMEGAMON,
OpenPower, PureAnalytics™, PureApplication®, pureCluster™,
PureCoverage®, PureData®, PureExperience®, PureFlex®,
pureQuery®, pureScale®, PureSystems®, QRadar®, Rational®,
Rhapsody®, Smarter Commerce®, SoDA, SPSS, Sterling Commerce®,
StoredIQ, Tealeaf®, Tivoli® Trusteer®, Unica®, urban{code}®, Watson,
WebSphere®, Worklight®, X-Force® and System z® Z/OS, are
trademarks of International Business Machines Corporation, registered
in many jurisdictions worldwide. Other product and service names
might be trademarks of IBM or other companies. A current list of IBM
trademarks is available on the Web at "Copyright and trademark
information" at: www.ibm.com/legal/copytrade.shtml.
InterConnect
2017
49 3/21/17

Haj 4328-java ee 7 overview

  • 1.
    InterConnect 2017 HAJ-4328: Java EE 7Overview Kevin Sutter, STSM Java EE Architect
  • 2.
    1 3/21/17 Please note IBM’sstatements regarding its plans, directions, and intent are subject to change or withdrawal without notice at IBM’s sole discretion. Information regarding potential future products is intended to outline our general product direction and it should not be relied on in making a purchasing decision. The information mentioned regarding potential future products is not a commitment, promise, or legal obligation to deliver any material, code or functionality. Information about potential future products may not be incorporated into any contract. The development, release, and timing of any future features or functionality described for our products remains at our sole discretion. Performance is based on measurements and projections using standard IBM benchmarks in a controlled environment. The actual throughput or performance that any user will experience will vary depending upon many factors, including considerations such as the amount of multiprogramming in the user’s job stream, the I/O configuration, the storage configuration, and the workload processed. Therefore, no assurance can be given that an individual user will achieve results similar to those stated here.
  • 3.
    Java: Broadest IndustryAdoption 10,000,000 JAVA DEVELOPERS and growing… DEPLOYING TO 18 COMPLIANT APPLICATION SERVERS 2
  • 4.
    Java EE 7Platform 3
  • 5.
    The Year ofJava EE 7 Note: Unsupported Platforms Note: Unsupported platforms“WebLogic 12.2.1 with full support for Java EE 7 is slated to be released in just months (the officially sanctioned timeline states calendar year 2015 which means the end of this year at the very latest)” https://blogs.oracle.com/reza/entry/the_ghosts _of_java_ee, 8 June 2015 IBM Marketing Announce WAS V8.0 – First fully-supported Java EE 6 Server WAS V8.5.5.6 – First fully-supported Java EE 7 Server 4
  • 6.
    Java EE 7Themes § Batch § Concurrency § Simplified JMS § More annotated POJOs § Less boilerplate code § Cohesive integrated platform DEVELOPER PRODUCTIVITY § WebSockets § JSON § Servlet 3.1 NIO § REST MEETING ENTERPRISE DEMANDS Java EE 7 5
  • 7.
    Top Ten Featuresin Java EE 7 1. WebSocket client/server endpoints 2. Batch Applications 3. JSON Processing 4. Concurrency Utilities 5. Simplified JMS API 6. @Transactional and @TransactionScoped 7. JAX-RS Client API 8. Default Resources 9. CDI Managed Beans 10. More annotated POJOs 6
  • 8.
    Java API forWebSocket 1.0/1.1 • Server and Client WebSocket Endpoint – Annotated: @ServerEndpoint, @ClientEndpoint – Programmatic: Endpoint • Lifecycle events support • Standard Packaging and Deployment @ServerEndpoint("/chat") public class ChatServer { @OnMessage public void chat(String m) { . . . } } Available Liberty v8.5.5.6 and WAS v9! 7
  • 9.
    Java API forWebSocket 1.0 @ServerEndpoint("/chat") public class ChatBean { static Set<Session> peers = Collections.synchronizedSet(...); @OnOpen public void onOpen(Session peer) { peers.add(peer); } @OnClose public void onClose(Session peer) { peers.remove(peer); } . . . Chat Server 8
  • 10.
    Java API forWebSocket 1.0 . . . @OnMessage public void message(String message) { for (Session peer : peers) { peer.getRemote().sendObject(message); } } } Chat Server (contd.) 9
  • 11.
    JSON Processing 1.0 •API to parse and generate JSON • Streaming API – Low-level, efficient way to parse/generate JSON – Similar to StAX API in XML world • Object Model API – Simple, easy to use high-level API – Similar to DOM API in XML world Available Liberty v8.5.5.6 and WAS v9! 10
  • 12.
    { "firstName": "John", "lastName":"Smith", "age": 25, "phoneNumber": [ { "type": "home", "number": "212 555-1234" }, { "type": "fax", "number": "646 555-4567" } ] } JsonParser p = Json.createParser(...); JsonParser.Event event = p.next(); // START_OBJECT event = p.next(); // KEY_NAME event = p.next(); // VALUE_STRING String name = p.getString(); // "John” Java API for JSON Processing 1.0 Streaming API 11
  • 13.
    Batch Applications forJava Platform 1.0 • Suited for non-interactive, bulk-oriented, and long-running tasks • Batch execution: sequential, parallel, decision-based • Processing Styles – Item-oriented: Chunked (primary) – Task-oriented: Batchlet Available Liberty v8.5.5.6 and WAS v9! 12
  • 14.
    Batch Applications 1.0 Concepts Metadatafor jobs Manage batch process Batch process Independent sequential phase of job Chunk 13
  • 15.
    <step id="sendStatements"> <chunk item-count="3"> <readerref="accountReader"/> <processor ref="accountProcessor"/> <writer ref="emailWriter"/> </step> ...implements ItemReader { public Object readItem() { // read account using JPA } ...implements ItemProcessor { Public Object processItems(Object account) { // read Account, return Statement } ...implements ItemWriter { public void writeItems(List statements) { // use JavaMail to send email } Batch Applications 1.0 Chunked Job Specification 14
  • 16.
    Concurrency Utilities forJava EE 1.0 • Extension of Java SE Concurrency Utilities API • Provide asynchronous capabilities to Java EE application components • Provides 4 types of managed objects – ManagedExecutorService – ManagedScheduledExecutorService – ManagedThreadFactory – ContextService • Context Propagation Available Liberty v8.5.5.6 and WAS v9! 15
  • 17.
    Concurrency Utilities forJava EE 1.0 public class TestServlet extends HttpPServlet { @Resource(name="java:comp/DefaultManagedExecutorService") ManagedExecutorService executor; Future future = executor.submit(new MyTask()); class MyTask implements Runnable { public void run() { . . . // task logic } } } Submit Tasks to ManagedExecutorService using JNDI 16
  • 18.
    Java Message Service2.0 • New JMSContext interface • AutoCloseable JMSContext, Connection, Session, … • Use of runtime exceptions • Method chaining on JMSProducer • Simplified message sending Get More from Less Java EE 7 Available Liberty v8.5.5.6 and WAS v9! 17
  • 19.
    @Resource(lookup = "myConnectionFactory") ConnectionFactoryconnectionFactory; @Resource(lookup = "myQueue") Queue myQueue; public void sendMessage (String payload) { Connection connection = null; try { connection = connectionFactory.createConnection(); Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE); MessageProducer messageProducer = session.createProducer(myQueue); TextMessage textMessage = session.createTextMessage(payload); messageProducer.send(textMessage); } catch (JMSException ex) { //. . . } finally { if (connection != null) { try { connection.close(); } catch (JMSException ex) { //. . . } } } } Application Server Specific Resources Boilerplate Code Exception Handling Java Message Service 2.0 Sending a Message using JMS 1.1 18
  • 20.
    Java Message Service2.0 @Inject JMSContext context; @Resource(lookup = "java:global/jms/demoQueue") Queue demoQueue; public void sendMessage(String payload) { context.createProducer().send(demoQueue, payload); } Sending a Message 19
  • 21.
    Java API forRESTful Web Services 2.0 • Client API • Message Filters and Entity Interceptors • Asynchronous Processing – Server and Client • Common Configuration Available Liberty v8.5.5.6 and WAS v9! 20
  • 22.
    Java API forRESTful Web Services 2.0 // Get instance of Client Client client = ClientBuilder.newClient(); // Get customer name for the shipped products String name = client.target("../orders/{orderId}/customer") .resolveTemplate("orderId", "10") .queryParam("shipped", "true") .request() .get(String.class); Client API 21
  • 23.
    Contexts and DependencyInjection 1.1/1.2 • Automatic enablement for beans with scope annotation and EJBs – “beans.xml” is optional • Bean discovery mode – all: All types – annotated: Types with bean defining annotation (default) – none: Disable CDI • @Vetoed for programmatic disablement of classes • Global ordering/priority of interceptors and decorators Available Liberty v8.5.5.6 and WAS v9! 22
  • 24.
    Bean Validation 1.1 •Alignment with Dependency Injection • Method-level validation – Constraints on parameters and return values – Check pre-/post-conditions • Integration with JAX-RS Java EE 7 Available Liberty v8.5.5.6 and WAS v9! 23
  • 25.
    Built-in Custom @Future public Date getAppointment(){ //. . . } public void placeOrder( @NotNull String productName, @NotNull @Max("10") Integer quantity, @Customer String customer) { //. . . } Bean Validation 1.1 Method Parameter and Result Validation 24
  • 26.
    Java Persistence API2.1 • Schema Generation – javax.persistence.schema-generation.* properties • Unsynchronized Persistence Contexts • Bulk update/delete using Criteria • User-defined functions using FUNCTION • Stored Procedure Query • Entity Graphs Available Liberty v8.5.5.6 and WAS v9! 25
  • 27.
    Servlet 3.1 • Non-blockingI/O • Protocol Upgrade – HttpUpgradeHandler – necessary for Web Sockets • Security Enhancements – <deny-uncovered-http-methods>: Deny request to HTTP methods not explicitly covered by specified constaints Available Liberty v8.5.5.6 and WAS v9! 26
  • 28.
    Servlet 3.1 public classTestServlet extends HttpServlet protected void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { ServletInputStream input = request.getInputStream(); byte[] b = new byte[1024]; int len = -1; while ((len = input.read(b)) != -1) { . . . } } } Non-blocking I/O Traditional 27
  • 29.
    Servlet 3.1 AsyncContext context= request.startAsync(); ServletInputStream input = request.getInputStream(); input.setReadListener( new MyReadListener(input, context)); Non-blocking I/O: doGet 28
  • 30.
    Servlet 3.1 @Override public voidonDataAvailable() { try { StringBuilder sb = new StringBuilder(); int len = -1; byte b[] = new byte[1024]; while (input.isReady() && (len = input.read(b)) != -1) { String data = new String(b, 0, len); System.out.println("--> " + data); } } catch (IOException ex) { . . . } } . . . Non-blocking read 29
  • 31.
    JavaServer Faces 2.2 •Faces Flow • Resource Library Contracts • HTML5 Friendly Markup Support – Pass through attributes and elements • Cross Site Request Forgery Protection • Loading Facelets via ResourceHandler • h:inputFile: New File Upload Component Available Liberty v8.5.5.6 and WAS v9! 30
  • 32.
    Java Transaction API1.2 § @Transactional: Define transaction boundaries on CDI managed beans • @TransactionScoped: CDI scope for bean instances scoped to the active JTA transaction Java EE 7 Available Liberty v8.5.5.6 and WAS v9! 31
  • 33.
    EJB 3.2 Servlet 3.1 CDI Extensions BeanValidation1.1 Batch1.0 Web Fragments Java EE 7 JSRs JCA 1.7JMS 2.0JPA 2.1 Managed Beans 1.0 Concurrency 1.0 Common Annotations 1.1 Interceptors 1.2, JTA 1.2 CDI 1.1 JSF 2.2, JSP 2.3, EL 3.0 JAX-RS 2.0, JAX-WS 2.2 JSON 1.0 WebSocket 1.0 32
  • 34.
  • 35.
    Liberty features –including Java EE 7 zOS ND Core Base scalingController-1.0 scalingMember-1.0 dynamicRouting-1.0 collectiveController-1.0 clusterMember-1.0 healthManager-1.0healthAnalyzer-1.0 Java EE 6 subset couchdb-1.0 mongodb-2.0 wsSecurity-1.1 javaee-7.0 batchManagement-1.0 rtcomm-1.0 rtcommGateway-1.0 sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0 wsAtomicTransaction-1.2cloudant-1.0 zosConnect-1.2 zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0 zosRequestLogging-1.0batchSMFLogging-1.0 New in 1Q17 New in 4Q16 New in 2Q16 New in 3Q16 webProfile-6.0 distributedMap-1.0 productInsights-1.0 openidConnectServer-1.0 openidConnectClient-1.0 osgiAppIntegration-1.0 spnego-1.0 collectiveMember-1.0 restConnector-2.0 sessionDatabase-1.0 ldapRegistry-3.0 webCache-1.0 javaMail-1.5 osgiConsole-1.0 json-1.0 timedOperations-1.0transportSecurity-1.0 oauth-2.0 serverStatus-1.0 wab-1.0 blueprint-1.0 webProfile-7.0 eventLogging-1.0 requestTiming-1.0 adminCenter-1.0concurrent-1.0 bells-1.0 samlWeb-2.0 httpWhiteboard-1.0 federatedRepository-1.0 constrainedDelegation-1.0 osgiBundle-1.0 passwordUtilities-1.0 bluemixUtility-1.0 apiDiscovery-1.0logstashCollector-1.0 scim-1.0 microProfile-1.0 openid-2.0 monitor-1.0
  • 36.
    Liberty features –Java EE 6 Web Profile zOS ND Core Base zosConnect-1.2 zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0 zosRequestLogging-1.0batchSMFLogging-1.0 scalingController-1.0 scalingMember-1.0 dynamicRouting-1.0 collectiveController-1.0 clusterMember-1.0 healthManager-1.0healthAnalyzer-1.0 Java EE 6 subset couchdb-1.0 mongodb-2.0 wsSecurity-1.1 javaee-7.0 batchManagement-1.0 rtcomm-1.0 rtcommGateway-1.0 sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0 wsAtomicTransaction-1.2cloudant-1.0 webProfile-6.0 distributedMap-1.0 productInsights-1.0 openidConnectServer-1.0 openidConnectClient-1.0 osgiAppIntegration-1.0 spnego-1.0 collectiveMember-1.0 restConnector-2.0 sessionDatabase-1.0 ldapRegistry-3.0 webCache-1.0 javaMail-1.5 osgiConsole-1.0 json-1.0 timedOperations-1.0transportSecurity-1.0 oauth-2.0 serverStatus-1.0 wab-1.0 blueprint-1.0 webProfile-7.0 eventLogging-1.0 requestTiming-1.0 adminCenter-1.0concurrent-1.0 bells-1.0 samlWeb-2.0 httpWhiteboard-1.0 federatedRepository-1.0 constrainedDelegation-1.0 osgiBundle-1.0 passwordUtilities-1.0 bluemixUtility-1.0 apiDiscovery-1.0logstashCollector-1.0 scim-1.0 microProfile-1.0 openid-2.0 monitor-1.0 servlet-3.0 jsp-2.0 jsf-2.0 ejbLite-3.1 jdbc-4.0 jndi-1.0 appSecurity-2.0 managedBeans-1.0 ssl-1.0 beanValidation-1.0 cdi-1.0 jpa-2.0 New in 1Q17 New in 4Q16 New in 2Q16 New in 3Q16
  • 37.
    Liberty features –Java EE 7 Web Profile zOS ND Core Base zosConnect-1.2 zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0 zosRequestLogging-1.0batchSMFLogging-1.0 scalingController-1.0 scalingMember-1.0 dynamicRouting-1.0 collectiveController-1.0 clusterMember-1.0 healthManager-1.0healthAnalyzer-1.0 Java EE 6 subset couchdb-1.0 mongodb-2.0 wsSecurity-1.1 javaee-7.0 batchManagement-1.0 rtcomm-1.0 rtcommGateway-1.0 sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0 wsAtomicTransaction-1.2cloudant-1.0 webProfile-6.0 distributedMap-1.0 productInsights-1.0 openidConnectServer-1.0 openidConnectClient-1.0 osgiAppIntegration-1.0 spnego-1.0 collectiveMember-1.0 restConnector-2.0 sessionDatabase-1.0 ldapRegistry-3.0 webCache-1.0 javaMail-1.5 osgiConsole-1.0 json-1.0 timedOperations-1.0transportSecurity-1.0 oauth-2.0 serverStatus-1.0 wab-1.0 blueprint-1.0 webProfile-7.0 eventLogging-1.0 requestTiming-1.0 adminCenter-1.0concurrent-1.0 bells-1.0 samlWeb-2.0 httpWhiteboard-1.0 federatedRepository-1.0 constrainedDelegation-1.0 osgiBundle-1.0 passwordUtilities-1.0 bluemixUtility-1.0 apiDiscovery-1.0logstashCollector-1.0 scim-1.0 microProfile-1.0 openid-2.0 monitor-1.0 servlet-3.1 jsp-2.3 jsf-2.2 ejbLite-3.2 jdbc-4.1 jndi-1.0 appSecurity-2.0 managedBeans-1.0 ssl-1.0 beanValidation-1.1 cdi-1.2 jpa-2.1 el-3.0websocket-1.1 websocket-1.0 jsonp-1.0 jaxrs-2.0 jaxrsClient-2.0 New in 1Q17 New in 4Q16 New in 2Q16 New in 3Q16
  • 38.
    Liberty features –Java EE 6 zOS ND Core Base zosConnect-1.2 zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0 zosRequestLogging-1.0batchSMFLogging-1.0 scalingController-1.0 scalingMember-1.0 dynamicRouting-1.0 collectiveController-1.0 clusterMember-1.0 healthManager-1.0healthAnalyzer-1.0 Java EE 6 subset couchdb-1.0 mongodb-2.0 wsSecurity-1.1 javaee-7.0 batchManagement-1.0 rtcomm-1.0 rtcommGateway-1.0 sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0 wsAtomicTransaction-1.2cloudant-1.0 webProfile-6.0 distributedMap-1.0 productInsights-1.0 openidConnectServer-1.0 openidConnectClient-1.0 osgiAppIntegration-1.0 spnego-1.0 collectiveMember-1.0 restConnector-2.0 sessionDatabase-1.0 ldapRegistry-3.0 webCache-1.0 javaMail-1.5 osgiConsole-1.0 json-1.0 timedOperations-1.0transportSecurity-1.0 oauth-2.0 serverStatus-1.0 wab-1.0 blueprint-1.0 webProfile-7.0 eventLogging-1.0 requestTiming-1.0 adminCenter-1.0concurrent-1.0 bells-1.0 samlWeb-2.0 httpWhiteboard-1.0 federatedRepository-1.0 constrainedDelegation-1.0 osgiBundle-1.0 passwordUtilities-1.0 bluemixUtility-1.0 apiDiscovery-1.0logstashCollector-1.0 scim-1.0 microProfile-1.0 openid-2.0 monitor-1.0 servlet-3.0 jsp-2.2 jsf-2.0 jdbc-4.0 jndi-1.0 appSecurity-2.0 managedBeans-1.0 ssl-1.0 beanValidation-1.0 cdi-1.0 jpa-2.0 jaxrs-1.1 jca-1.6 jms-1.1 jaxws-2.2 jaxb-2.2 wmqJmsClient-1.1 wasJmsClient-1.1 mdb-3.1 New in 1Q17 New in 4Q16 New in 2Q16 New in 3Q16
  • 39.
    Liberty features –Java EE 7 Full Platform zOS ND Core Base zosConnect-1.2 zosLocalAdapters-1.0zosSecurity-1.0 zosTransaction-1.0 zosWlm-1.0 zosRequestLogging-1.0batchSMFLogging-1.0 scalingController-1.0 scalingMember-1.0 dynamicRouting-1.0 collectiveController-1.0 clusterMember-1.0 healthManager-1.0healthAnalyzer-1.0 Java EE 6 subset couchdb-1.0 mongodb-2.0 wsSecurity-1.1 javaee-7.0 batchManagement-1.0 rtcomm-1.0 rtcommGateway-1.0 sipServlet-1.0 wsSecuritySaml-1.1 mediaServerControl-1.0 wsAtomicTransaction-1.2cloudant-1.0 webProfile-6.0 distributedMap-1.0 productInsights-1.0 openidConnectServer-1.0 openidConnectClient-1.0 osgiAppIntegration-1.0 spnego-1.0 collectiveMember-1.0 restConnector-2.0 sessionDatabase-1.0 ldapRegistry-3.0 webCache-1.0 javaMail-1.5 osgiConsole-1.0 json-1.0 timedOperations-1.0transportSecurity-1.0 oauth-2.0 serverStatus-1.0 wab-1.0 blueprint-1.0 webProfile-7.0 eventLogging-1.0 requestTiming-1.0 adminCenter-1.0concurrent-1.0 bells-1.0 samlWeb-2.0 httpWhiteboard-1.0 federatedRepository-1.0 constrainedDelegation-1.0 osgiBundle-1.0 passwordUtilities-1.0 bluemixUtility-1.0 apiDiscovery-1.0logstashCollector-1.0 scim-1.0 microProfile-1.0 openid-2.0 monitor-1.0 servlet-3.1 jsp-2.3 jsf-2.2 ejbLite-3.2 jdbc-4.1 jndi-1.0 appSecurity-2.0 managedBeans-1.0 ssl-1.0 beanValidation-1.1 cdi-1.2 jpa-2.1 el-3.0 websocket-1.1 websocket-1.0 jsonp-1.0 jaxrs-2.0 jaxrsClient-2.0 concurrent-1.0 appClientSupport-1.0 ejbPersistentTimer-1.0 ejbHome-3.2 ejbRemote-3.2 ejb-3.2 mdb-3.2 j2eeManagement-1.1 jacc-1.5 jaspic-1.1 jca-1.7 jms-2.0 wmqJmsClient-2.0 wasJmsClient-2.0 jaxws-2.2 jaxb-2.2 batch-1.0 javaMail-1.5 New in 1Q17 New in 4Q16 New in 2Q16 New in 3Q16
  • 40.
    • WebSphere ApplicationServer Liberty – v8.5.5.6 – Full Java EE 7 platform support – Available since 2Q2015 – https://developer.ibm.com/wasdev/downloads/#asset/runtimes-8.5.5-wlp-javaee7 • WebSphere Application Server traditional – V9.0 – Full Java EE 7 platform support – Available since 2Q2016 – https://www-01.ibm.com/support/docview.wss?uid=swg27048323 – Bluemix: https://console.ng.bluemix.net/docs/services/ApplicationServeronCloud/index.html WebSphere Support for Java EE 7 39
  • 41.
    Overview Java EE 8Introduction
  • 42.
    • Java EE8 Platform (JSR 366) – Development cycling fast – Most child specifications have early draft reviews available – Target date is 3Q2017 for GA of platform specifications Java EE 8 Introduction 41
  • 43.
    • JSON-B 1.0(JSR 367) – Binding complement to JSON-P in Java EE 7 • Java EE Security 1.0 (JSR 375) – Modernization of security-related JSRs • Servlet 4.0 (JSR 369) – HTTP/2 support • CDI 2.0 (JSR 365) – CDI Core, CDI Java SE, CDI Java EE • Bean Validation 2.0 (JSR 380) – Container element validation via annotations on type arguments of generics • JAX-RS 2.1 (JSR 370) – Server sent events • JSF 2.3 (JSR 372) – Better integration with CDI and JSON via Ajax API • JSON-P 1.1 (JSR 374) – Complementary support for JSON-B 1.0 Java EE 8 – Major New Specifications 42
  • 44.
  • 45.
    Java EE Samples •WASDev GitHub site – https://github.com/WASdev?utf8=%E2%9C%93&q=sample.javaee7&type=&language= – Java EE 7 samples with instructions on deploying to both WebSphere Liberty and WebSphere traditional v9 Beta – The README.md file (as well as the GitHub page) have helpful configuration information – Following technologies are currently available with complete instructions for WebSphere • Web Sockets 1.0/1.1 • Concurrency 1.0 • JTA 1.2 • JMS 2.0 • Servlet 3.1 • EL 3.0 • JSON-P 1.0 • JAX-RS 2.0 • Java Batch 1.0 • PlantsByWebSphere – https://github.com/WASdev/sample.plantsbywebsphere • WASDev Posts to help you get started – https://developer.ibm.com/wasdev/docs/running-java-ee-7-samples-liberty-using-eclipse/ – https://developer.ibm.com/wasdev/docs/running-the-java-ee-7-samples-on-was-liberty/ 44 44
  • 46.
    Sampling of RelatedSessions… • HAJ-4308: OpenJPA, EclipseLink, and the WebSphere Migration Toolkit – Monday, Mar 20, 1:00pm-1:45pm, Mandalay Bay South, Level 2 – Reef B • HAM-4393: MicroProfile, Java EE, and the Application Server – Monday, Mar 20, 2:00-2:45pm, Mandalay Bay North, Level 0 – Islander F • 1842: Technical Deep-Dive into IBM WebSphere Liberty – Tuesday, Mar 21, 1:30-2:15pm, Mandalay Bay North, Level 0 – Islander G – Tuesday, Mar 21, 4:45-5:30pm, Surf D • 7014: Roundtable Discussion on Building Java Microservices with WebSphere Liberty – Monday, Mar 20, 2:00-2:45pm, Tropics A – Wednesday, Mar 22, 8:00-8:45am, Tropics A • HAJ-4328: Java EE 7 Overview – Wednesday, Mar 22, 8:00-8:45am, Mandalay Bay South, Level 2 – Reef B • BAS-5676: Java EE 8 Introduction – Wednesday, Mar 22, 2:00-2:45pm, Mandalay Bay North, Level 0 – South Pacific A • BMC-4286: MicroProfile: A Programming Model for Microservices-Based Applications – Wednesday, Mar 22, 4:15-5:00pm, Mandalay Bay North, Level 0 – South Pacific A • HAJ-4344: Java SE 9 and the Application Server – Thursday, Mar 23, 10:30-11:15am, Mandalay Bay South, Level 2 – Reef B • 1835: Agile Development Using MicroProfile and IBM WebSphere Liberty (Lab) – Thursday, Mar 23, 10:30-12:15pm, South Seas D 45 45
  • 47.
  • 48.
    47 3/21/17 Notices anddisclaimers Copyright © 2017 by International Business Machines Corporation (IBM). No part of this document may be reproduced or transmitted in any form without written permission from IBM. U.S. Government Users Restricted Rights — use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM. Information in these presentations (including information relating to products that have not yet been announced by IBM) has been reviewed for accuracy as of the date of initial publication and could include unintentional technical or typographical errors. IBM shall have no responsibility to update this information. This document is distributed “as is” without any warranty, either express or implied. In no event shall IBM be liable for any damage arising from the use of this information, including but not limited to, loss of data, business interruption, loss of profit or loss of opportunity. IBM products and services are warranted according to the terms and conditions of the agreements under which they are provided. IBM products are manufactured from new parts or new and used parts. In some cases, a product may not be new and may have been previously installed. Regardless, our warranty terms apply.” Any statements regarding IBM's future direction, intent or product plans are subject to change or withdrawal without notice. Performance data contained herein was generally obtained in a controlled, isolated environments. Customer examples are presented as illustrations of how those customers have used IBM products and the results they may have achieved. Actual performance, cost, savings or other results in other operating environments may vary. References in this document to IBM products, programs, or services does not imply that IBM intends to make such products, programs or services available in all countries in which IBM operates or does business. Workshops, sessions and associated materials may have been prepared by independent session speakers, and do not necessarily reflect the views of IBM. All materials and discussions are provided for informational purposes only, and are neither intended to, nor shall constitute legal or other guidance or advice to any individual participant or their specific situation. It is the customer’s responsibility to insure its own compliance with legal requirements and to obtain advice of competent legal counsel as to the identification and interpretation of any relevant laws and regulatory requirements that may affect the customer’s business and any actions the customer may need to take to comply with such laws. IBM does not provide legal advice or represent or warrant that its services or products will ensure that the customer is in compliance with any law.
  • 49.
    48 3/21/17 Notices anddisclaimers continued Information concerning non-IBM products was obtained from the suppliers of those products, their published announcements or other publicly available sources. IBM has not tested those products in connection with this publication and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products. IBM does not warrant the quality of any third-party products, or the ability of any such third-party products to interoperate with IBM’s products. IBM expressly disclaims all warranties, expressed or implied, including but not limited to, the implied warranties of merchantability and fitness for a particular, purpose. The provision of the information contained herein is not intended to, and does not, grant any right or license under any IBM patents, copyrights, trademarks or other intellectual property right. IBM, the IBM logo, ibm.com, Aspera®, Bluemix, Blueworks Live, CICS, Clearcase, Cognos®, DOORS®, Emptoris®, Enterprise Document Management System™, FASP®, FileNet®, Global Business Services®, Global Technology Services®, IBM ExperienceOne™, IBM SmartCloud®, IBM Social Business®, Information on Demand, ILOG, Maximo®, MQIntegrator®, MQSeries®, Netcool®, OMEGAMON, OpenPower, PureAnalytics™, PureApplication®, pureCluster™, PureCoverage®, PureData®, PureExperience®, PureFlex®, pureQuery®, pureScale®, PureSystems®, QRadar®, Rational®, Rhapsody®, Smarter Commerce®, SoDA, SPSS, Sterling Commerce®, StoredIQ, Tealeaf®, Tivoli® Trusteer®, Unica®, urban{code}®, Watson, WebSphere®, Worklight®, X-Force® and System z® Z/OS, are trademarks of International Business Machines Corporation, registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at "Copyright and trademark information" at: www.ibm.com/legal/copytrade.shtml.
  • 50.