In this presentation I will go through latest features being added in Spring 3.1/3.2 one more time and also will try to look behind the scene on what new features are comming in Spring 4 which should be released at the end of this year.
Spring Framework 4.0 - The Next Generation - Soft-Shake 2013Sam Brannen
Spring Framework 4.0 is the next generation of the popular open source framework for Enterprise Java developers, focusing on the future with support for Java SE 8 and Java EE 7. In this presentation core Spring committer Sam Brannen will provide attendees an overview of the new enterprise features in the framework as well as new programming models made possible with the adoption of JDK 8 language features and APIs.
Specifically, this talk will cover support for lambda expressions and method references against Spring callback interfaces, JSR-310 Date-Time value types for Spring data binding and formatting, Spring's new @Conditional mechanism for activation of bean definitions, and a new WebSocket endpoint model. Regarding enterprise APIs, the presentation will cover Spring 4.0's new support for JMS 2.0, JPA 2.1, Bean Validation 1.1, Servlet 3.1, JCache, and JSR-236 concurrency. Last but not least, Sam will discuss improvements to Spring's testing support and point out which deprecated APIs have been pruned from the framework.
The Web and Spring MVC continue to be one of the most active areas of the
Spring Framework with each new release adding plenty of features and refinements
requested by the community. Furthermore version 4 added a significant choice
for web applications to build WebSocket-style architectures.
This talk provides an overview of the areas in which the framework has evolved
along with highlights of specific noteworthy features from the most recent
releases.
Introduction to the Spring Framework:
Generar description
IoC container
Dependency Injection
Beans scope and lifecycle
Autowiring
XML and annotation based configuration
Additional features
In this presentation I will go through latest features being added in Spring 3.1/3.2 one more time and also will try to look behind the scene on what new features are comming in Spring 4 which should be released at the end of this year.
Spring Framework 4.0 - The Next Generation - Soft-Shake 2013Sam Brannen
Spring Framework 4.0 is the next generation of the popular open source framework for Enterprise Java developers, focusing on the future with support for Java SE 8 and Java EE 7. In this presentation core Spring committer Sam Brannen will provide attendees an overview of the new enterprise features in the framework as well as new programming models made possible with the adoption of JDK 8 language features and APIs.
Specifically, this talk will cover support for lambda expressions and method references against Spring callback interfaces, JSR-310 Date-Time value types for Spring data binding and formatting, Spring's new @Conditional mechanism for activation of bean definitions, and a new WebSocket endpoint model. Regarding enterprise APIs, the presentation will cover Spring 4.0's new support for JMS 2.0, JPA 2.1, Bean Validation 1.1, Servlet 3.1, JCache, and JSR-236 concurrency. Last but not least, Sam will discuss improvements to Spring's testing support and point out which deprecated APIs have been pruned from the framework.
The Web and Spring MVC continue to be one of the most active areas of the
Spring Framework with each new release adding plenty of features and refinements
requested by the community. Furthermore version 4 added a significant choice
for web applications to build WebSocket-style architectures.
This talk provides an overview of the areas in which the framework has evolved
along with highlights of specific noteworthy features from the most recent
releases.
Introduction to the Spring Framework:
Generar description
IoC container
Dependency Injection
Beans scope and lifecycle
Autowiring
XML and annotation based configuration
Additional features
Spring Framework 4.0 is the latest generation of the popular open source framework for Enterprise Java developers, focusing on the future with support for Java SE 8 and Java EE 7. In this presentation core Spring committer Sam Brannen will provide attendees an overview of the new enterprise features in the framework as well as new programming models made possible with the adoption of JDK 8 language features and APIs.
Specifically, this talk will cover support for lambda expressions and method references against Spring callback interfaces, JSR-310 Date-Time value types for Spring data binding and formatting, Spring's new @Conditional mechanism for activation of bean definitions, and a new WebSocket endpoint model. The presentation also provides an overview of Spring 4.0's updated support for enterprise APIs such as JMS 2.0, JPA 2.1, Bean Validation 1.1, Servlet 3.1, and JCache. Last but not least, Sam will highlight some of the major themes for the upcoming Spring Framework 4.1 release such as support for JCache 1.0 annotations, annotation-driven JMS listeners, and testing improvements.
This presentation is about Spring MVC. Topics covered in this session are:
1. HTTP Servlet
2. What is Spring MVC?
3. MVC Architecture
4. Request Processing Workflow in Spring MVC
5. Spring Web Application Context
6. Spring MVC Configuration
7. Important Annotations
Introduction
Framework Modules
Spring Dependencies
Dependency Injection
The IoC Container
Spring IoC Container and Beans
XML-based Configuration Metadata
XML-based Beans
Instantiation of Beans
Dependency Injection
Bean Scopes
Depends On & Lazy-initialized Beans
Customizing the Nature of a Bean
Using PropertyPlaceholderConfigurer
https://notebookbft.wordpress.com/
Spring framework makes the easy development of JavaEE application.
Spring is a lightweight framework. It can be thought of as a framework of frameworks because it provides support to various frameworks such as Struts, Hibernate, Tapestry, EJB, JSF etc.
Spring framework comprises several modules such as IOC, AOP, DAO, Context, ORM, WEB MVC etc.
Introduction to Spring Framework and Spring IoCFunnelll
An introduction to the building blocks of the Spring framework. The presentation focuses on Spring Inverse of Control Container (IoC) ,how it used in the LinkedIn stack, how it integrates with other frameworks and how it works with your JUnit testing.
Java EE 8 Presentation given at NYC Java SIG on May 4, 2017. This presentation provides the latest information on the forthcoming release of Java EE 8 in June.
Java EE 8 Web Frameworks: A Look at JSF vs MVCJosh Juneau
This session provides an overview of both the JSF and MVC 1.0 frameworks. The frameworks are then compared to each other. Finally, JSF 2.3 upcoming features are previewed.
Leverage Hibernate and Spring Features TogetherEdureka!
As data usage is increasing day by day in all domain applications, the usage and complexity of Database increases exponentially. It is important to have a framework which handles all the life cycle, connections, sessions and transactions of database, henceforth leaving only the business logic for the developers to work with. This is where Hibernate comes in and helps the professionals to concentrate only on business logic instead of database environments.
Spring Framework combines all the industry standard framework approaches (e.g. Struts and Hibernate) into one bundle. Spring provides Dependency Injection, Aspect Oriented Programming and support for unit testing. This gives the developer time to work on main business logic rather than worrying about non-application code.
Spring Framework 4.0 is the latest generation of the popular open source framework for Enterprise Java developers, focusing on the future with support for Java SE 8 and Java EE 7. In this presentation core Spring committer Sam Brannen will provide attendees an overview of the new enterprise features in the framework as well as new programming models made possible with the adoption of JDK 8 language features and APIs.
Specifically, this talk will cover support for lambda expressions and method references against Spring callback interfaces, JSR-310 Date-Time value types for Spring data binding and formatting, Spring's new @Conditional mechanism for activation of bean definitions, and a new WebSocket endpoint model. The presentation also provides an overview of Spring 4.0's updated support for enterprise APIs such as JMS 2.0, JPA 2.1, Bean Validation 1.1, Servlet 3.1, and JCache. Last but not least, Sam will highlight some of the major themes for the upcoming Spring Framework 4.1 release such as support for JCache 1.0 annotations, annotation-driven JMS listeners, and testing improvements.
This presentation is about Spring MVC. Topics covered in this session are:
1. HTTP Servlet
2. What is Spring MVC?
3. MVC Architecture
4. Request Processing Workflow in Spring MVC
5. Spring Web Application Context
6. Spring MVC Configuration
7. Important Annotations
Introduction
Framework Modules
Spring Dependencies
Dependency Injection
The IoC Container
Spring IoC Container and Beans
XML-based Configuration Metadata
XML-based Beans
Instantiation of Beans
Dependency Injection
Bean Scopes
Depends On & Lazy-initialized Beans
Customizing the Nature of a Bean
Using PropertyPlaceholderConfigurer
https://notebookbft.wordpress.com/
Spring framework makes the easy development of JavaEE application.
Spring is a lightweight framework. It can be thought of as a framework of frameworks because it provides support to various frameworks such as Struts, Hibernate, Tapestry, EJB, JSF etc.
Spring framework comprises several modules such as IOC, AOP, DAO, Context, ORM, WEB MVC etc.
Introduction to Spring Framework and Spring IoCFunnelll
An introduction to the building blocks of the Spring framework. The presentation focuses on Spring Inverse of Control Container (IoC) ,how it used in the LinkedIn stack, how it integrates with other frameworks and how it works with your JUnit testing.
Java EE 8 Presentation given at NYC Java SIG on May 4, 2017. This presentation provides the latest information on the forthcoming release of Java EE 8 in June.
Java EE 8 Web Frameworks: A Look at JSF vs MVCJosh Juneau
This session provides an overview of both the JSF and MVC 1.0 frameworks. The frameworks are then compared to each other. Finally, JSF 2.3 upcoming features are previewed.
Leverage Hibernate and Spring Features TogetherEdureka!
As data usage is increasing day by day in all domain applications, the usage and complexity of Database increases exponentially. It is important to have a framework which handles all the life cycle, connections, sessions and transactions of database, henceforth leaving only the business logic for the developers to work with. This is where Hibernate comes in and helps the professionals to concentrate only on business logic instead of database environments.
Spring Framework combines all the industry standard framework approaches (e.g. Struts and Hibernate) into one bundle. Spring provides Dependency Injection, Aspect Oriented Programming and support for unit testing. This gives the developer time to work on main business logic rather than worrying about non-application code.
Keynote from Big Data World Show Singapore, April 2015.
• How is data driving change?
• Where are the opportunities, across industries?
• What is required to gain value from data?
• How can you get started today?
This is a presentation on Spring 3 annotations on a web stack. It includes basic spring annotation details, working with jpa, and the new MVC stuff. The code samples add a lot. I'll try to get them up on github.com.
Spring Web Service, Spring JMS, Eclipse & Maven tutorialsRaghavan Mohan
Organizations are increasingly communicating between disparate
software components in a loosely coupled and often asynchronous manner. These tutorials
will help you understand two of the popular integration technologies Web Services &
messaging (i.e. JMS – Java Messaging Service).
This presentation will guide you through the MVC Pattern and Flex implementation of MVC (Cairgorm and Mate Frameworks)
http://blog.go4flash.com/articles/flex-articles/mvc-pattern-presentation-cairngorm-vs-mate/
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012Sam Brannen
Spring 3.1 introduced several eagerly awaited features including bean definition profiles (a.k.a., environment-specific configuration), enhanced Java-based application and infrastructure configuration (a la XML namespaces), and a new cache abstraction. This session will provide attendees a high-level overview of these major new features plus a quick look at additional enhancements to the framework such as the new c: namespace for constructor arguments, support for Servlet 3.0, improvements to Spring MVC and REST, and Spring's new integration testing support for profiles and configuration classes. In addition, this talk will introduce new features under development in the Spring 3.2 roadmap.
Java 9 is just around the corner, and yet many of us developers have yet to use Java 8 features in an application. The goal of this presentation is to move beyond slide-sized examples of streams and lambdas, and to show how to build a fully working end-to-end application using just the core libraries available in the latest version of Java.
In this session, Trisha will build a Java 8 application live. This application will consume a real-time feed of high velocity data, contain services that make sense of the data, and present it in a JavaFX dashboard. Along the way, we’ll encounter Java 8 streams, lambdas, new ways of working with collections, and probably bump into the new date and time API.
Overview of Java EE 6 by Roberto Chinnici at SFJUGMarakana Inc.
Roberto Chinnici, Java EE 6 spec lead, gives an overview of Java EE 6 for San Francisco Java User Group on August 10th, 2010.
http://www.sfjava.org/calendar/13940755/
Building the simplest non-trivial application I could think of, using Java 8 (lambdas, streams, tiny bit of new date & time), with a JavaFX UI and websockets for communication.
More details here:
http://trishagee.github.io/presentation/java8_in_anger/
Testing Spring MVC and REST Web ApplicationsSam Brannen
The Spring Team has innovated extensively around testing in the past, and this innovation continues today. One of the most exciting recent additions to Spring's testing support is Spring MVC Test. What makes it so interesting is the comprehensive support for testing web applications and context hierarchies with the Spring TestContext Framework as well as comprehensive support for out-of-container Spring MVC and REST integration testing.
Join core Spring Framework committer Sam Brannen to see these new Spring Web testing features in action and learn how to speed up your development-test lifecycle.
Spring Day | Spring 3.1 in a Nutshell | Sam BrannenJAX London
2011-10-31 | 11:45 AM - 12:30 PM
Spring 3.1 introduces several eagerly awaited features including bean definition profiles (a.k.a., environment-specific configuration), enhanced Java-based application and infrastructure configuration (a la XML namespaces), and a new cache abstraction. This session will provide attendees with a high-level overview of these major new features, plus a quick look at additional enhancements to the framework such as the new c: namespace for constructor arguments, support for Servlet 3.0, improvements to Spring MVC and REST, and Spring's new integration testing support for profiles and configuration classes.
XRebel is a development-flow-friendly performance tool that enables developers to make performance optimizations during initial development. Find slow methods and HTTP calls, excessive queries, and hidden exceptions within your web application.
Top Reasons Why Java Rocks (report preview) - http:0t.ee/java-rocksZeroTurnaround
In this report we take a look at the top 10 reasons Java is the choice for so many development teams, all around the world, and why you should consider it for your next project. One of the main qualities Java possesses since the early design days is its simplicity. In that spirit we laid out in plain simple terms why Java outperforms other languages when it comes to popularity, performance, its amazing ecosystem and community.
For the less technical, this report explains the value Java brings to your projects. For fellow developers, we included some other projects in the Java ecosystem that you might want to look at. Check them out, have a play with them. It will make you a better developer.
Continue to the full report on RebelLabs: http:0t.ee/java-rocks
Java Tools and Technologies Landscape for 2014 (image gallery)ZeroTurnaround
**See the full version here: http://zeroturnaround.com/rebellabs/java-tools-and-technologies-landscape-for-2014/
--
In a recent survey, RebelLabs asked 2164 Java professionals about their technology usage in 14 tool categories, and found some interesting trends…
Getting Started with IntelliJ IDEA as an Eclipse UserZeroTurnaround
**Note: This is a sneak preview of the full report, which you can get on RebelLabs: http://zeroturnaround.com/rebellabs/getting-started-with-intellij-idea-as-an-eclipse-user/
---
My name is Anton, and I’m an IntelliJ IDEA addict. Whew, it feels good to say it out loud. The choice of IDE for developers is one of the most contentious debates in the software game. But why? After all, aren’t all IDEs more or less the same?
Perhaps you are Eclipse users who are interested in trying out IntelliJ IDEA, or perhaps considering the migration. Moving from Eclipse to IDEA can be quite overwhelming. My main purpose in writing this report is to show Eclipse users, specifically, how to get started using IDEA faster and with less headaches.
For the full report, check it out on RebelLabs:
http://zeroturnaround.com/rebellabs/getting-started-with-intellij-idea-as-an-eclipse-user/
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...ZeroTurnaround
For you lazy coders out there, we offer the visual aids for the first 3 chapters of "Java Build Tools: Part 2 - A Decision Maker's Comparison of Maven, Gradle and Ant + Ivy". Here you can find the raw scores given to each tool based on 6 feature categories. **Download the full report to see Chapter 4, mapping the features against different user profiles**
DevOps vs Traditional IT Ops (DevOps Days ignite talk by Oliver White)ZeroTurnaround
This is a 5-min version of RebelLabs IT Ops / DevOps Productivity Report" (http://zeroturnaround.com/rebellabs/rebel-labs-release-it-ops-devops-productivity-report-2013/) presented at DevOps Days in Paris, Austin, Berlin and Silicon Valley by Oliver White (@TheOTown).
Lazy Coder's Visual Guide to RebelLabs' Developer Productivity Report 2013ZeroTurnaround
For a long time, developers have known that the tools we use and the methodologies we practice have an effect on the quality of our software and our ability to delivery releases predictably. However, this is often a gut feeling based on anecdotal evidence with no numbers to support this theory. Wouldn't be cool to see actual numbers on how doing Code Quality analysis, Pairing Up and using tools for VCS and Continuous Integration significantly improve our ability to delivery quality software? Then look no further. RebelLabs' Developer Productivity Report 2013 is here: http://zeroturnaround.com/rebellabs/developer-productivity-report-2013-how-engineering-tools-practices-impact-software-quality-delivery/
The State of Managed Runtimes 2013, by Attila SzegediZeroTurnaround
There’s JVM, and that’s it, right? Well, not exactly. Even within JVM, there’s an increasing support for running all kinds of non-Java languages: we have invokedynamic, but it’s being improved, and new layers of functionality are emerging on top of it, making JVM a better home for all kinds of programming languages. There’s life outside of JVM too. JavaScript seems to be a new assembler-lever compilation target even for C programs (I’ll show some amusing examples of what exactly you can run these days in a browser) , and there are some independent efforts at managed runtimes in various stages of completion that seem promising – PyPy, Topaz, Rubinius, Parrot VM (it’s alive again!). This talk is admittedly a language-runtime-enthusiast’s walk-through the things he finds interesting happening this year. Recorded at GeekOut 2013.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
Neuro-symbolic is not enough, we need neuro-*semantic*Frank van Harmelen
Neuro-symbolic (NeSy) AI is on the rise. However, simply machine learning on just any symbolic structure is not sufficient to really harvest the gains of NeSy. These will only be gained when the symbolic structures have an actual semantics. I give an operational definition of semantics as “predictable inference”.
All of this illustrated with link prediction over knowledge graphs, but the argument is general.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Ramesh Iyer
In today's fast-changing business world, Companies that adapt and embrace new ideas often need help to keep up with the competition. However, fostering a culture of innovation takes much work. It takes vision, leadership and willingness to take risks in the right proportion. Sachin Dev Duggal, co-founder of Builder.ai, has perfected the art of this balance, creating a company culture where creativity and growth are nurtured at each stage.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
2. 22www.springsource.org
Review: Spring 3 Component Model Themes
Powerful annotated component model
• stereotypes, configuration classes, composable annotations
Spring Expression Language
• and its use in value injection
Comprehensive REST support
• and other Spring @MVC additions
Support for async MVC processing
• Spring MVC interacting with Servlet 3.0 async callbacks
Declarative validation and formatting
• integration with JSR-303 Bean Validation
Declarative scheduling
• trigger abstraction, cron support
Declarative caching
4. 44www.springsource.org
A Typical Annotated Component
@Service
public class MyBookAdminService implements BookAdminService {
@Inject
public MyBookAdminService(AccountRepository ar) {
…
}
@Transactional
public BookUpdate updateBook(Addendum addendum) {
…
}
}
5. 55www.springsource.org
Configuration Classes
@Configuration
public class MyBookAdminConfig {
@Bean
public BookAdminService myBookAdminService() {
MyBookAdminService service = new MyBookAdminService();
service.setDataSource(bookAdminDataSource());
return service;
}
@Bean
public DataSource bookAdminDataSource() {
…
}
}
6. 66www.springsource.org
Next Stop: Spring Framework 4.0
First-class support for Java 8 language and API features
• lambda expressions, method references
• JSR-310 Date and Time, etc
A generalized model for conditional bean definitions
• a more flexible and more dynamic variant of bean definition profiles
First-class support for Groovy (in particular: Groovy 2)
• Groovy-based bean definitions (a.k.a. Grails Bean Builder)
• runtime support for regular Spring beans implemented in Groovy
A WebSocket endpoint model along the lines of Spring MVC
• deploying Spring-defined endpoint beans to a WebSocket runtime
7. 77www.springsource.org
Spring 4.0: Upcoming Enterprise Specs
JMS 2.0
• delivery delay, JMS 2.0 createSession variants etc
JTA 1.2
• javax.transaction.Transactional annotation
JPA 2.1
• unsynchronized persistence contexts
Bean Validation 1.1
• method parameter and return value constraints
JSR-236 Concurrency Utilities
• EE-compliant TaskScheduler backend with trigger support
JSR-107 JCache
• standard CacheManager backend, standard caching annotations
8. 88www.springsource.org
Spring and Common Java SE Generations
Spring 2.5 introduced Java 6 support
• JDK 1.4 – JDK 6
Spring 3.0 raised the bar to Java 5+
• JDK 5 – JDK 6
Spring 3.1/3.2: explicit Java 7 support
• JDK 5 – JDK 7
Spring 4.0 introducing explicit Java 8 support now
• JDK 6 – JDK 8
9. 99www.springsource.org
Spring and Common Java EE Generations
Spring 2.5 completed Java EE 5 support
• J2EE 1.3 – Java EE 5
Spring 3.0 introduced Java EE 6 support
• J2EE 1.4 – Java EE 6
Spring 3.1/3.2: strong Servlet 3.0 focus
• J2EE 1.4 (deprecated) – Java EE 6
Spring 4.0 introducing explicit Java EE 7 support now
• Java EE 5 (with JPA 2.0 feature pack) – Java EE 7
10. 1010www.springsource.org
The State of Java 8
Delayed again...
• scheduled for GA in September 2013
• now just Developer Preview in September
• OpenJDK 8 GA as late as March 2014 (!)
IDE support for Java 8 language features
• IntelliJ: available since IDEA 12, released in December 2012
• Eclipse: announced for June 2014 (!)
• Spring Tool Suite: trying to get some Eclipse-based support earlier
Spring Framework 4.0 scheduled for GA in October 2013
• with best-effort Java 8 support on OpenJDK 8 Developer Preview
11. 1111www.springsource.org
JDK 8: Initial Problems
1.8 bytecode level
• as generated by -target 1.8 (the compiler's default)
• not accepted by ASM 4.x (Spring's bytecode parsing library)
• Spring Framework 4.0 M1 comes with patched ASM 4.1 variant
HashMap/HashSet implementation differences
• different hash algorithms in use
• leading to different hash iteration order
• code shouldn't rely on such an order but sometimes accidentally does
Note: Java 8 API features can be used with -target 1.7 as well
• compatible with ASM 4.0, as used in Spring Framework 3.2
12. 1212www.springsource.org
JSR-310 Date-Time
Specialized date and time value types in java.time package
• replacing java.util.Date/Calendar, along the lines of the Joda-Time project
• Spring 4.0: annotation-driven date formatting
public class Customer {
// @DateTimeFormat(iso=ISO.DATE)
private LocalDate birthDate;
@DateTimeFormat(pattern="M/d/yy h:mm")
private LocalDateTime lastContact;
}
13. 1313www.springsource.org
Lambda Conventions
Many common Spring APIs are candidates for lambdas
• through naturally following the lambda interface conventions
• formerly "single abstract method" types, now "functional interfaces"
JdbcTemplate
• RowMapper:
Object mapRow(ResultSet rs, int rowNum) throws SQLException
JmsTemplate
• MessageCreator:
Message createMessage(Session session) throws JMSException
TransactionTemplate, TaskExecutor, etc
14. 1414www.springsource.org
JdbcTemplate jt = new JdbcTemplate(dataSource);
jt.query("SELECT name, age FROM person WHERE dep = ?",
ps -> { ps.setString(1, "Sales"); },
(rs, rowNum) -> new Person(rs.getString(1), rs.getInt(2)));
jt.query("SELECT name, age FROM person WHERE dep = ?",
ps -> {
ps.setString(1, "test");
},
(rs, rowNum) -> {
return new Person(rs.getString(1), rs.getInt(2));
});
Java 8 Lambdas with Spring's JdbcTemplate
15. 1515www.springsource.org
public List<Person> getPersonList(String department) {
JdbcTemplate jt = new JdbcTemplate(this.dataSource);
return jt.query(
"SELECT name, age FROM person WHERE dep = ?",
ps -> {
ps.setString(1, "test");
},
this::mapPerson;
}
private Person mapPerson(ResultSet rs, int rowNum)
throws SQLException {
return new Person(rs.getString(1), rs.getInt(2));
}
Java 8 Method References with Spring's JdbcTemplate
16. 1616www.springsource.org
The State of Java 8, Revisited
Current OpenJDK 8 builds work quite well for our purposes
• JSR-310's java.time package is near completion
• lambdas and method references work great
• currently using b88 (due to AspectJ compiler problems with b89+)
IntelliJ IDEA 12 is quite advanced in terms of Java 8 support
• can replace anonymous inner class with lambda if possible
• can auto-complete method reference
• works fine with any recent OpenJDK 8 build
No support for 1.8 bytecode in Gradle's test class detection yet
• Gradle is using an unpatched version of ASM 4.0
17. 1717www.springsource.org
Spring Framework 4.0 M1: May 2013
General pruning and dependency upgrades
• JDK 6+, JPA 2.0+, ASM 4.1, etc
Initial Java 8 support based on OpenJDK 8 M7
• including JSR-310 Date-Time and lambda support
Enterprise specs (EE 7 level)
• JMS 2.0, JTA 1.2, JPA 2.1, Bean Validation 1.1, JSR-236 Concurrency
First prototype of conditional bean definitions
Initial WebSocket endpoint programming model
18. 1818www.springsource.org
Spring Framework 4.0 M2: July 2013
Initial Groovy support story
• Groovy-based bean definitions, some AOP refinements
Up-to-date Java 8 support based on feature-complete OpenJDK 8
• including latest lambda compiler and lambda-based stream APIs
Enterprise specs (EE 7 level)
• support for the final API releases (following the EE 7 release in June)
Second iteration of conditional bean definitions
Annotation-based message endpoint model (-> WebSocket)