You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2022/08/08 02:02:01 UTC

[GitHub] [dolphinscheduler] hiSandog commented on a diff in pull request #11330: [Feature][Python] Combine gateway.entry_point call in python api side

hiSandog commented on code in PR #11330:
URL: https://github.com/apache/dolphinscheduler/pull/11330#discussion_r939767055


##########
dolphinscheduler-python/pydolphinscheduler/src/pydolphinscheduler/models/queue.py:
##########
@@ -33,10 +32,3 @@ def __init__(
         description: Optional[str] = "",
     ):
         super().__init__(name, description)
-
-    def create_if_not_exists(self, user=configuration.USER_NAME) -> None:
-        """Create Queue if not exists."""
-        gateway = launch_gateway()
-        # Here we set Queue.name and Queue.queueName same as self.name
-        result = gateway.entry_point.createProject(user, self.name, self.name)
-        gateway_result_checker(result, None)

Review Comment:
   Because I didn't find the createProject method in the [PythonGateway.java ](https://github.com/apache/dolphinscheduler/blob/dev/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/python/PythonGateway.java).
   
   And the [Queue](https://github.com/apache/dolphinscheduler/blob/dev/dolphinscheduler-python/pydolphinscheduler/src/pydolphinscheduler/models/queue.py) class doesn't seem to be in use .
   
   So I deleted that code



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

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