File tree Expand file tree Collapse file tree 1 file changed +22
-2
lines changed
Expand file tree Collapse file tree 1 file changed +22
-2
lines changed Original file line number Diff line number Diff line change @@ -42,9 +42,29 @@ class ConnectorMetadata(BaseModel):
4242
4343 dockerRepository : str = Field (..., description = "Docker repository for the connector image" )
4444 dockerImageTag : str = Field (..., description = "Docker image tag for the connector" )
45- language : ConnectorLanguage | None = Field (
46- None , description = "Language of the connector implementation"
45+
46+ tags : list [str ] = Field (
47+ default = [],
48+ description = "List of tags for the connector" ,
4749 )
50+
51+ @property
52+ def language (self ) -> ConnectorLanguage :
53+ """Get the connector language."""
54+ for tag in self .tags :
55+ if tag .startswith ("language:" ):
56+ language = tag .split (":" , 1 )[1 ]
57+ if language == "python" :
58+ return ConnectorLanguage .PYTHON
59+ elif language == "java" :
60+ return ConnectorLanguage .JAVA
61+ elif language == "low-code" :
62+ return ConnectorLanguage .LOW_CODE
63+ elif language == "manifest-only" :
64+ return ConnectorLanguage .MANIFEST_ONLY
65+
66+ return ConnectorLanguage .UNKNOWN
67+
4868 connectorBuildOptions : ConnectorBuildOptions | None = Field (
4969 None , description = "Options for building the connector"
5070 )
You can’t perform that action at this time.
0 commit comments