Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support array result include sequence action #65

Conversation

ningyougang
Copy link
Contributor

Depend on below prs:

@ningyougang
Copy link
Contributor Author

Steps of test support sequence action

  • Write Split.cs and Sort.cs
using System;
using Newtonsoft.Json.Linq;

namespace Apache.OpenWhisk.Example.Dotnet
{
    public class Split
    {
        public JArray Main(JObject args)
        {
            JArray jarray = new JArray();
            jarray.Add("e1");
            jarray.Add("e2");
            // use Jarray param as next action's input param
            return (jarray);
        }
    }
}

using System;
using Newtonsoft.Json.Linq;

namespace Apache.OpenWhisk.Example.Dotnet
{
    public class Sort
    {
        public JArray Main(JArray args)
        {
            // Don't do real sort operation, just return Jarray direclty, don't do real split operation
            return (args);
        }
    }
}
wsk -i action update /whisk.system/utils/splitDotNet splitDotNet.zip --main Apache.OpenWhisk.Example.Dotnet::Apache.OpenWhisk.Example.Dotnet.Split::Main --kind dotnet:2.2
wsk -i action update /whisk.system/utils/sortDotNet sortDotNet.zip --main Apache.OpenWhisk.Example.Dotnet::Apache.OpenWhisk.Example.Dotnet.Sort::Main --kind dotnet:2.2
wsk -i action create mySequence-dotnet --sequence /whisk.system/utils/splitDotNet,/whisk.system/utils/sortDotNet 
wsk -i action invoke --result mySequence-dotnet -r -v

@ningyougang ningyougang force-pushed the support-array-result-include-sequence-action branch from b5c1672 to 1749da4 Compare August 8, 2022 06:52
Copy link
Member

@dgrove-oss dgrove-oss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ningyougang ningyougang merged commit 24995db into apache:master Aug 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants