Simple Application using JNDI and DataSource without Server, ServiceUnavailableException, ConnectException
问题 I'm reading about JNDI and DataSource. https://www.journaldev.com/2509/java-datasource-jdbc-datasource-example https://www.journaldev.com/2513/tomcat-datasource-jndi-example-java https://www.baeldung.com/jndi Does it make sense to use JNDI without a server, e.g. Tomcat, JBoss, WAS? Is there some simple, standalone application that uses JNDI? I would like an example using both without a server. import java.rmi.Remote; import java.rmi.RemoteException; import java.rmi.registry.LocateRegistry;