You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "jayeshchoudhary (via GitHub)" <gi...@apache.org> on 2023/09/15 15:03:21 UTC
[GitHub] [pinot] jayeshchoudhary opened a new pull request, #11602: UI fix schema add
jayeshchoudhary opened a new pull request, #11602:
URL: https://github.com/apache/pinot/pull/11602
`ui` `bugfix`
## Issue
- The issue is that UI is passing wrong data in the request header
```
Content-Type: text/plain;charset=UTF-8
```
Whereas Backend API expects application/json
```
@POST
@Produces(MediaType.APPLICATION_JSON)
@Consumes(MediaType.APPLICATION_JSON)
@Path("/schemas/validate")
```

## Solution
- The issue occurred because UI is sending a stringify version of the request object, so contentType: text gets auto-added. Sending the data as json object solves the issue.
--
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@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
[GitHub] [pinot] xiangfu0 commented on a diff in pull request #11602: Schema add UI: fix passing wrong data in the request header
Posted by "xiangfu0 (via GitHub)" <gi...@apache.org>.
xiangfu0 commented on code in PR #11602:
URL: https://github.com/apache/pinot/pull/11602#discussion_r1327764780
##########
pinot-controller/src/main/resources/app/requests/index.ts:
##########
@@ -229,13 +229,13 @@ export const rebalanceBrokersForTable = (tableName: string): Promise<AxiosRespon
baseApi.post(`/tables/${tableName}/rebuildBrokerResourceFromHelixTags`, null, {headers});
export const validateSchema = (schemaObject: string): Promise<AxiosResponse<OperationResponse>> =>
- baseApi.post(`/schemas/validate`, JSON.stringify(schemaObject), {headers});
+ baseApi.post(`/schemas/validate`, schemaObject, {headers});
export const validateTable = (tableObject: string): Promise<AxiosResponse<OperationResponse>> =>
baseApi.post(`/tables/validate`, JSON.stringify(tableObject), {headers});
Review Comment:
does it apply to `/tables` API as well?
--
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@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
[GitHub] [pinot] codecov-commenter commented on pull request #11602: Schema add UI: fix passing wrong data in the request header
Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #11602:
URL: https://github.com/apache/pinot/pull/11602#issuecomment-1721533849
## [Codecov](https://app.codecov.io/gh/apache/pinot/pull/11602?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
> Merging [#11602](https://app.codecov.io/gh/apache/pinot/pull/11602?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) (5ff0234) into [master](https://app.codecov.io/gh/apache/pinot/commit/4292356500870d960f016267660392550879c28d?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) (4292356) will **increase** coverage by `0.12%`.
> The diff coverage is `n/a`.
```diff
@@ Coverage Diff @@
## master #11602 +/- ##
============================================
+ Coverage 62.92% 63.04% +0.12%
- Complexity 1103 1106 +3
============================================
Files 2326 2326
Lines 124984 124984
Branches 19080 19080
============================================
+ Hits 78641 78795 +154
+ Misses 40730 40578 -152
+ Partials 5613 5611 -2
```
| [Flag](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
|---|---|---|
| [integration](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `<0.01% <ø> (ø)` | |
| [integration1](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `<0.01% <ø> (ø)` | |
| [integration2](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `0.00% <ø> (ø)` | |
| [java-11](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `63.02% <ø> (+48.51%)` | :arrow_up: |
| [java-17](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `62.91% <ø> (+48.41%)` | :arrow_up: |
| [java-20](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `62.91% <ø> (+<0.01%)` | :arrow_up: |
| [temurin](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `63.04% <ø> (+0.12%)` | :arrow_up: |
| [unittests](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `63.03% <ø> (+0.12%)` | :arrow_up: |
| [unittests1](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `67.44% <ø> (+0.17%)` | :arrow_up: |
| [unittests2](https://app.codecov.io/gh/apache/pinot/pull/11602/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `14.50% <ø> (-0.01%)` | :arrow_down: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
[see 25 files with indirect coverage changes](https://app.codecov.io/gh/apache/pinot/pull/11602/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
:mega: We’re building smart automated test selection to slash your CI/CD build times. [Learn more](https://about.codecov.io/iterative-testing/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
--
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@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
[GitHub] [pinot] xiangfu0 merged pull request #11602: Schema add UI: fix passing wrong data in the request header
Posted by "xiangfu0 (via GitHub)" <gi...@apache.org>.
xiangfu0 merged PR #11602:
URL: https://github.com/apache/pinot/pull/11602
--
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@pinot.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org