Java 8 geared up to cloud and its feature

Java SE 8 is geared up to the cloud. Multi-tenancy and modularity is featured.

Multi-tenancy is considered as one of the main components characteristics of cloud computing, as single instance of software application runs on the server but served multiple clients.

Modularity is reorganization of JDK into a set of clearly defined though interdependent modules.

Java 8 also decides to include C# / Scala’s Lambda style which worked pretty well in subjective measure. Java 7 should have Lambda but its construct is weird.

JSR TBD is included as language support for collections, where literal expressions for immutable lists, sets, and maps, and indexing-access syntax for lists and maps.

Below codes are possible when define a Set or List.

List<Integer> aListOfNumber = [1,2,3,4,7,2,4,6,7];

Set<Integer> aSetOfNumber = {1,5,34,45645,23};

Map<Integer, String> aHashMap = {5 : “fyhao”, 6 : “bmwjob”, 18 : “Singapore”};

Virtual extension method is included as providing default implementation for interface virtual methods. If you are not afford an implementation of method, one will providing you an implementation with no charge.

Sharing state often introduce complexity in concurrency programming. If the state is not shared, or said immutable state, it will not brought trouble because it has fixed input-output pair. Functional language comes with this benefit, but Java is not going to switch language but just adopt the principle functional language based on, seek to increase immutability and decrease sharing. Fork-join decomposition introduced in Java SE 7 to easily write algorithm that parallelized automatically across wide range of hardware configurations.

Author: fyhao

Jebsen & Jessen Comms Singapore INTI University College Bsc (Hon) of Computer Science, Coventry University

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.