Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Upgrade OpenAPI to R17 #117

Open
wants to merge 19 commits into
base: next
Choose a base branch
from
Open

feat: Upgrade OpenAPI to R17 #117

wants to merge 19 commits into from

Conversation

pf-lin
Copy link
Contributor

@pf-lin pf-lin commented Aug 12, 2024

No description provided.

@ianchen0119
Copy link
Contributor

ianchen0119 commented Aug 14, 2024

Hi @pf-lin ,

image

Please note that the content type of the response will be "multipart/related" if and only if the message has binary body part(s). Otherwise, the content type should be "application/json".

@ianchen0119
Copy link
Contributor

Also,
I found the schema of the errBody doesn't have the multipart tags.

This issue has already been fixed, please refer to the last two commits in openapi PR:
image

@andy89923 andy89923 self-assigned this Aug 15, 2024
internal/util/search_nf_service.go Outdated Show resolved Hide resolved
internal/sbi/processor/pdu_session.go Outdated Show resolved Hide resolved
Copy link

@a3828162 a3828162 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@pf-lin pf-lin marked this pull request as ready for review September 8, 2024 16:57
Copy link

@TYuan0816 TYuan0816 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

go.mod Outdated Show resolved Hide resolved
internal/context/sm_context.go Outdated Show resolved Hide resolved
internal/context/sm_context.go Outdated Show resolved Hide resolved
internal/sbi/consumer/amf_service.go Outdated Show resolved Hide resolved
internal/sbi/consumer/pcf_service.go Outdated Show resolved Hide resolved
internal/sbi/consumer/smf_service.go Outdated Show resolved Hide resolved
internal/sbi/processor/association.go Show resolved Hide resolved
internal/sbi/processor/datapath.go Show resolved Hide resolved
internal/sbi/processor/datapath.go Show resolved Hide resolved
@ianchen0119 ianchen0119 changed the base branch from main to next November 12, 2024 06:35
Comment on lines +142 to +158
postChargingDataRequest := &ConvergedCharging.PostChargingDataRequest{
ChfConvergedChargingChargingDataRequest: req,
}
rspPost, localErr := client.DefaultApi.PostChargingData(ctx, postChargingDataRequest)

switch err := localErr.(type) {
case openapi.GenericOpenAPIError:
switch errModel := err.Model().(type) {
case ConvergedCharging.PostChargingDataError:
chargingDataRef := strings.Split(errModel.Location, "/")
smContext.ChargingDataRef = chargingDataRef[len(chargingDataRef)-1]
return nil, &errModel.ProblemDetails, nil
case error:
return nil, openapi.ProblemDetailsSystemFailure(errModel.Error()), nil
default:
return nil, nil, openapi.ReportError("openapi error")
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The logic is not correct.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants