Comments (8)
for example, adding mtime is, I think, likely to lead to cache fragmentation from files that are content-identical but produced on different machines via a hermetic process.
I agree that we generally shouldn't add timestamps. The cache fragmentation would only affect Directory protos, not actual file blobs, but it's still not ideal.
However, in BuildStream where we build a whole module in a single Action using a traditional build system (e.g., autotools, cmake), we have a feature to support incremental builds. This currently only works for local builds but we'd like to support it also with remote execution. The way this works is that we use the previous buildtree + the modified sources as input tree for the incremental build. Unfortunately, with traditional build systems it's crucial to properly support file mtime, otherwise too little or too much will be rebuilt.
We won't use file mtime for regular builds, however, for incremental builds the improved user experience is worth the Directory proto cache fragmentation.
I don't expect Bazel or other REAPI clients that work with fine-grained actions to be interested in file mtimes. However, we'd still like to support this for the optional incremental build feature in BuildStream and at least one REAPI server. More clients might be interested in additional node properties, though, e.g., for permissions. That's why we thought it might be sensible to add a string-based extension mechanism that would provide implementations the flexibility for such features. If one or multiple such extensions turn out to be more generally useful, we can consider standardizing them, similar to platform properties.
from remote-apis.
Note that there's a related but less-comprehensive proposal in #54.
I'm not sure that adding the capability to support arbitrary properties is a great idea--for example, adding mtime is, I think, likely to lead to cache fragmentation from files that are content-identical but produced on different machines via a hermetic process. There's clearly a general desire for better permissions handling--at least increased clarity, and possibly more flexibility.
I'm curious to hear what others think of file/node-specific properties--what would be useful vs. overly complex, whether a general mechanism is necessary, etc.
from remote-apis.
from remote-apis.
I'm torn on representing these as general properties vs a small number of known fields. modified-time feels like it should be a standardized and cross-platform field. Permissions are platform-dependent, which argues for general.
I would lean towards a general property usually and allow the server to implement the supported keys. I'm not sure there's an added value to specific field support
from remote-apis.
from remote-apis.
Apologies, I missed your response.
The current use-cases of Directory protos are action inputs and action
outputs, and I think we should outline these explicitly w.r.t to what the
additional metadata should be and how is it to be interpreted (Eric's
proposal
https://docs.google.com/document/d/10ari9WtTTSv9bqB_UU-oe2gBtaAA7HyQgkpP-RFP80c/edit?ts=5d433a83#
adds
other use-cases, and when it goes through, we will need to address these
similarly as well).
That's fine, I'll read the proposal and update here.
- The properties need to be sorted, for canonical Directory
representation.
Agreed.
- Do we want to make is_executable part of metadata? Logically, it does
belong there, so will be a bit cleaner, and then we can remove the field in
v3. On the other hand, it will make the messages referencing executables
more verbose, particularly if we want to optionally add the properties to
outputs.
I have no strong feelings on that. On one-hand if file properties are supported then is_executable becomes redundant and could be replaced with a reference to those although I wouldn't want to break functionality.
from remote-apis.
@ola-rozenfeld I've made some updates to #91. Does this address some of your concerns? In terms of what the output should be I intend for properties to be returned as part of the message. In terms of RE, I'd agree that the server should set the properties of the files where possible (and there will need to be an update to #91) for this.
from remote-apis.
I've added a few comments to #91.
- Output metadata: either we say the server will not add any output metadata, or we need to add a message to Command, e.g. OutputMetadata with repeated string property_name, that the server needs to return for every output.
This is still missing if I haven't overlooked anything.
from remote-apis.
Related Issues (20)
- Compression: Further specify ByteStream WriteResponse committed_size field for compressed blobs HOT 1
- How does GetCapabilities() interact with authorization & unknown instance names? HOT 3
- Git tags for minor versions
- Non-Bazel Server Example HOT 3
- Replace message Tree with a topologically sorted varint delimited stream of Directory messages HOT 1
- REv3 idea: Make is_topologically_sorted the default, and eliminate tag bytes
- Let exit_code be better aligned with C/POSIX
- REv3 idea: Make use of digest_function in requests mandatory
- REv3: Use IPLD (CIDs, DAG-PB, etc.)
- Chyba
- CAS: Existence Caching in Intermediate Caches (user experience report) HOT 2
- Please tag REv2 2.1.0 2.2.0 [...] HOT 6
- API extension for Git hashes HOT 1
- Googleapis is outdated HOT 1
- Should we make a resolution to NOT have a v3? HOT 2
- Support compression with external dictionary HOT 6
- Add supported_max_cas_entry_size property to CacheCapabilities HOT 2
- Bazel version to use to run hooks/pre-commit unclear HOT 1
- REv3: Reduce asymmetry between O(n) output files and O(1) output directories HOT 2
- Platform standardization HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from remote-apis.