9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] Patcher file server
@ 2025-01-23 10:28 tlaronde
  2025-01-23 16:33 ` Dave Eckhardt
  2025-01-23 17:47 ` Skip Tavakkolian
  0 siblings, 2 replies; 7+ messages in thread
From: tlaronde @ 2025-01-23 10:28 UTC (permalink / raw)
  To: 9fans

Does someone know of a "patcher file server" for Plan9? I mean:

There are external sources in a hier called S. (S is considered a
remote resource, owned by some external entity and this is text.)

There is a same hier called P, with some filename matching a filename
on S, but with, for clarity (it is not required if they are diffs), a
'.diff' extension.

If there is such a diff, the file served is S/filename patched with
S/filename.diff. If there is not, the vanilla file is served.

If a modification is made, the diff is modified or created.

(Whether the P is itself backed by a filesystem doing versioning is
orthogonal.)
-- 
        Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
                     http://www.kergis.com/
                    http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T332d621280e18c2d-Ma2debbf38b88873fd7bde9a4
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [9fans] Patcher file server
  2025-01-23 10:28 [9fans] Patcher file server tlaronde
@ 2025-01-23 16:33 ` Dave Eckhardt
  2025-01-23 17:24   ` sirjofri
  2025-01-24  7:50   ` tlaronde
  2025-01-23 17:47 ` Skip Tavakkolian
  1 sibling, 2 replies; 7+ messages in thread
From: Dave Eckhardt @ 2025-01-23 16:33 UTC (permalink / raw)
  To: 9fans

> Does someone know of a "patcher file server" for Plan9?

That is an interesting idea!  The closest thing I am aware
of (which might be useful as a starting point) is divergefs,
done by a student of mine, Chao-Kuo Lin, nearly 20 years ago,
see:

  http://9p.io/sources/contrib/de0u/INDEX

I don't think either of us has tried to build it recently.

Dave Eckhardt

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T332d621280e18c2d-M7682756d8afc8c415da56f85
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [9fans] Patcher file server
  2025-01-23 16:33 ` Dave Eckhardt
@ 2025-01-23 17:24   ` sirjofri
  2025-01-24  7:56     ` tlaronde
  2025-01-24  7:50   ` tlaronde
  1 sibling, 1 reply; 7+ messages in thread
From: sirjofri @ 2025-01-23 17:24 UTC (permalink / raw)
  To: 9fans

23.01.2025 17:37:30 Dave Eckhardt <davide+p9@cs.cmu.edu>:

>> Does someone know of a "patcher file server" for Plan9?
>
> That is an interesting idea!  The closest thing I am aware
> of (which might be useful as a starting point) is divergefs,
> done by a student of mine, Chao-Kuo Lin, nearly 20 years ago,

Just in case, isn't this quite easy to script using a ramfs and binds?

I think:

walk/ls, to find all files with their diff counterparts
ramfs for temporary file storage
bind for each individual temporary file to their original location

Sure, the original diff files would still be there, but that should be enough for building/testing etc.

sirjofri

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T332d621280e18c2d-M66d07e92e9bcd5481099c2ae
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [9fans] Patcher file server
  2025-01-23 10:28 [9fans] Patcher file server tlaronde
  2025-01-23 16:33 ` Dave Eckhardt
@ 2025-01-23 17:47 ` Skip Tavakkolian
  2025-01-24  8:01   ` tlaronde
  1 sibling, 1 reply; 7+ messages in thread
From: Skip Tavakkolian @ 2025-01-23 17:47 UTC (permalink / raw)
  To: 9fans

Couldn't this be done with union directories with the proper ordering
and use '-c'?

This thread from 24 years ago might be relevant. The goal was to stash
files that had been pulled from the remote fs, to handle low bandwidth
and unreliable networks. If I understand your use case, you want to be
able to keep the changes on the local shadow fs until ready to push
them to the remote?

https://9fans.topicbox.com/groups/9fans/T74b794a0b25b3452-M4e93273ae029a34387d5b847/9fans-persistent-cache-for-cfs

I think for environments where the external source (fs) is heavily
used, inconsistency would become an issue.

On Thu, Jan 23, 2025 at 3:10 AM <tlaronde@kergis.com> wrote:
> 
> Does someone know of a "patcher file server" for Plan9? I mean:
> 
> There are external sources in a hier called S. (S is considered a
> remote resource, owned by some external entity and this is text.)
> 
> There is a same hier called P, with some filename matching a filename
> on S, but with, for clarity (it is not required if they are diffs), a
> '.diff' extension.
> 
> If there is such a diff, the file served is S/filename patched with
> S/filename.diff. If there is not, the vanilla file is served.
> 
> If a modification is made, the diff is modified or created.
> 
> (Whether the P is itself backed by a filesystem doing versioning is
> orthogonal.)
> --
> Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
>              http://www.kergis.com/
>             http://kertex.kergis.com/
> Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T332d621280e18c2d-Mc117a24ad12598904350b1fc
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [9fans] Patcher file server
  2025-01-23 16:33 ` Dave Eckhardt
  2025-01-23 17:24   ` sirjofri
@ 2025-01-24  7:50   ` tlaronde
  1 sibling, 0 replies; 7+ messages in thread
