Remove swagger and minor feature extensions and bug fixes
- Various Bug fixes and improvements - Management API extended - Swagger removed - Guava Upgraded to 19
This commit is contained in:
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/ControllerPollProperties.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/ControllerPollProperties.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/DistributedResourceBundleMessageSource.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/DistributedResourceBundleMessageSource.java
Executable file → Normal file
7
hawkbit-core/src/main/java/org/eclipse/hawkbit/api/HostnameResolver.java
Executable file → Normal file
7
hawkbit-core/src/main/java/org/eclipse/hawkbit/api/HostnameResolver.java
Executable file → Normal file
@@ -12,15 +12,14 @@ import java.net.URL;
|
||||
|
||||
/**
|
||||
* Resolve to reach the server url.
|
||||
*
|
||||
*
|
||||
*
|
||||
*/
|
||||
@FunctionalInterface
|
||||
public interface HostnameResolver {
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
URL resolveHostname();
|
||||
|
||||
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/ArtifactRepository.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/ArtifactRepository.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/ArtifactStoreException.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/ArtifactStoreException.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/HashNotMatchException.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/HashNotMatchException.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/model/DbArtifact.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/model/DbArtifact.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/model/DbArtifactHash.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/artifact/repository/model/DbArtifactHash.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/CacheConstants.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/CacheConstants.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/DownloadArtifactCache.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/DownloadArtifactCache.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/DownloadType.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/DownloadType.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/TenancyCacheManager.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/TenancyCacheManager.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/TenantAwareCacheManager.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/cache/TenantAwareCacheManager.java
vendored
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/DeadEventListener.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/DeadEventListener.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/EventBusSubscriberProcessor.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/EventBusSubscriberProcessor.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/EventSubscriber.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/EventSubscriber.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/AbstractDistributedEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/AbstractDistributedEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/CancelTargetAssignmentEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/CancelTargetAssignmentEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/CustomEvents.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/CustomEvents.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/DistributedEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/DistributedEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/DownloadProgressEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/DownloadProgressEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/EntityEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/EntityEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/Event.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/Event.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/NodeAware.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/NodeAware.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/TargetDeletedEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/eventbus/event/TargetDeletedEvent.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/exception/GenericSpServerException.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/exception/GenericSpServerException.java
Executable file → Normal file
46
hawkbit-core/src/main/java/org/eclipse/hawkbit/exception/SpServerError.java
Executable file → Normal file
46
hawkbit-core/src/main/java/org/eclipse/hawkbit/exception/SpServerError.java
Executable file → Normal file
@@ -12,7 +12,7 @@ package org.eclipse.hawkbit.exception;
|
||||
*
|
||||
*
|
||||
*
|
||||
* Define the Error code for Error handling
|
||||
* Define the Error code for Error handling
|
||||
*
|
||||
*/
|
||||
|
||||
@@ -69,8 +69,7 @@ public enum SpServerError {
|
||||
*
|
||||
*/
|
||||
SP_REST_BODY_NOT_READABLE("hawkbit.server.error.rest.body.notReadable",
|
||||
"The given request body is not well formed"), SP_UI_SEARCH("hawkbit.server.error.ui.searchError",
|
||||
"blabla :-)"),
|
||||
"The given request body is not well formed"),
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@@ -113,7 +112,6 @@ public enum SpServerError {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
|
||||
SP_ARTIFACT_LOAD_FAILED("hawkbit.server.error.artifact.loadFailed",
|
||||
"Load of artifact failed with internal server error."),
|
||||
|
||||
@@ -124,26 +122,34 @@ public enum SpServerError {
|
||||
"Too many status entries have been inserted."),
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
*
|
||||
*/
|
||||
SP_ATTRIBUTES_TO_MANY_ENTRIES("hawkbit.server.error.target.attributes.tooManyEntries",
|
||||
"Too many attribute entries have been inserted."),
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
* error message, which describes that the action can not be canceled cause
|
||||
* the action is inactive.
|
||||
*/
|
||||
SP_ACTION_NOT_CANCELABLE("hawkbit.server.error.action.notcancelable",
|
||||
"Only active actions which are in status pending are canceable"),
|
||||
"Only active actions which are in status pending are canceable."),
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
* error message, which describes that the action can not be force quit
|
||||
* cause the action is inactive.
|
||||
*/
|
||||
SP_ACTION_NOT_FORCE_QUITABLE("hawkbit.server.error.action.notforcequitable",
|
||||
"Only active actions which are in status pending can be force quit."),
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
SP_DS_INCOMPLETE("hawkbit.server.error.distributionset.incomplete",
|
||||
"Distribution set is assigned to a a target that is incomplete (i.e. mandatory modules are missing)"),
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
*
|
||||
*/
|
||||
SP_DS_TYPE_UNDEFINED("hawkbit.server.error.distributionset.type.undefined",
|
||||
"Distribution set type is not yet defined. Modules cannot be added until definition."),
|
||||
|
||||
@@ -154,8 +160,8 @@ public enum SpServerError {
|
||||
"Distribution set type does not contain the given module, i.e. is incompatible."),
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
*
|
||||
*/
|
||||
SP_REPO_TENANT_NOT_EXISTS("hawkbit.server.error.repo.tenantNotExists",
|
||||
"The entity cannot be inserted due the tenant does not exists"),
|
||||
|
||||
@@ -181,10 +187,20 @@ public enum SpServerError {
|
||||
this.message = message;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the key of the error
|
||||
*
|
||||
* @return the key of the error
|
||||
*/
|
||||
public String getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the message of the error
|
||||
*
|
||||
* @return message of the error
|
||||
*/
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
|
||||
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/exception/SpServerRtException.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/exception/SpServerRtException.java
Executable file → Normal file
10
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/ActionFields.java
Executable file → Normal file
10
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/ActionFields.java
Executable file → Normal file
@@ -15,7 +15,7 @@ package org.eclipse.hawkbit.repository;
|
||||
*
|
||||
*
|
||||
*/
|
||||
public enum ActionFields implements FieldNameProvider, FieldValueConverter<ActionFields> {
|
||||
public enum ActionFields implements FieldNameProvider,FieldValueConverter<ActionFields> {
|
||||
|
||||
/**
|
||||
* The status field.
|
||||
@@ -51,7 +51,7 @@ public enum ActionFields implements FieldNameProvider, FieldValueConverter<Actio
|
||||
}
|
||||
}
|
||||
|
||||
private Object convertStatusValue(final String value) {
|
||||
private static Object convertStatusValue(final String value) {
|
||||
final String trimmedValue = value.trim();
|
||||
if (trimmedValue.equalsIgnoreCase(ACTIVE)) {
|
||||
return 1;
|
||||
@@ -62,12 +62,6 @@ public enum ActionFields implements FieldNameProvider, FieldValueConverter<Actio
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
*
|
||||
* @see org.eclipse.hawkbit.server.rest.resource.model.FieldValueConverter#
|
||||
* possibleValues(java.lang.Enum)
|
||||
*/
|
||||
@Override
|
||||
public String[] possibleValues(final ActionFields e) {
|
||||
switch (e) {
|
||||
|
||||
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/ActionStatusFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/ActionStatusFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/DistributionSetFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/DistributionSetFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/DistributionSetMetadataFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/DistributionSetMetadataFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/DistributionSetTypeFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/DistributionSetTypeFields.java
Executable file → Normal file
3
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/FieldNameProvider.java
Executable file → Normal file
3
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/FieldNameProvider.java
Executable file → Normal file
@@ -12,10 +12,9 @@ package org.eclipse.hawkbit.repository;
|
||||
* An interface for declaring the name of the field described in the database
|
||||
* which is used as string representation of the field, e.g. for sorting the
|
||||
* fields over REST.
|
||||
*
|
||||
*
|
||||
*
|
||||
*/
|
||||
@FunctionalInterface
|
||||
public interface FieldNameProvider {
|
||||
|
||||
/**
|
||||
|
||||
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/FieldValueConverter.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/FieldValueConverter.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/SoftwareModuleFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/SoftwareModuleFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/SoftwareModuleMetadataFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/SoftwareModuleMetadataFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/SoftwareModuleTypeFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/SoftwareModuleTypeFields.java
Executable file → Normal file
@@ -0,0 +1,40 @@
|
||||
/**
|
||||
* Copyright (c) 2015 Bosch Software Innovations GmbH and others.
|
||||
*
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*/
|
||||
package org.eclipse.hawkbit.repository;
|
||||
|
||||
/**
|
||||
* Describing the fields of the Tag model which can be used in the REST API e.g.
|
||||
* for sorting etc.
|
||||
*
|
||||
*/
|
||||
public enum TagFields implements FieldNameProvider {
|
||||
/**
|
||||
* The name field.
|
||||
*/
|
||||
NAME("name"),
|
||||
/**
|
||||
* The description field.
|
||||
*/
|
||||
DESCRIPTION("description"),
|
||||
/**
|
||||
* The controllerId field.
|
||||
*/
|
||||
COLOUR("colour");
|
||||
|
||||
private final String fieldName;
|
||||
|
||||
private TagFields(final String fieldName) {
|
||||
this.fieldName = fieldName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getFieldName() {
|
||||
return fieldName;
|
||||
}
|
||||
}
|
||||
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/TargetFields.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/repository/TargetFields.java
Executable file → Normal file
11
hawkbit-core/src/main/java/org/eclipse/hawkbit/tenancy/TenantAware.java
Executable file → Normal file
11
hawkbit-core/src/main/java/org/eclipse/hawkbit/tenancy/TenantAware.java
Executable file → Normal file
@@ -10,7 +10,7 @@ package org.eclipse.hawkbit.tenancy;
|
||||
|
||||
/**
|
||||
* Interface for components that are aware of the application's current tenant.
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
@@ -20,7 +20,7 @@ public interface TenantAware {
|
||||
/**
|
||||
* Implementation might retrieve the current tenant from a session or
|
||||
* thread-local.
|
||||
*
|
||||
*
|
||||
* @return the current tenant
|
||||
*/
|
||||
String getCurrentTenant();
|
||||
@@ -31,7 +31,7 @@ public interface TenantAware {
|
||||
* specific tenant e.g. under control of an {@link ThreadLocal}. After the
|
||||
* {@link TenantRunner} it must be ensured that the original tenant before
|
||||
* this invocation is reset.
|
||||
*
|
||||
*
|
||||
* @param tenant
|
||||
* the tenant which the specific code should run
|
||||
* @param tenantRunner
|
||||
@@ -47,17 +47,18 @@ public interface TenantAware {
|
||||
* An {@link TenantRunner} interface which allows to run specific code under
|
||||
* a given tenant by using the
|
||||
* {@link TenantAware#runAsTenant(String, TenantRunner)}.
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
* @param <T>
|
||||
* the return type of the runner
|
||||
*/
|
||||
@FunctionalInterface
|
||||
interface TenantRunner<T> {
|
||||
/**
|
||||
* Called to run specific code and a given tenant.
|
||||
*
|
||||
*
|
||||
* @return the return of the code block running under a certain tenant
|
||||
*/
|
||||
T run();
|
||||
|
||||
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/tenancy/configuration/TenantConfigurationKey.java
Executable file → Normal file
0
hawkbit-core/src/main/java/org/eclipse/hawkbit/tenancy/configuration/TenantConfigurationKey.java
Executable file → Normal file
Reference in New Issue
Block a user