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

Provide links of the workspace to the client #5581

Closed
akorneta opened this issue Jul 10, 2017 · 3 comments
Closed

Provide links of the workspace to the client #5581

akorneta opened this issue Jul 10, 2017 · 3 comments
Assignees
Labels
target/branch Indicates that a PR will be merged into a branch other than master.

Comments

@akorneta
Copy link
Contributor

akorneta commented Jul 10, 2017

We already have at least two endpoints which may be useful for clients:
output endpoint
workspace status endpoint
So we need to rework our workspace links injector in accordance with client`s needs and changes in spi branch.
Note that the set of endpoints may expand.
We also want to simplify Links model. It is supposed to be done as a part of this issue.
The current model is complicated and, lately, we used to use it in the simplest use cases only. So we decided to simplify it significantly.
The current model of an object that contains links is:

{
    "field1" : "",
    "links" : [
        {
            "href" : "http://some-server.com:9090/path1/path2",
            "rel" : "myserver.api",
            "method" : "GET",
            "produces" : "application/json",
            "consumes" : "application/json",
            "parameters" : [
                {
                    "name" : "parameterName",
                    "defaultValue" : "defvalue1",
                    "description" : "Some user-friendly description",
                    "type" : "string",
                    "required" : true,
                    "valid" : [
                        "valid1",
                        "valid2",
                    ]
                }
            ],
            "requestBody" : {
                "description" : "body user-friendly description"
            }
        }
    ]
}

and the new model would be:

{
    "field1" : "",
    "links" : {
        "myserver.api" : "http://some-server.com:9090/path1/path2",
        "anotherserver.api" : "http://another-server.com",
    }
}
@akorneta akorneta added the target/branch Indicates that a PR will be merged into a branch other than master. label Jul 10, 2017
@akorneta akorneta self-assigned this Jul 10, 2017
@garagatyi
Copy link

I've updated description of this issue to extend its DoD with links model simplification

@gazarenkov
Copy link
Contributor

Let's also take seriously the name convention for the links and servers.
Before we our naming was rather random.
Does that make sense to consider the ["namespace"]/"name" pattern (both names - camel-cased)?

@garagatyi
Copy link

I think it is OK - then it will be similar to JSON_RPC method naming

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
target/branch Indicates that a PR will be merged into a branch other than master.
Projects
None yet
Development

No branches or pull requests

4 participants