forked from eclipse-hono/hono-extras
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[#19] Enhance device communication API
* added support for device states * added automatic Pub/Sub tenant topic & subscription creation and deletion * added automatically sending of a config in case a config is requested or a new one created * extended config table with error field Signed-off-by: Matthias Kaemmer <[email protected]>
- Loading branch information
Showing
44 changed files
with
2,828 additions
and
341 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
...unication/src/main/java/org/eclipse/hono/communication/api/config/ApiCommonConstants.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
/* | ||
* *********************************************************** | ||
* Copyright (c) 2023 Contributors to the Eclipse Foundation | ||
* <p> | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information regarding copyright ownership. | ||
* <p> | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* <p> | ||
* SPDX-License-Identifier: EPL-2.0 | ||
* ********************************************************** | ||
* | ||
*/ | ||
|
||
package org.eclipse.hono.communication.api.config; | ||
|
||
/** | ||
* Device constant values. | ||
*/ | ||
public final class ApiCommonConstants { | ||
|
||
/** | ||
* Path parameter name for tenantId. | ||
*/ | ||
public static final String TENANT_PATH_PARAMS = "tenantid"; | ||
/** | ||
* Path parameter name for deviceId. | ||
*/ | ||
public static final String DEVICE_PATH_PARAMS = "deviceid"; | ||
|
||
private ApiCommonConstants() { | ||
// avoid instantiation | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
...cation/src/main/java/org/eclipse/hono/communication/api/config/DeviceStatesConstants.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* *********************************************************** | ||
* Copyright (c) 2023 Contributors to the Eclipse Foundation | ||
* <p> | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information regarding copyright ownership. | ||
* <p> | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* <p> | ||
* SPDX-License-Identifier: EPL-2.0 | ||
* ********************************************************** | ||
* | ||
*/ | ||
|
||
package org.eclipse.hono.communication.api.config; | ||
|
||
/** | ||
* Device states constant values. | ||
*/ | ||
public final class DeviceStatesConstants { | ||
|
||
public static ApiCommonConstants API_COMMON; | ||
/** | ||
* OpenApi GET device states operation id. | ||
*/ | ||
public static final String LIST_STATES_OP_ID = "listStates"; | ||
/** | ||
* Path parameter name for number of states. | ||
*/ | ||
|
||
public static final String NUM_STATES_QUERY_PARAMS = "numStates"; | ||
/** | ||
* Sql migrations script path. | ||
*/ | ||
public static final String CREATE_SQL_SCRIPT_PATH = "db/v1_create_state_table.sql"; | ||
|
||
private DeviceStatesConstants() { | ||
// avoid instantiation | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.