File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -102,20 +102,20 @@ jobs:
102102 OPENSEARCH_VERSION : ${{ steps.get_opensearch_version.outputs.version }}
103103 run : npm ci && npm run preprocessing -- --opensearch-version "$OPENSEARCH_VERSION"
104104
105- - name : Clone Protobuf Generator Repository
106- run : |
107- git clone https://github.com/OpenAPITools/openapi-generator cloned-repo
108- cd cloned-repo
109- git checkout 6699ecd9d2f4e0868f23bb36566ea03cd1230e6a
110-
111- - name : Build Protobuf Generator Tool
105+ - name : Convert protobuf
112106 run : |
113- cd cloned-repo
114- ./mvnw clean package
107+ java -jar tools/bin/openapi-generator-cli.jar generate -c tools/proto-convert/src/config/protobuf-generator-config.yaml
115108
116- - name : Convert protobuf
109+ - name : Check for auto-pr-branch and use its protos if exists
117110 run : |
118- java -jar cloned-repo/modules/openapi-generator-cli/target/openapi-generator-cli.jar generate -c tools/proto-convert/src/config/protobuf-generator-config.yaml
111+ # Check if auto-pr-branch exists
112+ if git ls-remote --exit-code --heads origin auto-pr-branch > /dev/null 2>&1; then
113+ echo "Found auto-pr-branch, using its proto files for comparison"
114+ git fetch origin auto-pr-branch
115+ git checkout origin/auto-pr-branch -- protos/schemas/
116+ else
117+ echo "auto-pr-branch not found, using main branch proto files"
118+ fi
119119
120120 - name : Check for auto-pr-branch and use its protos if exists
121121 run : |
Original file line number Diff line number Diff line change 1313jobs :
1414 auto-proto-convert :
1515 runs-on : ubuntu-latest
16- if : github.repository == 'opensearch-project/opensearch-protobufs'
16+ # if: github.repository == 'opensearch-project/opensearch-protobufs'
1717 steps :
1818 - name : Checkout Repository
1919 uses : actions/checkout@v4
@@ -104,20 +104,9 @@ jobs:
104104 OPENSEARCH_VERSION : ${{ steps.get_opensearch_version.outputs.version }}
105105 run : npm ci && npm run preprocessing -- --opensearch-version "$OPENSEARCH_VERSION"
106106
107- - name : Clone Protobuf Generator Repository
108- run : |
109- git clone https://github.com/OpenAPITools/openapi-generator cloned-repo
110- cd cloned-repo
111- git checkout 6699ecd9d2f4e0868f23bb36566ea03cd1230e6a
112-
113- - name : Build Protobuf Generator Tool
114- run : |
115- cd cloned-repo
116- ./mvnw clean package
117-
118107 - name : Convert protobuf
119108 run : |
120- java -jar cloned-repo/modules/openapi-generator-cli/target /openapi-generator-cli.jar generate -c tools/proto-convert/src/config/protobuf-generator-config.yaml
109+ java -jar tools/bin /openapi-generator-cli.jar generate -c tools/proto-convert/src/config/protobuf-generator-config.yaml
121110
122111 - name : Post Process Protobuf
123112 id : merge_report
Original file line number Diff line number Diff line change @@ -588,10 +588,6 @@ export class SchemaModifier {
588588 const prop = schema . properties [ propName ] as any ;
589589 if ( prop && typeof prop === 'object' ) {
590590 prop [ 'x-oneof-property' ] = true ;
591-
592- if ( '$ref' in prop ) {
593- this . markReferencedSchemaAsOneof ( prop . $ref ) ;
594- }
595591 }
596592 }
597593 }
You can’t perform that action at this time.
0 commit comments