You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openwhisk.apache.org by Christophe Jelger <je...@adobe.com.INVALID> on 2019/12/03 09:56:20 UTC

Adding OW_ACTION_VERSION

Hello,

I just joined the dev list after opened https://github.com/apache/openwhisk/pull/4761 : it adds OW_ACTION_VERSION to the execution environment.

I was asked by Rodric to send this email to the list because this change will require extra changes in the runtime repos for tests (see his comment in the PR).
Since I just joined the list and have until now only been an active user of OpenWhisk, I don’t know what the process is to do that next. Any hint is appreciated.

BR,
Christophe
--
Christophe Jelger | AEM Commerce Developer
Adobe Research Schweiz AG
+41 (0)61 226 5792


Re: Adding OW_ACTION_VERSION

Posted by Rodric Rabbah <ro...@gmail.com>.
Thank Michele. I've submitted PRs for all the runtimes now.

-r

Re: Adding OW_ACTION_VERSION

Posted by Michele Sciabarra <mi...@sciabarra.com>.
I submitted the actionloop version of the ruby and java runtimes but the non-actionloop has never been removed. 
Also there has been some additional work on the java runtime non-actionloop recently. The runtime has been updated to java11 in the non-actionloop version. If needed I can do support for java11 for the actionloop one.
-- 
  Michele Sciabarra
  michele@sciabarra.com

----- Original message -----
From: Rodric Rabbah <ro...@gmail.com>
To: dev@openwhisk.apache.org
Subject: Re: Adding OW_ACTION_VERSION
Date: Tuesday, December 03, 2019 4:17 PM

I went ahead and created PRs for most of the runtimes - ones missing are
Docker, Go and Swift.

I noticed for Java and Ruby we have two copies of mostly the same code for
action-loop and non-action-loop. Do we need two copies of the same code?
These exists in Java and Ruby. I didn't spot them elsewhere.

https://github.com/apache/openwhisk-runtime-nodejs/pull/154
https://github.com/apache/openwhisk-runtime-python/pull/76
https://github.com/apache/openwhisk-runtime-php/pull/71
https://github.com/apache/openwhisk-runtime-dotnet/pull/27
https://github.com/apache/openwhisk-runtime-java/pull/104
https://github.com/apache/openwhisk-runtime-java/pull/105
https://github.com/apache/openwhisk-runtime-ruby/pull/38
https://github.com/apache/openwhisk-runtime-ruby/pull/39
https://github.com/apache/openwhisk-runtime-rust/pull/18

Re: Adding OW_ACTION_VERSION

Posted by Rodric Rabbah <ro...@gmail.com>.
I forgot to add that the runtime PR can actually be merged ahead of the
actual change upstream which I think we should accept.
Will wait 48hrs for comments before having a merge fest by silent assent.

-r

On Tue, Dec 3, 2019 at 10:17 AM Rodric Rabbah <ro...@gmail.com> wrote:

> I went ahead and created PRs for most of the runtimes - ones missing are
> Docker, Go and Swift.
>
> I noticed for Java and Ruby we have two copies of mostly the same code for
> action-loop and non-action-loop. Do we need two copies of the same code?
> These exists in Java and Ruby. I didn't spot them elsewhere.
>
> https://github.com/apache/openwhisk-runtime-nodejs/pull/154
> https://github.com/apache/openwhisk-runtime-python/pull/76
> https://github.com/apache/openwhisk-runtime-php/pull/71
> https://github.com/apache/openwhisk-runtime-dotnet/pull/27
> https://github.com/apache/openwhisk-runtime-java/pull/104
> https://github.com/apache/openwhisk-runtime-java/pull/105
> https://github.com/apache/openwhisk-runtime-ruby/pull/38
> https://github.com/apache/openwhisk-runtime-ruby/pull/39
> https://github.com/apache/openwhisk-runtime-rust/pull/18
>
>

Re: Adding OW_ACTION_VERSION

Posted by Rodric Rabbah <ro...@gmail.com>.
I went ahead and created PRs for most of the runtimes - ones missing are
Docker, Go and Swift.

I noticed for Java and Ruby we have two copies of mostly the same code for
action-loop and non-action-loop. Do we need two copies of the same code?
These exists in Java and Ruby. I didn't spot them elsewhere.

https://github.com/apache/openwhisk-runtime-nodejs/pull/154
https://github.com/apache/openwhisk-runtime-python/pull/76
https://github.com/apache/openwhisk-runtime-php/pull/71
https://github.com/apache/openwhisk-runtime-dotnet/pull/27
https://github.com/apache/openwhisk-runtime-java/pull/104
https://github.com/apache/openwhisk-runtime-java/pull/105
https://github.com/apache/openwhisk-runtime-ruby/pull/38
https://github.com/apache/openwhisk-runtime-ruby/pull/39
https://github.com/apache/openwhisk-runtime-rust/pull/18

