Skip to content

remove superfluous parameters at the mapping stage #327

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

Closed
richard-melvin opened this issue Mar 17, 2025 · 6 comments
Closed

remove superfluous parameters at the mapping stage #327

richard-melvin opened this issue Mar 17, 2025 · 6 comments
Milestone

Comments

@richard-melvin
Copy link

The mapping.yaml file currently allows adding extra parameters, e.g. a HttpServletRequest ..

For the client side in particukar, tt would also be usefult to generate interfaces in which named parameters coudl be dropped. These might represent common settings that are instead set by confiiguration or during initialisation, rathee than as part of each call, or just optional parameters the client does not send.

For example, something like:

map:
   parameters:
   - remove: traceLevel 

@hauner
Copy link
Member

hauner commented Mar 18, 2025

To make sure I understand your use case: For example: you have described a header in the OpenAPI that will be handled by a filter. Therefore it would not be needed in the endpoint interface method?

@richard-melvin
Copy link
Author

My use case is currently only for the client. On the server, I agree it could be handled by a filter, or perhaps could be bundled into some other added parameter.

@hauner
Copy link
Member

hauner commented Mar 18, 2025

hmm, I'm confused by client side. openapi-processor does generate server side code. How do you use it client side? Feign? 🤔

@richard-melvin
Copy link
Author

I just wrote an implementaiton of the generated interface (using REST-assured).

@hauner hauner added this to the core: next milestone Mar 19, 2025
@hauner
Copy link
Member

hauner commented Mar 19, 2025

I'll add it.

hauner added a commit to openapi-processor/openapi-processor-base that referenced this issue Apr 3, 2025
hauner added a commit to openapi-processor/openapi-processor-base that referenced this issue Apr 4, 2025
hauner added a commit to openapi-processor/openapi-processor-base that referenced this issue Apr 4, 2025
@hauner hauner modified the milestones: core: next, 2025.2 Apr 4, 2025
hauner added a commit that referenced this issue Apr 14, 2025
@hauner
Copy link
Member

hauner commented Apr 21, 2025

available with 2025.2

@hauner hauner closed this as completed Apr 21, 2025
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

No branches or pull requests

2 participants