hezean / sustc

Template for project 2 of SUSTech Principles of Database Systems (CS307 / CS213), 23 fall semester.
http://172.18.34.154
MIT License
22 stars 10 forks source link

[Configuration] Configuration Issues with Third-Party Library #60

Closed maxinglo closed 10 months ago

maxinglo commented 10 months ago

Describe your question

During the development process, I utilized the MyBatis library. However, I couldn't figure out how to retrieve the database URL and account credentials from the application.yml file. As a result, I created a separate configuration file named mybatis-config.xml and stored the relevant information there. Would this pose any issues?

hezean commented 10 months ago

actually there's a spring-starter for mybatis that can read jdbc config from application.yml, however, as mentioned below, you are NOT allowed to use mybatis since it's generally considered as an orm.

https://github.com/hezean/sustc/blob/2a596f950bb6b2132eb4f35347a3e61ebd14f168/sustc-api/build.gradle.kts#L17-L18

maxinglo commented 10 months ago

@hezean What would be the consequences if I use MyBatis? Would it result in penalties or a deduction of points? I need to assess whether I should rewrite my entire code.

hezean commented 10 months ago

May I first ask if you were in CS307 or CS213? I'll consult with the corresponding tutor for you.

maxinglo commented 10 months ago

@hezean Professor Cheng Ran's CS307.

sses7757 commented 10 months ago

@maxinglo After consulting TA, our decision is that if you insist using ORM, you will get 50% of your original benchmark score.