Using DocRead:
examples.util.ServletException: java.lang.NullPointerException: Object reference not set to an instance of an object.View.viewWithViewingServer() Exception: examples.util.ServletException: java.lang.NullPointerException: Object reference not set to an instance of an object. View.viewWithDocRead() Exception: examples.util.ServletException: Could not view the document through the DocRead object. Possible Cause: java.lang.RuntimeException: ------ java.lang.RuntimeException: ServerSpec not set. Set via API, or set the VERITY_K2_HOSTPORT Java property or environment variable. at com.verity.search.util.JSDispenser.getConnResource(String serverSpec, String encryptionKey) at com.verity.search.DocRead.getDoc(Boolean fetchFeatureVector) at com.verity.search.DocRead.getDoc() at com.verity.search.DocRead.docViewIntern(String streamName, String beginHL, String endHL) ------ class java.lang.RuntimeException------ java.lang.RuntimeException: ServerSpec not set. Set via API, or set the VERITY_K2_HOSTPORT Java property or environment variable. at com.verity.search.util.JSDispenser.getConnResource(String serverSpec, String encryptionKey) at com.verity.search.DocRead.getDoc(Boolean fetchFeatureVector) at com.verity.search.DocRead.getDoc() at com.verity.search.DocRead.docViewIntern(String streamName, String beginHL, String endHL) ------ class java.lang.RuntimeException