Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Building Realtime Access Data Apps with Speedment (TCF ITPC 2017)

101 views

Published on

A presentation introducing and demonstrating Speedment, an ORM that abstracts the process of database connectivity and querying.

Published in: Software
  • Be the first to comment

  • Be the first to like this

Building Realtime Access Data Apps with Speedment (TCF ITPC 2017)

  1. 1. 1 Building Realtime Data Apps with Speedment TCF IT Professional Conference March 17, 2017 Michael P. Redlich @mpredli about.me/mpredli/
  2. 2. Who’s Mike? • BS in CS from • “Petrochemical Research Organization” • Java Queue News Editor, InfoQ • Ai-Logix, Inc. (now AudioCodes) • Amateur Computer Group of New Jersey 2
  3. 3. Objectives • What is Speedment? • Why Speedment? • Database Support • Get Started Building an Application • Live Demo (yea!) • Speedment Resources 3
  4. 4. What is Speedment (1)? “Speedment accelerates your development speed and makes database programming so easy and fun. When you use Speedment Open Source for database querying, you do not have to learn a new API or use complex ORMs. Everything is standard Java 8 and works out of the box.” Speedment Web Site, http://www.speedment.org/ 4
  5. 5. What is Speedment (2)? • First introduced in June 2015 • A portmanteau of “speed” and “development” • Abstracts the process of: • database connectivity • database operations 5
  6. 6. Speedment Integration 6 “Hello, Java Users Group!”
  7. 7. Speedment 3.0.5 • Codename:“Forest” • Latest features include: • declarative Java 8 stream API for databases operations • improved user interface 7
  8. 8. Why Speedment? • Full Java 8 support • lamdas and streams • Easy query with Smart Streams • no need for coding SQL • No NULL pointer exceptions 8
  9. 9. Speedment Open Source • Speedment Open Source Database Support: • MySQL • PostgreSQL • MariaDB 9
  10. 10. Speedment Enterprise • Speedment Enterprise Database Support includes Open Source plus: • Oracle • DB2 • AS400 • SQL Server 10
  11. 11. Let’s Get Started… 11
  12. 12. Example Database 12 “Hello, Java Users Group!”
  13. 13. Getting Started $ mvn archetype:generate -DgroupId=org.redlich.publications -DartifactId=publications -DarchetypeArtifactId=speedment-archtype-mysql -DarchetypeGroupId=com.speedment.archetypes -DinteractiveMode=false -DarchetypeVersion=3.0.5 && cd publications && mvn speedment:tool 13 generates a new project project package project root invoke the Speedment tool the latest version of Speedment specify desired database
  14. 14. Speedment Tool (1) 14 “Hello, Java Users Group!” specify desired database subpackage (user defined) database name click…
  15. 15. Speedment Tool (2) 15 “Hello, Java Users Group!” click…
  16. 16. Let’s Build That App… 16
  17. 17. 17 /* * initial setup */ protected final PublicationsApplication app; protected final AuthorsManager authorsManager; protected final PublicationsManager publicationsManager; app = new PublicationsApplicationBuilder(); authorsManager = app.getOrThrow(AuthorsManager.class); publicationsManager = app.getOrThrow(PublicationsManager.class); main app manager representing each database table
  18. 18. 18 /* * smart streaming */ publicationsManager.stream() .forEach(System.out::println); publicationsManager.stream() .filter(Publications.TITLE.startsWith(“”); long count = publicationsManager.stream() .count() Optional<Authors> redlich = authorsManager .stream() .filter(Authors.LAST_NAME.equal(“Redlich”)) .findAny();
  19. 19. Partial UML Diagram 19 “Hello, Java Users Group!”
  20. 20. Demo Time… 20
  21. 21. 21 Speedment Resources •speedment.org •javadoc.io/doc/com.speedment/ runtime-deploy/3.0.5 •minborgsjavapot.blogspot.com •https://www.infoq.com/news/ 2016/12/speedment-releases- version-3 Per-Åke Minborg, CTO at Speedment
  22. 22. Upcoming Events (1) • March 17-18, 2017 •tcf-nj.org • April 18-19, 2017 •phillyemergingtech.com 22
  23. 23. Acknowledgements • Speedment, Inc. • Per-Åke Minborg, CTO at Speedment 23
  24. 24. 24 Thanks! mike@redlich.net @mpredli redlich.net slideshare.net/mpredli01 github.com/mpredli01

×