-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
폐업 추정 장소 크롤링 구현 #391
base: main
Are you sure you want to change the base?
폐업 추정 장소 크롤링 구현 #391
Conversation
private val crsFactory = CRSFactory() | ||
private val transformFactory = CoordinateTransformFactory() | ||
|
||
private val sourceCrs = crsFactory.createFromParameters(sourceCrsType.wellKnownName, sourceCrsType.proj) | ||
private val targetCrs = crsFactory.createFromParameters(targetCrsType.wellKnownName, targetCrsType.proj) | ||
private val transformer = transformFactory.createTransform(sourceCrs, targetCrs) | ||
|
||
fun toLocation(x: Double, y: Double): Location { | ||
val sourceCoordinate = ProjCoordinate(x, y) | ||
val transformedCoordinate = transformer.transform(sourceCoordinate, ProjCoordinate()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
흔히 알려진 JTS + MathTransform 으로 변환하면 너무 생뚱맞은 좌표가 나와서 proj4j 라는 라이브러리 사용
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[CHECK] 달린 것만 한 번 확인해주세요! 감사합니당
@PrePersist | ||
fun prePersist() { | ||
val now = SccClock.instant() | ||
createdAt = now | ||
updatedAt = now | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
걍 @CreationTimestamp
@UpdateTimestamp` 쓰면 어떤가요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
그 어노테이션이 spring-data-jpa 라이브러리에 포함된 애들인데 stdlib 모듈에는 그게 없어서.. jakarta.persistence 에 있는 어노테이션을 사용했습니다
그냥 spring-data-jpa 를 dependency 로 가져올까요? ㅋㅋㅋ 저는 뭔가 이거 하나 때문에 그거까지 가져와야 하나 싶어서
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
엥 하이버네이트에 포함된 거 아닌가요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
아 넹 hibernate 네요. 그 라이브러리를 stdlib 모듈이 들고 있지 않아서요
여기 저기서 들고 가서 사용하는 stdlib 모듈에 새로운 라이브러리 의존성을 최대한 피할 수 있으면 피하고 싶었던건데 CreationTimestamp 쓰는게 조금 더 깔끔할 것 같기도 하고요..
Checklist
예시 Response