Java 8 – Filter a null value from a Stream

Review a Stream containing null values. Java8Examples.java package com.mkyong.java8; import java.util.List; import java.util.stream.Collectors; import java.util.stream.Stream; public class Java8Examples { public static void main(String[] args) { Stream<String> language = Stream.of("java", "python", "node", null, "ruby", null, "php"); List<String> result = language.collect(Collectors.toList()); result.forEach(System.out::println); } } output java python node null //

Struts 2 on GAE – Error: result ‘null’ not found

Problem Developing Struts2 on Google App Engine, in following environment. Struts 2.3.1.2 JDK 1.6 Eclipse 3.7 + Google Plugin for Eclipse Google App Engine Java SDK 1.6.3.1 Just started a simple Struts2 hello world example, when access the action class, hit error “Error: result ‘null’ not found”, in both local development and real production GAE …

Read more