jeff-901 commented on a change in pull request #800:
URL: https://github.com/apache/submarine/pull/800#discussion_r749028433



##########
File path: 
submarine-serve/src/main/java/org/apache/submarine/serve/utils/SeldonConstants.java
##########
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.submarine.serve.utils;
+
+public class SeldonConstants {
+  public static final String API_VERSION = "machinelearning.seldon.io/v1";
+
+  public static final String KIND = "SeldonDeployment";
+
+  public static final String GROUP = "machinelearning.seldon.io";
+
+  public static final String VERSION = "v1";
+
+  public static final String PLURAL = "seldondeployments";
+
+  public static final String STORAGE_INITIALIZER_IMAGE = 
"seldonio/rclone-storage-initializer:1.10.0";
+
+  public static final String ENV_SECRET_REF_NAME = 
"seldon-init-container-secret";

Review comment:
       The default ENV_SECRET_REF_NAME should be "submarine-serve-secret".

##########
File path: 
submarine-serve/src/main/java/org/apache/submarine/serve/tensorflow/SeldonTFServing.java
##########
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.submarine.serve.tensorflow;
+
+import io.kubernetes.client.models.V1ObjectMeta;
+import org.apache.submarine.serve.seldon.SeldonDeployment;
+import org.apache.submarine.serve.seldon.SeldonGraph;
+import org.apache.submarine.serve.seldon.SeldonPredictor;
+import org.apache.submarine.serve.utils.SeldonConstants;
+
+public class SeldonTFServing extends SeldonDeployment {
+  public SeldonTFServing(String name, String modelURI){
+    V1ObjectMeta v1ObjectMeta = new V1ObjectMeta();
+    v1ObjectMeta.setName(name);
+    v1ObjectMeta.setNamespace(SeldonConstants.DEFAULT_NAMESPACE);
+    setMetadata(v1ObjectMeta);
+
+    setSpec(new SeldonDeploymentSpec(SeldonConstants.SELDON_PROTOCOL));
+
+    SeldonGraph seldonGraph = new SeldonGraph();
+    seldonGraph.setName(name);
+    seldonGraph.setImplementation(SeldonConstants.TFSERVING_IMPLEMENTATION);

Review comment:
       Do we need to help the user to setup envSecretRefName?

##########
File path: 
submarine-serve/src/test/java/org/apache/submarine/serve/tensorflow/SeldonTFServingTest.java
##########
@@ -0,0 +1,70 @@
+// /*
+//  * Licensed to the Apache Software Foundation (ASF) under one
+//  * or more contributor license agreements.  See the NOTICE file
+//  * distributed with this work for additional information
+//  * regarding copyright ownership.  The ASF licenses this file
+//  * to you under the Apache License, Version 2.0 (the
+//  * "License"); you may not use this file except in compliance
+//  * with the License.  You may obtain a copy of the License at
+//  *
+//  *   http://www.apache.org/licenses/LICENSE-2.0

Review comment:
       Why do you comment all the lines in the file?




-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to