Replies: 4 comments 14 replies
-
What is the expected input for |
Beta Was this translation helpful? Give feedback.
-
We'll open a PR on with this information in this part of the design repo: https://github.com/microsoftgraph/msgraph-sdk-design/tree/master/middleware |
Beta Was this translation helpful? Give feedback.
-
i'm not sure i get the advantage here. BaseMiddleware meant you had to implement a send method, now you implement an intercept method instead which couples the pipeline to the middleware. pipeline next and pipeline send do the same thing so why both? Are you also managing being able to manage the response as well? What happens with managing that index when a middleware looks at the response and reissues the request? |
Beta Was this translation helpful? Give feedback.
-
I support the use of abstract classes and methods in python to enforce the contract (custom middlewares implementing the |
Beta Was this translation helpful? Give feedback.
-
The current implementation of the pipeline is such that middlewares have to take a dependency on BaseMiddleware this makes it easy to break user defined middlewares.
I am proposing a better middleware pipeline implementation that is simpler and avoids this inheritance relationship.
All a middleware has to do is implement the intercept method that takes instance of pipeline, request object and other **kwargs.
Beta Was this translation helpful? Give feedback.
All reactions