I am new to NanoHTTPD server and Maven. I'm starting a maven project using NanoHTTPD server and im trying to test the HelloServer (set to port 8081 in HelloServer class' super call). I run the app and a NetBeans like window opens, i guess it is the server running, i haven't given it any brandings yet.
But how do i test that it is serving properly?
In tomcat or apache i could just go to the url on that port http://localhost:8080/
and the server will serve me an error or welcome page.
I try going to http://localhost:8081
in a browser but all i get is the browser couldnt connect error, no confirmation of anything served..
I feel like im really dumb right now.
Im not 100% confident i have set the project up properly, i imported the class files as i wasn't sure how to import it as a module, and i put parent tags in the pom file for the NanoHTTPD pointing to my parent app but i guess its not actually using that, anyhow it builds and compiles and runs, but how do i confirm it is serving..?
i notice these errors in output log:
specifically i notice context errors before/after it turns on modules:
java[7741] <Error>: CGContextGetCTM: invalid context 0x0
java[7741] <Error>: CGContextSetBaseCTM: invalid context 0x0
java[7741] <Error>: CGContextGetCTM: invalid context 0x0
java[7741] <Error>: CGContextSetBaseCTM: invalid context 0x0
java[7741] <Error>: CGContextGetCTM: invalid context 0x0
java[7741] <Error>: CGContextSetBaseCTM: invalid context 0x0
`
update: context errors are fixed by updating to Mountain Lion. Apparently they are caused by Mac's version of Java prior to Mt.Lion.