This repository has been archived by the owner on Apr 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feature/support multiple notification urls (#24)
* Added tenant support to Fiware integration services Implemented tenant support in Fiware integration services to organize resources and provide resource isolation. Integrated this implementation into the existing test suites. Made necessary amendments to the corresponding test resources and instantiated services with the tenant parameter. Removed StatusServiceIT test file as the functionality is covered in DeviceIntegrationServiceBasedOnTenantIT. * Update version in pom.xml file Bumped up the version from 5.4.0 to 6.0.0 in pom.xml. This Version change reflects the recent updates made to the project, including the implementation of tenant support in Fiware integration services for resource organization and isolation. As part of these updates, also made necessary changes to the corresponding test resources and services. * Add CustomHeader for tenant identification in Fiware API calls Introduced a 'CustomHeader' interface which standardizes the use of the 'fiware-service' HTTP header across the application. It improves code consistency, reduces potential human error and enhances code readability. This header carries the identity of the tenant(service) and eases resource coordination in multi-tenancy environments. Changes are made in the AbstractEntityIntegrationService and SubscriptionService classes, where the header is being added to the HTTP requests. * Update tests for the usage of contextBrokerUrl and tenant Refactored some integration tests so that instead of hard-coding the strings for the contextBrokerUrl and tenant, they're now using values from a superclass (AbstractIT). This helps to avoid redundancy, reduces the risk of inconsistencies across tests and increases code maintainability. * Format. * Remove duplicate header in SubscriptionService A header for FIWARE_SERVICE was duplicated in the SubscriptionService class. This duplication added no functional value and could potentially cause confusion or issues in future development. The unnecessary line has been removed for cleaner, more efficient code.
- Loading branch information
1 parent
34235d4
commit 9b932b9
Showing
7 changed files
with
80 additions
and
58 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
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,14 @@ | ||
package de.app.fivegla.fiware; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
* This class is an abstract base class for IT (Integration Testing) classes. | ||
* It provides common properties and methods that can be used by concrete IT classes. | ||
*/ | ||
public class AbstractIT { | ||
protected String contextBrokerUrl = "http://localhost:1026"; | ||
protected String tenant = "default"; | ||
protected List<String> notificationUrls = List.of("http://192.168.56.1:5055/notify"); | ||
|
||
} |
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
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
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