#1 new docker recipe type
currently we have type:"dockerfile", location: "http://path-to-recipe"
now we could provide
type:"dockerfile", content: "FROM codenvy/foo\nENV FLORENT=TRUE\"
and
type:"image", location or content: "codenvy/foo"
#2 InstanceKey
Up to now, InstanceKey was used to perform snapshot recovery.
But machine source is a way to provide this information.
So remove InstanceKey and replace it by MachineSource (and DockerMachineSource instead of DockerInstanceKey)
InstanceProvider:
void removeInstanceSnapshot(InstanceKey instanceKey)
--> void removeInstanceSnapshot(MachineSource machineSource)
Instance:
InstanceKey saveToSnapshot(String owner)
--> MachineSource saveToSnapshot(String owner)
#3 InstanceProvider model
To avoid also that MachineManager "knows" the inner type, the recipe handling is moved to the instance provider implementation
And as the snapshot handling is with MachineSource (included in MachineConfig included in Machine), no need to give extra InstanceKey parameter
Replace two previous methods
Instance createInstance(Recipe recipe,
Machine machine,
LineConsumer creationLogsOutput)
Instance createInstance(InstanceKey instanceKey,
Machine machine,
LineConsumer creationLogsOutput) throws NotFoundException, InvalidInstanceSnapshotException, MachineException;
by only one:
createInstance(Machine machine,
LineConsumer creationLogsOutput)
Change-Id: Ia7ea97bc1a44059b4892f5db387f54f2e1709fa3
Signed-off-by: Florent BENOIT <fbenoit@codenvy.com>
Discover ssh machines architecture automatically.
Remove beta field in machine conf that provides architecture.
Move server-side classes to appropriate package.
Removed workarounds in ssh client and properly wait until command finishes.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
Add path to wsagent into wsagent server url to avoid doing that on client-side
Add class DevMachine on client-side what contain all needed information for communicate with wsagent and terminal
Remove @Named(cheExtensionPath)
Signed-off-by: Vitaly Parfonov <vparfonov@codenvy.com>
Add field 'path' to machine server conf.
Add fields 'path', 'protocol' to runtime machine server.
Field 'url' of runtime machine server now includes path if path is
not null.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
Machine model changes:
- MachineState was removed, Machine should be used instead
- Machine states API was removed
- Machine includes MachineConfig as field instead of extending it
- All runtime information of machine is in runtime field of Machine.
- Now API call GET */api/machine?workspace=ws-id123456* returns all existing machines of workspace,
including machines with status CREATING, DESTROYING
- Machine channels was removed from. To get channels clients should check links of WorkspaceConfigDto.
Workspace model changes:
- EnvironmentState was removed
- UsersWorkspace includes WorkspaceConfig as field instead of extending it
- Start tmp workspace API returns RuntimeWorkspace instead of UsersWorkspace
- Machine channels are included in links of MachineConfigDto of WorkspaceConfig. Don't try to find them
in runtime machines of RuntimeWorkspaceDto.
- Field activeEnvName in RuntimeWorkspace was renamed to envName in accordance with defaultEnv field
of WorkspaceConfig.
Also:
- add static method cloneDto to DtoFactory
- add getParameter(paramName) method to DTO Link to simplify parameter retrieval
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>