Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Well-Written Java 8, 8 Ways

DZone's Guide to

Well-Written Java 8, 8 Ways

Continuing the Java discussion backing it up with facts, tools and answers. Link this to the other Java comment explosions.

· Java Zone
Free Resource

Bitbucket is for the code that takes us to Mars, decodes the human genome, or drives your next car. What will your code do? Get started with Bitbucket today, it's free.

You can do itWrite Better Code.

It's hard, but there are tools, techniques, and tool kits to help.

I love Scala, Case Classes (okay the 22 field thing is an issue, especially when I want to model Twitter JSON) and val. That alone made it so much cleaner to write then Java. Write Scala code.   Think Functionally. Use what you learn and like in Scala in Java.

Say you are at a large enterprise, they can't get off Java that easy. Hundreds of Java developers can't all be functional programmers writing Scala.

You can make Java 8 really strong.

  1. Follow the Right Guidelines (12 Factor Apps, Reactive Programming, SOLID, TDD, AntiFragile, microservices)

  2. Use the Right Infrastructure (Containers/Docker, CloudFoundry/PaaS, Mesos, YARN, NoSQL, Hadoop, Geode, Redis)

  3. Use the Right Frameworks (Lagom, Spring Boot, Play, DropWizard, JHipster)

  4. Use the Right Tools (IntelliJ, Gradle, SBT). Never create a singleton, toString method or JavaBean set/get from scratch.

  5. Use the Right Libraries and Accelerators (ImmutablesGoogle AutoCyclops-React, RetroFit, Spring Cloud Netflix, Guava, Project Lombok, Project Reactor, Chronicle Maps, LMAX Disruptor, Vertx)

  6. Use the Functional Force (Java 8 Lambdas, Javaslang)

  7. Use Java 8 for Big Data (Spark, Flink, Kakfa, Akka)

  8. Use Java for Non-JEE Internal Apps (IoT, Android, Big Data, Deep Learning)

Remember, a few companies might still be using a little Java: Google, AOL, ebay, Square,... You may find a few repositories for Java here.

Oh and unlike, say, Perl, Java isn't afraid to do some serious upgrades and changes like adding cool things from other languages and just fixing stuff.

Bitbucket is the Git solution for professional teams who code with a purpose, not just as a hobby. Get started today, it's free.

Topics:
java ,java 8 ,java 8 functional programming ,jvm

Opinions expressed by DZone contributors are their own.

The best of DZone straight to your inbox.

SEE AN EXAMPLE
Please provide a valid email address.

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.
Subscribe

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}