Re: Adding OW_ACTION_VERSION

Posted by Rodric Rabbah <ro...@gmail.com>.
Thanks Christophe for the contribution. 

The specific change is question is part of the test suite we run for all runtimes. The test checks the what values are available in the runtime context. Since there’s a new value (action version) now being checked, I see two options:

Make the change as is and accept the PR and then patch up all the runtimes (the change is trivial but has to be done for all the runtime repos). 

Alternatively, make the check for the additional context variable optional which won’t break any of the runtime tests and once all the runtimes are updated, then we can make it mandatory.

I favor the first approach in this case but others may differ. The runtimes themselves do not need to change, it is only one test that needs to adapt per runtime. 

-r

> On Dec 3, 2019, at 4:56 AM, Christophe Jelger <je...@adobe.com.invalid> wrote:
> 
> Hello,
> 
> I just joined the dev list after opened https://github.com/apache/openwhisk/pull/4761 : it adds OW_ACTION_VERSION to the execution environment.
> 
> I was asked by Rodric to send this email to the list because this change will require extra changes in the runtime repos for tests (see his comment in the PR).
> Since I just joined the list and have until now only been an active user of OpenWhisk, I don’t know what the process is to do that next. Any hint is appreciated.
> 
> BR,
> Christophe
> --
> Christophe Jelger | AEM Commerce Developer
> Adobe Research Schweiz AG
> +41 (0)61 226 5792
> 

Re: Adding OW_ACTION_VERSION

Posted by Christophe Jelger <je...@adobe.com.INVALID>.
Hi Tyson,

Yes it's exactly the use case you mention: the keys and values are stored externally, and yes the cache might be overwritten by concurrent action invocations.

Regards,
Christophe

On 04.12.19, 01:32, "Tyson Norris" <tn...@adobe.com.INVALID> wrote:

    Hi  -
    Just to clarify, your examples mention "cache keys" - can you confirm these keys are stored external to the action code/container? I guess the behavior you are after is that a cache is populated the first time a particular version of the action is invoked, and the action is responsible for populating the cache? 
    This will require it to be ok that the cache is overwritten by multiple concurrent action invocations - is that ok? Otherwise some external coordination will be required.
    
    Thanks
    Tyson
    
    On 12/3/19, 1:56 AM, "Christophe Jelger" <je...@adobe.com.INVALID> wrote:
    
        Hello,
        
        I just joined the dev list after opened https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Fopenwhisk%2Fpull%2F4761&amp;data=02%7C01%7Ctnorris%40adobe.com%7Cf6bbce97138840d6d3d808d777d713e2%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C1%7C637109637950585977&amp;sdata=NpAWRBdQiBdA%2BUc6YED%2BppFJnVQT31OU4YXF6Dg%2FRn0%3D&amp;reserved=0 : it adds OW_ACTION_VERSION to the execution environment.
        
        I was asked by Rodric to send this email to the list because this change will require extra changes in the runtime repos for tests (see his comment in the PR).
        Since I just joined the list and have until now only been an active user of OpenWhisk, I don’t know what the process is to do that next. Any hint is appreciated.
        
        BR,
        Christophe
        --
        Christophe Jelger | AEM Commerce Developer
        Adobe Research Schweiz AG
        +41 (0)61 226 5792
        
        
    
    


Re: Adding OW_ACTION_VERSION

Posted by Tyson Norris <tn...@adobe.com.INVALID>.
Hi  -
Just to clarify, your examples mention "cache keys" - can you confirm these keys are stored external to the action code/container? I guess the behavior you are after is that a cache is populated the first time a particular version of the action is invoked, and the action is responsible for populating the cache? 
This will require it to be ok that the cache is overwritten by multiple concurrent action invocations - is that ok? Otherwise some external coordination will be required.

Thanks
Tyson

On 12/3/19, 1:56 AM, "Christophe Jelger" <je...@adobe.com.INVALID> wrote:

    Hello,
    
    I just joined the dev list after opened https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Fopenwhisk%2Fpull%2F4761&amp;data=02%7C01%7Ctnorris%40adobe.com%7Cf6bbce97138840d6d3d808d777d713e2%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C1%7C637109637950585977&amp;sdata=NpAWRBdQiBdA%2BUc6YED%2BppFJnVQT31OU4YXF6Dg%2FRn0%3D&amp;reserved=0 : it adds OW_ACTION_VERSION to the execution environment.
    
    I was asked by Rodric to send this email to the list because this change will require extra changes in the runtime repos for tests (see his comment in the PR).
    Since I just joined the list and have until now only been an active user of OpenWhisk, I don’t know what the process is to do that next. Any hint is appreciated.
    
    BR,
    Christophe
    --
    Christophe Jelger | AEM Commerce Developer
    Adobe Research Schweiz AG
    +41 (0)61 226 5792