Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    canSyncCache on server-side DSRequest

    Is it possible to have a dsRequest.setCanSyncCache(boolean) on the server-side of a dsRequest?
    Now, I have to create an empty operationBinding only for this purpose, e.g.:
    Code:
    <operationBinding operationType="update" operationId="noCacheSync"
    			canSyncCache="false">
    			<tableClause>t_adressen</tableClause>
    		</operationBinding>
    It would be better to have such a method directly on the dsRequest, e.g. dsRequest.setCanSyncCache(boolean).
    Using smartGWT 5.0p
    Last edited by edulid; 27 Feb 2015, 07:47.

    #2
    If you're still looking for this - it sounds like DSResponse.setInvalidateCache(true); is what you're after.

    Regards
    Isomorphic Software

    Comment


      #3
      No, because this is on the DSResponse.
      I actually have a server-side DSRequest (insert), which automatically performs a fetch afterwards (because of cacheSync).
      For optimization purposes, and because I am not using this inserts in the client - side, I need to turn off this behavior.

      I can do it with an operation binding:
      Code:
       <operationBinding operationType="add" operationId="noCacheSync" canSyncCache="false">
      <tableClause>t_adressen</tableClause>
      </operationBinding>
      But I have to create an operation binding for this purpose. If I have 4 tables I am inserting to, I have to create 4 operationBindings only for this purpose.

      Wouldn't be better to have a method in the server-side DSRequest, for example dsRequest.setCanSyncCache(false), that indicates that no fetch should be performed after the insert? Then I wouldn't need these 4 operation bindings.

      Comment


        #4
        That doesn't seem especially onerous, but we'll take a note that a convenience API has been requested here.

        Comment


          #5
          Hi Isomorphic,

          I support edulids suggestion, as I have the exact same use case (many operationBindings that are in clientside-use that I'd have to duplicate for server use where I do not need the cache sync).

          Best regards
          Blama

          Comment


            #6
            +1
            same here

            Comment

            Working...
            X