I1.1.3 Develop a CourseMan prototype to demonstrate MSA (jda-eg-coursemanmsa)
Opened this issue · 16 comments
Example: jda-eg-coursemanmdsa
Develop a CourseMan prototype to demonstrate MSA (to be reused later for developing MOSA+).
@jdomainapp/dev-all @haworker25
Example jda-eg-coursemanmsa
: added ReadMe.md & initial resources
13/3/2022:
- Implemented code in first 6 chapters of the book "Spring Microservices in Action"
- Todo: (meeting time: 14:00 Friday afternoon)
- implement next 3 chapters of the book (7,8,10)
- migrate MOSAR controller/service API to the current project.
- implement all the migrated API methods using Spring's features (keeping the same API interface)
jda-eg-coursemanmsa
: updated with modules containing child projects
- implement next 3 chapters of the book (7,8,10) -> finished
- jda-eg-coursemanmsa: updated with modules containing child projects -> finished on local, hasn't commit git yet
implement next 3 chapters of the book (7,8,10) -> finished
- jda-eg-coursemanmsa: updated with modules containing child projects -> finished on local, hasn't commit git yet
Todo:
jda-eg-coursemanmsa
: complete use Case 1 by next Friday - 15/04 (with all code checked into the main branch)- Meeting time: changed to 14:30
implement next 3 chapters of the book (7,8,10) -> finished
- jda-eg-coursemanmsa: updated with modules containing child projects -> finished on local, hasn't commit git yet
Todo:
jda-eg-coursemanmsa
: complete use Case 1 by next Friday - 15/04 (with all code checked into the main branch)- Meeting time: changed to 14:30
@haworker25 Please report your update on this
Description
- Demo Use case 1: ok
Todo
Use case 1
- improve service implementation with the 3 TODO tasks in the code
- CourseModuleService: support querying subtype object (e.g.
.../compulsorymodule/1
) - checkin source code into folder:
jda-eg-coursemanmsa/ucase1
- write
ReadMe.md
(used as report) - migrate the missing service API functions from MOSAR to each service
Use case 2
- Implement Usecase 2: source code folder:
jda-eg-coursemanmsa/ucase2
11/5/2022
Description
- improve service implementation with the 3 TODO tasks in the code: fininshed 2 TODO tasks
- CourseModuleService: support querying subtype object (e.g. .../compulsorymodule/1): finished
- checkin source code into folder: jda-eg-coursemanmsa/ucase1: just checkin source code to old folder
- write ReadMe.md (used as report): not finshed yet
- migrate the missing service API functions from MOSAR to each service: finished, 1 TODO task
TODO:
- finish ucase 1
- finish ucase 2: ucase 1 + EnrolmentAdministration
- add documentation via ReadMe.md file.
20/5/2022
Progress description
- finish ucase 1 -> finished
- finish ucase 2: ucase 1 + EnrolmentAdministration -> finished v1.0 (academic service forwards request to enrolment service for get/update)
Todo
- ucase 2: version 2.0: academic service to store and update enrolment's marks and final grade. Enrolment service does not store these.
- ReadMe.md: add documentation
- issue #43: make a plan and start working
- usecase 2: finished
- readMe.md : added Usage instructions
27/5/2022
ReadMe.md
ReadMe.md
: update to be like a Technical Report
- Add
mvn install
, if needed - Describe each service (one per subsection) for both use cases
- Add a screenshot for each run command
- Describe PostMan and how to write a query on the services (use screenshots to illustrate)
- add screenshots of the output (Eclipse and/or Postman)
Use case 2:
- how to query EnrolmentAdministration and AcademicAdministration to obtain full Enrolment details (i.e. student, course module, marks, grade)?
- Error fixed: 493ff3e
- Compilation error:
jda> mvn clean install -DskipTests
Error running mvn clean install
:
A longer error log segment (there are many more on the console)
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ student-service ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 27 source files to /data/projects/jda/examples/courseman/msa/modules/services/student-service/target/classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/CustomChannels.java:[3,51] package org.springframework.cloud.stream.annotation does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[3,14] package lombok does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[4,14] package lombok does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[5,14] package lombok does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[7,2] cannot find symbol
symbol: class Getter
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[7,10] cannot find symbol
symbol: class Setter
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[7,18] cannot find symbol
symbol: class ToString
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/handler/ChangeHandler.java:[18,51] package org.springframework.cloud.stream.annotation does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/handler/ChangeHandler.java:[19,51] package org.springframework.cloud.stream.annotation does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/handler/ChangeHandler.java:[21,2] cannot find symbol
symbol: class EnableBinding
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[14,39] package org.springframework.data.domain does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[15,39] package org.springframework.data.domain does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[17,50] package org.springframework.transaction.annotation does not exist
[ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[20,2] cannot find symbol
symbol: class Transactional
...
- Error fixed: 493ff3e
- Compilation error:
jda> mvn clean install -DskipTests
Error running
mvn clean install
:A longer error log segment (there are many more on the console)
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ student-service --- [INFO] Changes detected - recompiling the module! [INFO] Compiling 27 source files to /data/projects/jda/examples/courseman/msa/modules/services/student-service/target/classes [INFO] ------------------------------------------------------------- [ERROR] COMPILATION ERROR : [INFO] ------------------------------------------------------------- [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/CustomChannels.java:[3,51] package org.springframework.cloud.stream.annotation does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[3,14] package lombok does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[4,14] package lombok does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[5,14] package lombok does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[7,2] cannot find symbol symbol: class Getter [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[7,10] cannot find symbol symbol: class Setter [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/model/SourceChangeModel.java:[7,18] cannot find symbol symbol: class ToString [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/handler/ChangeHandler.java:[18,51] package org.springframework.cloud.stream.annotation does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/handler/ChangeHandler.java:[19,51] package org.springframework.cloud.stream.annotation does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/events/handler/ChangeHandler.java:[21,2] cannot find symbol symbol: class EnableBinding [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[14,39] package org.springframework.data.domain does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[15,39] package org.springframework.data.domain does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[17,50] package org.springframework.transaction.annotation does not exist [ERROR] /data/projects/jda/examples/courseman/msa/modules/services/student-service/src/main/java/org/jda/example/coursemanmsa/student/service/AddressService.java:[20,2] cannot find symbol symbol: class Transactional ...
Install project Lombok on Eclipse: https://www.baeldung.com/lombok-ide
@haworker25
Todo:
- Refactor shared code into a separate project. Include this project into dependencies in the pom.xml of MSA-related projects.
Details:
- Move shared MSA-related classes/packages to module
jda-msacommon
(jda/modules
):
Examplesrc
directory structure: - config
- event
- model
- controller
- messaging (put Kafka stuff here)
- exception
- ...
@haworker25
Issues:
- Error: path matching from CourseMgnt down to the submodules is wrong (FIXED)
- Improve path matching pattern so that it does not match with the ancestor module names
- Error: Enrolment, Teacher, CourseModule objects created on CourseMmgt not synchnorised to AssessmentHub
- Missing FinanceHub
- ControllerTk.parseDomainID: to generalise by using DSM to parse domain id value
@haworker25
Features:
- (Duc) define TASL in JDA
- (Duc & Ha) build Service-Generator (using TASL)
- (Duc & Ha) develop service promotion & demotion:
- how to start a service in real-time (i.e. without using the command line).
A parent service (e.g. AcademicAdministration) receives the code of a service S (e.g. CourseModuleManagement) and runs S in realtime. The code is sent over the network from the another service (e.g. CourseManagement). - ...
- how to start a service in real-time (i.e. without using the command line).