Table of content



The Airport entity within the microservice architecture

Entity-Relationship-Model of <AirportService>

Entity Name: Airport

Data Schema: AirportLogistics

Master Service: AirportService


Dataflow of entity of Airport

Microservices

3.1 AirplaneService3.2 AirportService3.3 CargoService3.4 CountryService3.5 EmployeeService3.6 LuggageService
3.7 PassengerBookingService

Entity Properties

Property NameDatatypeData EntityReference Entity
AirportNameSTRINGAirport
CityLONGAirportCity
PrimaryKeyLONGAirport
ServerReplicationVersionLONGAirport

Service Interfaces

Relative mapping URLRequest MethodMethod NameMicroserviceInvolved Entities
/flightroute/destination/{id}GETfindAllFlightRouteOfDestination(id)AirportServiceAirport FlightRoute
/airport/city/{id}GETfindAllAirportOfCity(id)AirportServiceCity Airport
/terminal/airport/{id}GETfindAllTerminalOfAirport(id)AirportServiceAirport Terminal
/flightroute/source/{id}GETfindAllFlightRouteOfSource(id)AirportServiceAirport FlightRoute
/airportGETfindAllAirport()AirportServiceAirport
/airport/{id}DELETEdeleteAirportById(id)AirportServiceAirport
/airportPOSTinsertAirport(airport)AirportServiceAirport
/airport/{id}GETfindAirportById(id)AirportServiceAirport
/airport/{id}PUTupdateAirportById(airport)AirportServiceAirport

Distributed transaction of <Airport>

Pseudo code snippet

final Airport airport = (Airport) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/airport/" + id, Airport.class);
if (airport != null) {
    final City city1 = (City) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/city/" + airport.getCity().getId(), City.class);
    if (city1 != null) {
        final Country country2 = (Country) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/country/" + city1.getCountry().getId(), Country.class);
        if (country2 != null) {
        }
    }
}
return airport;


Table of content