From: tlaronde @ 2025-01-24  7:50 UTC (permalink / raw)
  To: 9fans

On Thu, Jan 23, 2025 at 11:33:37AM -0500, Dave Eckhardt wrote:
> > Does someone know of a "patcher file server" for Plan9?
> 
> That is an interesting idea!  The closest thing I am aware
> of (which might be useful as a starting point) is divergefs,
> done by a student of mine, Chao-Kuo Lin, nearly 20 years ago,
> see:
> 
>   http://9p.io/sources/contrib/de0u/INDEX
> 
> I don't think either of us has tried to build it recently.

Thanks for the link! I will give it a look.
-- 
        Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
                     http://www.kergis.com/
                    http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T332d621280e18c2d-Ma1ae9db4c2952b8146b21a09
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [9fans] Patcher file server
  2025-01-23 17:24   ` sirjofri
@ 2025-01-24  7:56     ` tlaronde
  0 siblings, 0 replies; 7+ messages in thread
From: tlaronde @ 2025-01-24  7:56 UTC (permalink / raw)
  To: 9fans

On Thu, Jan 23, 2025 at 06:24:01PM +0100, sirjofri wrote:
> 23.01.2025 17:37:30 Dave Eckhardt <davide+p9@cs.cmu.edu>:
> 
> >> Does someone know of a "patcher file server" for Plan9?
> >
> > That is an interesting idea!  The closest thing I am aware
> > of (which might be useful as a starting point) is divergefs,
> > done by a student of mine, Chao-Kuo Lin, nearly 20 years ago,
> 
> Just in case, isn't this quite easy to script using a ramfs and binds?
> 
> I think:
> 
> walk/ls, to find all files with their diff counterparts
> ramfs for temporary file storage
> bind for each individual temporary file to their original location
> 
> Sure, the original diff files would still be there, but that should be enough for building/testing etc.

Yes, If I have to write it, I will probably start by scripting it if only
to prototype. At first, for the envisioned use case, it will not have
to serve a highly changing or serving filesystem.
-- 
        Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
                     http://www.kergis.com/
                    http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T332d621280e18c2d-M1fae099e9bce8460ea45ef18
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [9fans] Patcher file server
  2025-01-23 17:47 ` Skip Tavakkolian
@ 2025-01-24  8:01   ` tlaronde
  0 siblings, 0 replies; 7+ messages in thread
From: tlaronde @ 2025-01-24  8:01 UTC (permalink / raw)
  To: 9fans

On Thu, Jan 23, 2025 at 09:47:05AM -0800, Skip Tavakkolian wrote:
> Couldn't this be done with union directories with the proper ordering
> and use '-c'?
> 
> This thread from 24 years ago might be relevant. The goal was to stash
> files that had been pulled from the remote fs, to handle low bandwidth
> and unreliable networks. If I understand your use case, you want to be
> able to keep the changes on the local shadow fs until ready to push
> them to the remote?
> 

Yes, exactly! And generally for small changes that are more easily
seen as diff.

> https://9fans.topicbox.com/groups/9fans/T74b794a0b25b3452-M4e93273ae029a34387d5b847/9fans-persistent-cache-for-cfs
> 

Thanks for the link!

> I think for environments where the external source (fs) is heavily
> used, inconsistency would become an issue.
> 

Hum, you hit one point: if the diff doesn't apply there is some policy
to decide about what to do, and there should be a way to administrate
the thing by requiring user to reconciliate the two (and if the diff
is already applied, the diff should be simply suppressed).

> On Thu, Jan 23, 2025 at 3:10?AM <tlaronde@kergis.com> wrote:
> > 
> > Does someone know of a "patcher file server" for Plan9? I mean:
> > 
> > There are external sources in a hier called S. (S is considered a
> > remote resource, owned by some external entity and this is text.)
> > 
> > There is a same hier called P, with some filename matching a filename
> > on S, but with, for clarity (it is not required if they are diffs), a
> > '.diff' extension.
> > 
> > If there is such a diff, the file served is S/filename patched with
> > S/filename.diff. If there is not, the vanilla file is served.
> > 
> > If a modification is made, the diff is modified or created.
> > 
> > (Whether the P is itself backed by a filesystem doing versioning is
> > orthogonal.)
> > --
> > Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
> >              http://www.kergis.com/
> >             http://kertex.kergis.com/
> > Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C

-- 
        Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
                     http://www.kergis.com/
                    http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T332d621280e18c2d-M947ebdb97d552bc7f4afe025
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2025-01-24 13:58 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-01-23 10:28 [9fans] Patcher file server tlaronde
2025-01-23 16:33 ` Dave Eckhardt
2025-01-23 17:24   ` sirjofri
2025-01-24  7:56     ` tlaronde
2025-01-24  7:50   ` tlaronde
2025-01-23 17:47 ` Skip Tavakkolian
2025-01-24  8:01   ` tlaronde

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).