currently refactoring a lot
This commit is contained in:
parent
a32805a623
commit
700b5d5d10
20 changed files with 406 additions and 292 deletions
|
|
@ -1,23 +1,23 @@
|
|||
package de.kentoj.scrowlib.servermanager;
|
||||
|
||||
import com.leakyabstractions.result.api.Result;
|
||||
import org.jspecify.annotations.Nullable;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface InstanceManager {
|
||||
|
||||
/**
|
||||
* @return Mono with handle of deployed server
|
||||
*/
|
||||
Result<ServerInstance, String> deployInstance(String template);
|
||||
ServerInstance deployInstance(String template);
|
||||
|
||||
Result<Object, String> destroyInstance(String handle);
|
||||
/**
|
||||
* @return if the instance was found
|
||||
*/
|
||||
boolean destroyInstance(String handle);
|
||||
|
||||
/**
|
||||
* @return Flux with handles of running servers
|
||||
*/
|
||||
Result<List<ServerInstance>, String> getInstances();
|
||||
List<ServerInstance> getInstances();
|
||||
|
||||
Result<@Nullable ServerInstance, String> getInstance(String handle);
|
||||
@Nullable
|
||||
ServerInstance getInstance(String handle);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue