You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[ideas] Progressive JSON Streamer: Architecture with Fluent Builders, Policy-Based Authorization, and Composable Data Pipelines by @ panastasiadist @ reddit
#3
Nice. Let me share a few ideas that you could consider.
Regarding future functionality, you could introduce key-level data transformers and pipelines, as well as authorization/policy handlers. The first would be fed data provided by resolvers and process it before allowing it to be streamed. The latter would decide on whether a key-value is eligible for being streamed under specific conditions. Although this functionality could be part of a resolver's responsibilities, I believe that the benefits of SRP will be better utilized, if this type of functionality is taken care in discrete isolated steps based on library-level provided infrastructure.
Taking into account future key-level functionality should it be introduced, current array based data structure configuration could be better served by a typed, and fluent "data structure builder". That would relief developers from the hassle of repeating the placeholder symbol, and would offer an IDE-discoverable way of enabling key-level special functionality.
Moreover, you could introduce a way of customizing the errors produced by invalid JSON, for example by means of a callback which receives error/exception/value data and returns the appropriate error structure.
I wish you all the best with your project's progress.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
by @panastasiadist at Reddit Post
Beta Was this translation helpful? Give feedback.
All reactions