mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chun-Hung Hsiao <chhs...@mesosphere.io>
Subject Re: Review Request 63105: Added 'apply' handlers for storage operations.
Date Thu, 19 Oct 2017 23:19:35 GMT


> On Oct. 19, 2017, 10:42 p.m., Chun-Hung Hsiao wrote:
> > src/common/resources.cpp
> > Line 1765 (original), 1765 (patched)
> > <https://reviews.apache.org/r/63105/diff/1/?file=1862325#file1862325line1765>
> >
> >     We need a separated validation function. A resource provider will do the following:
> >     ```
> >     Option<Error> error = Resources::validateOperation(operation);
> >     if (error.isSome()) {
> >       Update operation status: OFFER_OPERATION_ERROR;
> >     }
> >     
> >     Do the actual operation, e.g., call CSI.
> >     if (actual operation fails) {
> >       Update oeration status: OFFER_OPERATION_FAILED;
> >     }
> >     
> >     checkpointedResources.apply(target resource);
> >     Update operation status: OFFER_OPERATION_FINISHED;
> >     ```
> >     Can you separate the validation logic from `Resources::apply` and provide an
interface?
> >     
> >     We can also use the new validation functions in `src/common/resource_utils.cpp`

Hmm discussed with Jie and now it seems to me that the validation will be done on the master.
Then I think for SLRP a single `apply()` is sufficient.


- Chun-Hung


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63105/#review188775
-----------------------------------------------------------


On Oct. 18, 2017, 2:36 p.m., Jan Schlicht wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63105/
> -----------------------------------------------------------
> 
> (Updated Oct. 18, 2017, 2:36 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier and Jie Yu.
> 
> 
> Bugs: MESOS-7594
>     https://issues.apache.org/jira/browse/MESOS-7594
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Added 'apply' handlers for storage operations.
> 
> 
> Diffs
> -----
> 
>   src/common/resources.cpp 7ee4dae1389e037531aec533a3d235ee06443ea8 
> 
> 
> Diff: https://reviews.apache.org/r/63105/diff/1/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Jan Schlicht
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message