Class DefaultCloudServiceFactory
- java.lang.Object
-
- de.dytanic.cloudnet.driver.provider.service.DefaultCloudServiceFactory
-
- All Implemented Interfaces:
CloudServiceFactory
- Direct Known Subclasses:
RemoteCloudServiceFactory
public abstract class DefaultCloudServiceFactory extends java.lang.Object implements CloudServiceFactory
-
-
Constructor Summary
Constructors Constructor Description DefaultCloudServiceFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @Nullable ServiceInfoSnapshotcreateCloudService(ServiceTask serviceTask)Creates and prepares a new cloud service@Nullable ServiceInfoSnapshotcreateCloudService(ServiceTask serviceTask, int taskId)Creates and prepares a new cloud service@Nullable java.util.Collection<ServiceInfoSnapshot>createCloudService(java.lang.String nodeUniqueId, int amount, java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)Creates and prepares a new cloud service@Nullable ServiceInfoSnapshotcreateCloudService(java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)Creates and prepares a new cloud service@NotNull de.dytanic.cloudnet.common.concurrent.ITask<ServiceInfoSnapshot>createCloudServiceAsync(ServiceTask serviceTask)Creates and prepares a new cloud service@NotNull de.dytanic.cloudnet.common.concurrent.ITask<ServiceInfoSnapshot>createCloudServiceAsync(ServiceTask serviceTask, int taskId)Creates and prepares a new cloud service@NotNull de.dytanic.cloudnet.common.concurrent.ITask<java.util.Collection<ServiceInfoSnapshot>>createCloudServiceAsync(java.lang.String nodeUniqueId, int amount, java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)Creates and prepares a new cloud service@NotNull de.dytanic.cloudnet.common.concurrent.ITask<ServiceInfoSnapshot>createCloudServiceAsync(java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)Creates and prepares a new cloud service-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface de.dytanic.cloudnet.driver.provider.service.CloudServiceFactory
createCloudService, createCloudService, createCloudService, createCloudServiceAsync, createCloudServiceAsync, createCloudServiceAsync
-
-
-
-
Method Detail
-
createCloudService
@Nullable public @Nullable ServiceInfoSnapshot createCloudService(ServiceTask serviceTask)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServicein interfaceCloudServiceFactory- Parameters:
serviceTask- the task the service should be created from- Returns:
- the info of the created service or null if the service couldn't be created
-
createCloudService
@Nullable public @Nullable ServiceInfoSnapshot createCloudService(ServiceTask serviceTask, int taskId)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServicein interfaceCloudServiceFactory- Parameters:
serviceTask- the task the service should be created fromtaskId- the id of the service- Returns:
- the info of the created service or null if the service couldn't be created
-
createCloudService
@Nullable public @Nullable ServiceInfoSnapshot createCloudService(java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServicein interfaceCloudServiceFactory- Parameters:
name- the name of the task of the new cloud service (the name of the service will be name-id)runtime- the runtime of the new cloud service (normally this is "jvm")autoDeleteOnStop- should the service be automatically deleted on stop?staticService- should the service be a static one?includes- the additional files that should be included when preparing the servicetemplates- the templates that should be included when preparing the servicedeployments- the deployments that should be added to the service by defaultgroups- the groups for the serviceprocessConfiguration- the process configuration for the serviceproperties- the properties for the service (those are not used by the cloud, you can define whatever you want as the properties)port- the port of the service- Returns:
- the info of the created service or null if the service couldn't be created
-
createCloudService
@Nullable public @Nullable java.util.Collection<ServiceInfoSnapshot> createCloudService(java.lang.String nodeUniqueId, int amount, java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServicein interfaceCloudServiceFactory- Parameters:
nodeUniqueId- the uniqueId of the node where the services should be started onamount- the amount of services to be createdname- the name of the task of the new cloud services (the name of the service will be name-id)runtime- the runtime of the new cloud services (normally this is "jvm")autoDeleteOnStop- should the services be automatically deleted on stop?staticService- should the services be a static one?includes- the additional files that should be included when preparing the servicestemplates- the templates that should be included when preparing the servicesdeployments- the deployments that should be added to the services by defaultgroups- the groups for the servicesprocessConfiguration- the process configuration for the servicesproperties- the properties for the services (those are not used by the cloud, you can define whatever you want as the properties)port- the port of the services- Returns:
- the info of the created service or null if the service couldn't be created
-
createCloudServiceAsync
@NotNull public @NotNull de.dytanic.cloudnet.common.concurrent.ITask<ServiceInfoSnapshot> createCloudServiceAsync(ServiceTask serviceTask)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServiceAsyncin interfaceCloudServiceFactory- Parameters:
serviceTask- the task the service should be created from- Returns:
- the info of the created service or null if the service couldn't be created
-
createCloudServiceAsync
@NotNull public @NotNull de.dytanic.cloudnet.common.concurrent.ITask<ServiceInfoSnapshot> createCloudServiceAsync(ServiceTask serviceTask, int taskId)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServiceAsyncin interfaceCloudServiceFactory- Parameters:
serviceTask- the task the service should be created fromtaskId- the id of the service- Returns:
- the info of the created service or null if the service couldn't be created
-
createCloudServiceAsync
@NotNull public @NotNull de.dytanic.cloudnet.common.concurrent.ITask<ServiceInfoSnapshot> createCloudServiceAsync(java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServiceAsyncin interfaceCloudServiceFactory- Parameters:
name- the name of the task of the new cloud service (the name of the service will be name-id)runtime- the runtime of the new cloud service (normally this is "jvm")autoDeleteOnStop- should the service be automatically deleted on stop?staticService- should the service be a static one?includes- the additional files that should be included when preparing the servicetemplates- the templates that should be included when preparing the servicedeployments- the deployments that should be added to the service by defaultgroups- the groups for the serviceprocessConfiguration- the process configuration for the serviceport- the port of the service- Returns:
- the info of the created service or null if the service couldn't be created
-
createCloudServiceAsync
@NotNull public @NotNull de.dytanic.cloudnet.common.concurrent.ITask<java.util.Collection<ServiceInfoSnapshot>> createCloudServiceAsync(java.lang.String nodeUniqueId, int amount, java.lang.String name, java.lang.String runtime, boolean autoDeleteOnStop, boolean staticService, java.util.Collection<ServiceRemoteInclusion> includes, java.util.Collection<ServiceTemplate> templates, java.util.Collection<ServiceDeployment> deployments, java.util.Collection<java.lang.String> groups, ProcessConfiguration processConfiguration, de.dytanic.cloudnet.common.document.gson.JsonDocument properties, java.lang.Integer port)
Description copied from interface:CloudServiceFactoryCreates and prepares a new cloud service- Specified by:
createCloudServiceAsyncin interfaceCloudServiceFactoryname- the name of the task of the new cloud service (the name of the service will be name-id)runtime- the runtime of the new cloud service (normally this is "jvm")autoDeleteOnStop- should the service be automatically deleted on stop?staticService- should the service be a static one?includes- the additional files that should be included when preparing the servicetemplates- the templates that should be included when preparing the servicedeployments- the deployments that should be added to the service by defaultgroups- the groups for the serviceprocessConfiguration- the process configuration for the serviceproperties- the properties for the service (those are not used by the cloud, you can define whatever you want as the properties)port- the port of the service- Returns:
- the info of the created service or null if the service couldn't be created
-
-