2 Replies Latest reply on Apr 7, 2009 1:18 PM by alesj

    Best files update strategy

    alesj

      WRT:
      - http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4224070#4224070

      What would be the best way to "notice" user file changes/updates?
      The idea is to make it temp agnostic.

      With the previous discussion (see wrt), I see two options:
      (1) each sub-system has a way of diff between original and possible temp
      ** see Remy's option on JBW having a VFS/VDF based resources lookup

      (2) push any changes from original to temp

      The (1) is read only, hence faster.
      Where (2) is completely general, but needs to do read/write.

      I've started off with (2):
      - http://anonsvn.jboss.org/repos/jbossas/projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/SynchWrapperModificationChecker.java

      But if someone has a better idea, I'm all ears. :-)

      Btw: is there some oss framework like svn's merge,
      so instead of overriding files, we would simply merge them?

        • 1. Re: Best files update strategy
          jaikiran

           

          "alesj" wrote:

          Btw: is there some oss framework like svn's merge,
          so instead of overriding files, we would simply merge them?

          Not sure whether there's a existing project for this, but do we really want to merge the changes? Shouldn't it be a total overwrite? In case of merging, i guess we would introduce more complexity like how to deal with merge conflicts?

          • 2. Re: Best files update strategy
            alesj

            I'm just thinking outloud. :-)

            Since in most cases you just change/fix a few minor things,
            changing some line, typo or simple configuration.

            It would of course be configurable,
            e.g. merge-fail, merge-override, override, ...