wb-cache 0.1.0

Your L1 in-app write-behind cache for various kinds of backends.
Documentation
<mxfile host="65bd71144e">
    <diagram id="Lth35N3WGJTE87Q9JVgG" name="Page-1">
        <mxGraphModel dx="1093" dy="1092" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="850" pageHeight="1100" math="0" shadow="0">
            <root>
                <mxCell id="0"/>
                <mxCell id="1" parent="0"/>
                <mxCell id="2" value="" style="group;fillColor=default;strokeWidth=1;perimeterSpacing=0;glass=0;strokeColor=default;shadow=1;" vertex="1" connectable="0" parent="1">
                    <mxGeometry x="460" y="40" width="220" height="130" as="geometry"/>
                </mxCell>
                <mxCell id="3" value="" style="curved=1;endArrow=openThin;html=1;fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=default;resizable=0;rounded=1;strokeColor=#6c8ebf;strokeWidth=5;align=center;verticalAlign=middle;endFill=0;fillColor=#dae8fc;" edge="1" parent="2">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="20" y="50" as="sourcePoint"/>
                        <mxPoint x="100" y="50" as="targetPoint"/>
                        <Array as="points"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="4" value="Initial Stage&lt;div&gt;&lt;span style=&quot;background-color: transparent;&quot;&gt;(Request)&lt;/span&gt;&lt;/div&gt;" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=none;fillColor=none;gradientColor=none;" vertex="1" connectable="0" parent="3">
                    <mxGeometry x="-0.425" relative="1" as="geometry">
                        <mxPoint x="97" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="5" value="" style="curved=1;endArrow=openThin;html=1;strokeWidth=5;fillColor=#60a917;strokeColor=#2D7600;verticalAlign=middle;align=left;endFill=0;" edge="1" parent="2">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="20" y="80" as="sourcePoint"/>
                        <mxPoint x="100" y="80" as="targetPoint"/>
                        <Array as="points"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="6" value="&lt;font&gt;Internal Processing&lt;/font&gt;" style="edgeLabel;html=1;align=right;verticalAlign=middle;resizable=0;points=[];fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=none;fillColor=none;gradientColor=none;labelPosition=left;verticalLabelPosition=bottom;spacingRight=0;" vertex="1" connectable="0" parent="5">
                    <mxGeometry x="0.1596" y="8" relative="1" as="geometry">
                        <mxPoint x="143" y="8" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="7" value="" style="curved=1;endArrow=openThin;html=1;fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=default;resizable=0;rounded=1;strokeColor=#A50040;strokeWidth=5;align=left;verticalAlign=middle;endFill=0;fillColor=#d80073;" edge="1" parent="2">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="20" y="110" as="sourcePoint"/>
                        <mxPoint x="100" y="110" as="targetPoint"/>
                        <Array as="points"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="8" value="&lt;font&gt;Final Result&lt;/font&gt;" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=none;fillColor=none;gradientColor=none;spacingRight=0;" vertex="1" connectable="0" parent="7">
                    <mxGeometry x="-0.1594" y="5" relative="1" as="geometry">
                        <mxPoint x="86" y="5" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="9" value="Legend" style="rounded=0;whiteSpace=wrap;html=1;align=center;verticalAlign=top;fontFamily=Helvetica;fontSize=14;fontColor=default;labelBackgroundColor=none;resizable=1;fillColor=none;gradientColor=none;movable=1;rotatable=1;deletable=1;editable=1;locked=0;connectable=1;fontStyle=1;strokeColor=none;shadow=0;" vertex="1" parent="2">
                    <mxGeometry width="220" height="130" as="geometry"/>
                </mxCell>
                <mxCell id="11" value="User&lt;div&gt;Code&lt;/div&gt;" style="rounded=1;whiteSpace=wrap;html=1;strokeWidth=3;fontFamily=American TypeWriter;fontStyle=1;fontSize=20;fillColor=#f5f5f5;fontColor=#333333;strokeColor=#666666;" vertex="1" parent="1">
                    <mxGeometry x="280" y="40" width="160" height="80" as="geometry"/>
                </mxCell>
                <mxCell id="12" value="Cached?" style="rhombus;whiteSpace=wrap;html=1;rounded=1;strokeColor=#666666;strokeWidth=3;align=center;verticalAlign=middle;fontFamily=American TypeWriter;fontSize=20;fontColor=#333333;fontStyle=1;fillColor=#f5f5f5;" vertex="1" parent="1">
                    <mxGeometry x="280" y="160" width="160" height="80" as="geometry"/>
                </mxCell>
                <mxCell id="13" value="" style="curved=1;endArrow=openThin;html=1;entryX=0.5;entryY=0;entryDx=0;entryDy=0;strokeWidth=5;fillColor=#dae8fc;strokeColor=#6c8ebf;exitX=0.5;exitY=1;exitDx=0;exitDy=0;endFill=0;" edge="1" parent="1" source="11" target="12">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="390" y="490" as="sourcePoint"/>
                        <mxPoint x="475" y="620" as="targetPoint"/>
                        <Array as="points"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="15" value="Request&lt;div&gt;to change&lt;/div&gt;&lt;div&gt;a record&lt;/div&gt;" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];" vertex="1" connectable="0" parent="13">
                    <mxGeometry x="-0.5" y="2" relative="1" as="geometry">
                        <mxPoint x="28" y="10" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="18" value="" style="curved=1;endArrow=openThin;html=1;exitX=0.5;exitY=1;exitDx=0;exitDy=0;strokeWidth=5;fillColor=#60a917;strokeColor=#2D7600;verticalAlign=middle;align=left;endFill=0;" edge="1" parent="1" source="12" target="20">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="480" y="440" as="sourcePoint"/>
                        <mxPoint x="240" y="290" as="targetPoint"/>
                        <Array as="points"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="19" value="No" style="edgeLabel;html=1;align=right;verticalAlign=middle;resizable=0;points=[];fontFamily=American TypeWriter;fontSize=11;fontColor=default;labelBackgroundColor=none;fillColor=none;gradientColor=none;labelPosition=left;verticalLabelPosition=bottom;spacingRight=0;" vertex="1" connectable="0" parent="18">
                    <mxGeometry x="0.1596" y="8" relative="1" as="geometry">
                        <mxPoint x="22" y="-3" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="20" value="Is in&lt;div&gt;updates?&lt;/div&gt;" style="rhombus;whiteSpace=wrap;html=1;rounded=1;strokeColor=#666666;strokeWidth=3;align=center;verticalAlign=middle;fontFamily=American TypeWriter;fontSize=20;fontColor=#333333;fontStyle=1;fillColor=#f5f5f5;" vertex="1" parent="1">
                    <mxGeometry x="280" y="280" width="160" height="80" as="geometry"/>
                </mxCell>
                <mxCell id="21" value="Flush&lt;div&gt;one&lt;/div&gt;" style="shape=process;whiteSpace=wrap;html=1;backgroundOutline=1;rounded=1;strokeColor=#666666;strokeWidth=3;align=center;verticalAlign=middle;fontFamily=American TypeWriter;fontSize=20;fontColor=#333333;fontStyle=1;fillColor=#f5f5f5;" vertex="1" parent="1">
                    <mxGeometry x="470" y="280" width="160" height="80" as="geometry"/>
                </mxCell>
                <mxCell id="22" value="" style="curved=1;endArrow=openThin;html=1;exitX=1;exitY=0.5;exitDx=0;exitDy=0;strokeWidth=5;fillColor=#60a917;strokeColor=#2D7600;verticalAlign=middle;align=left;endFill=0;entryX=0;entryY=0.5;entryDx=0;entryDy=0;" edge="1" parent="1" source="20" target="21">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="370" y="250" as="sourcePoint"/>
                        <mxPoint x="370" y="290" as="targetPoint"/>
                        <Array as="points"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="23" value="Yes" style="edgeLabel;html=1;align=right;verticalAlign=middle;resizable=0;points=[];fontFamily=American TypeWriter;fontSize=11;fontColor=default;labelBackgroundColor=none;fillColor=none;gradientColor=none;labelPosition=left;verticalLabelPosition=bottom;spacingRight=0;" vertex="1" connectable="0" parent="22">
                    <mxGeometry x="0.1596" y="8" relative="1" as="geometry">
                        <mxPoint x="-3" y="-12" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="24" value="Fetch&lt;div&gt;from&lt;/div&gt;&lt;div&gt;backend&lt;/div&gt;" style="shape=process;whiteSpace=wrap;html=1;backgroundOutline=1;rounded=1;strokeColor=#666666;strokeWidth=3;align=center;verticalAlign=middle;fontFamily=American TypeWriter;fontSize=20;fontColor=#333333;fontStyle=1;fillColor=#f5f5f5;" vertex="1" parent="1">
                    <mxGeometry x="280" y="400" width="160" height="80" as="geometry"/>
                </mxCell>
                <mxCell id="25" value="" style="curved=1;endArrow=openThin;html=1;exitX=0.5;exitY=1;exitDx=0;exitDy=0;strokeWidth=5;fillColor=#60a917;strokeColor=#2D7600;verticalAlign=middle;align=left;endFill=0;entryX=0.5;entryY=0;entryDx=0;entryDy=0;" edge="1" parent="1" source="20" target="24">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="370" y="250" as="sourcePoint"/>
                        <mxPoint x="370" y="290" as="targetPoint"/>
                        <Array as="points"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="26" value="No" style="edgeLabel;html=1;align=right;verticalAlign=middle;resizable=0;points=[];fontFamily=American TypeWriter;fontSize=11;fontColor=default;labelBackgroundColor=none;fillColor=none;gradientColor=none;labelPosition=left;verticalLabelPosition=bottom;spacingRight=0;" vertex="1" connectable="0" parent="25">
                    <mxGeometry x="0.1596" y="8" relative="1" as="geometry">
                        <mxPoint x="22" y="-3" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="29" value="" style="endArrow=openThin;html=1;exitX=0.5;exitY=1;exitDx=0;exitDy=0;entryX=1;entryY=0.5;entryDx=0;entryDy=0;strokeWidth=5;fillColor=#60a917;strokeColor=#2D7600;verticalAlign=middle;align=left;endFill=0;edgeStyle=orthogonalEdgeStyle;" edge="1" parent="1" source="21" target="24">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="480" y="440" as="sourcePoint"/>
                        <mxPoint x="390" y="680" as="targetPoint"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="31" value="" style="endArrow=openThin;html=1;fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=default;resizable=0;entryX=0;entryY=0.75;entryDx=0;entryDy=0;rounded=1;strokeColor=#A50040;strokeWidth=5;align=left;verticalAlign=middle;endFill=0;fillColor=#d80073;edgeStyle=orthogonalEdgeStyle;exitX=0.5;exitY=0;exitDx=0;exitDy=0;" edge="1" parent="1" source="35" target="11">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="160" y="300" as="sourcePoint"/>
                        <mxPoint x="460" y="480" as="targetPoint"/>
                        <Array as="points">
                            <mxPoint x="160" y="100"/>
                        </Array>
                    </mxGeometry>
                </mxCell>
                <mxCell id="33" value="Record" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];" vertex="1" connectable="0" parent="31">
                    <mxGeometry x="-0.0545" y="-3" relative="1" as="geometry">
                        <mxPoint x="67" y="-81" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="40" value="Yes" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];" vertex="1" connectable="0" parent="31">
                    <mxGeometry x="-0.8927" y="-1" relative="1" as="geometry">
                        <mxPoint x="19" y="12" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="35" value="Found?" style="rhombus;whiteSpace=wrap;html=1;rounded=1;strokeColor=#666666;strokeWidth=3;align=center;verticalAlign=middle;fontFamily=American TypeWriter;fontSize=20;fontColor=#333333;fontStyle=1;fillColor=#f5f5f5;" vertex="1" parent="1">
                    <mxGeometry x="80" y="400" width="160" height="80" as="geometry"/>
                </mxCell>
                <mxCell id="36" value="" style="endArrow=openThin;html=1;exitX=0;exitY=0.5;exitDx=0;exitDy=0;entryX=1;entryY=0.5;entryDx=0;entryDy=0;strokeWidth=5;fillColor=#60a917;strokeColor=#2D7600;verticalAlign=middle;align=left;endFill=0;edgeStyle=orthogonalEdgeStyle;" edge="1" parent="1" source="24" target="35">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="560" y="370" as="sourcePoint"/>
                        <mxPoint x="450" y="450" as="targetPoint"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="37" value="" style="endArrow=openThin;html=1;fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=default;resizable=0;rounded=1;strokeColor=#A50040;strokeWidth=5;align=left;verticalAlign=middle;endFill=0;fillColor=#d80073;edgeStyle=orthogonalEdgeStyle;exitX=0;exitY=0.5;exitDx=0;exitDy=0;" edge="1" parent="1" source="12">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="180" y="410" as="sourcePoint"/>
                        <mxPoint x="160" y="200" as="targetPoint"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="39" value="Yes" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];" vertex="1" connectable="0" parent="37">
                    <mxGeometry x="-0.1855" relative="1" as="geometry">
                        <mxPoint y="-10" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="41" value="" style="endArrow=openThin;html=1;fontFamily=Helvetica;fontSize=11;fontColor=default;labelBackgroundColor=default;resizable=0;entryX=0;entryY=0.25;entryDx=0;entryDy=0;rounded=1;strokeColor=#A50040;strokeWidth=5;align=left;verticalAlign=middle;endFill=0;fillColor=#d80073;edgeStyle=orthogonalEdgeStyle;exitX=0;exitY=0.5;exitDx=0;exitDy=0;" edge="1" parent="1" source="35" target="11">
                    <mxGeometry width="50" height="50" relative="1" as="geometry">
                        <mxPoint x="30" y="430" as="sourcePoint"/>
                        <mxPoint x="140" y="130" as="targetPoint"/>
                        <Array as="points">
                            <mxPoint x="60" y="440"/>
                            <mxPoint x="60" y="60"/>
                        </Array>
                    </mxGeometry>
                </mxCell>
                <mxCell id="42" value="None" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];" vertex="1" connectable="0" parent="41">
                    <mxGeometry x="-0.0545" y="-3" relative="1" as="geometry">
                        <mxPoint x="167" y="-127" as="offset"/>
                    </mxGeometry>
                </mxCell>
                <mxCell id="43" value="No" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];" vertex="1" connectable="0" parent="41">
                    <mxGeometry x="-0.8927" y="-1" relative="1" as="geometry">
                        <mxPoint x="9" y="23" as="offset"/>
                    </mxGeometry>
                </mxCell>
            </root>
        </mxGraphModel>
    </diagram>
</mxfile>