chrisdutz commented on code in PR #747:
URL: https://github.com/apache/plc4x/pull/747#discussion_r1072191526


##########
plc4j/api/src/main/java/org/apache/plc4x/java/api/PlcDriverManager.java:
##########
@@ -16,17 +16,25 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.plc4x.java.utils.connectionpool2;
+package org.apache.plc4x.java.api;
 
-import org.apache.plc4x.java.api.PlcConnection;
+import org.apache.plc4x.java.DefaultPlcDriverManager;
 import org.apache.plc4x.java.api.exceptions.PlcConnectionException;
 
-/**
- * Simple Factory Method which creates a new PlcConnection
- */
-@FunctionalInterface
-public interface PlcConnectionFactory {
+import java.util.Set;
+
+public interface PlcDriverManager {
+
+    static PlcDriverManager getDefault() {
+        return new DefaultPlcDriverManager();
+    }
+
+    Set<String> listDrivers();
+
+    PlcDriver getDriver(String protocolCode) throws PlcConnectionException;
+
+    PlcDriver getDriverForUrl(String url) throws PlcConnectionException;
 
-    PlcConnection create() throws PlcConnectionException;

Review Comment:
   Let's agree on not calling them "customers" as they are missing one 
important aspect of a typical customer relation.
   I would say that "customers" have the chance to come forward and announce 
this would break things for them. I would consider it important to have 
backward compatibility once we are at 1.0.0. But I wouldn't object your 
proposal. Feel free to add it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to