The type java.io.ObjectInputStream cannot be resolved. It is indirectly referenced from required .class files

Something happened in Java 8 Update 91 that broke existing JSP code. That seems pretty clear. Here is a sample of similar questions and bug reports: Unable to compile JSP file with JDK1.8.0_92 Spring MVC – Unable to compile class for JSP Unable to access CloudPlatform Client https://bugs.openjdk.java.net/browse/JDK-8155588 (closed as “not an issue”) https://bugs.openjdk.java.net/browse/JDK-8155223 (closed … Read more

Appending to an ObjectOutputStream

Here’s the trick: subclass ObjectOutputStream and override the writeStreamHeader method: public class AppendingObjectOutputStream extends ObjectOutputStream { public AppendingObjectOutputStream(OutputStream out) throws IOException { super(out); } @Override protected void writeStreamHeader() throws IOException { // do not write a header, but reset: // this line added after another question // showed a problem with the original reset(); } … Read more