Skip to content

Commit c0197c1

Browse files
committed
Restructured the routing team code slightly
1 parent 41f76db commit c0197c1

File tree

6 files changed

+4
-47
lines changed

6 files changed

+4
-47
lines changed

dddsample/src/main/java/se/citerus/dddsample/application/routing/ExternalRoutingService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ public List<Itinerary> fetchRoutesForSpecification(RouteSpecification routeSpeci
3434
final Location origin = routeSpecification.origin();
3535
final Location destination = routeSpecification.destination();
3636

37-
final List<TransitPath> transitPaths = graphTraversalService.performHeavyCalculations(
37+
final List<TransitPath> transitPaths = graphTraversalService.findShortestPath(
3838
origin.unLocode().idString(),
3939
destination.unLocode().idString()
4040
);

dddsample/src/main/java/se/citerus/routingteam/GraphDAO.java

Lines changed: 0 additions & 43 deletions
This file was deleted.

dddsample/src/main/java/se/citerus/routingteam/GraphTraversalService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
*/
1010
public interface GraphTraversalService {
1111

12-
List<TransitPath> performHeavyCalculations(String originUnLocode, String destinationUnLocode);
12+
List<TransitPath> findShortestPath(String originUnLocode, String destinationUnLocode);
1313

1414
}

dddsample/src/main/java/se/citerus/routingteam/internal/GraphTraversalServiceImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public GraphTraversalServiceImpl(GraphDAO dao) {
1616
this.random = new Random();
1717
}
1818

19-
public List<TransitPath> performHeavyCalculations(String originUnLocode, String destinationUnLocode) {
19+
public List<TransitPath> findShortestPath(String originUnLocode, String destinationUnLocode) {
2020
List<String> allVertices = dao.listLocations();
2121
allVertices.remove(originUnLocode);
2222
allVertices.remove(destinationUnLocode);
File renamed without changes.

dddsample/src/main/webapp/WEB-INF/web.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
classpath:context-messaging-jms.xml
2929

3030
classpath:context-service.xml
31-
classpath:context-routing.xml
31+
classpath:context-routingteam.xml
3232
classpath:context-remote.xml
3333
classpath:context-web.xml
3434
</param-value>

0 commit comments

Comments
 (0)