-
Notifications
You must be signed in to change notification settings - Fork 1
[FEAT] 알람 스키마 변경/마이그레이션 및 database 모듈 분리 #230
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
Merged
DongChyeon
merged 15 commits into
develop
from
feat/#227-alarm-db-migration-module-split
Jul 12, 2025
Merged
Changes from 13 commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
bfaa787
[FEAT/#227] AlarmEntity missionType(enum-int), missionCount column 추가
DongChyeon b5d85a5
[FEAT/#227] 변경된 missionType(enum-int) 에 따른 수정
DongChyeon 6bbf6dc
[FEAT/#227] core:database 분리
DongChyeon e04fc63
[FEAT/#227] DatabaseMigration 정의
DongChyeon be11d14
[FEAT/#227] 이미지 저장 기능 core:media 모듈로 이전
DongChyeon 4d82cd4
[REFACTOR/#227] ApiCallUtils, ApiError을 core:network 모듈로 이전
DongChyeon f4c12b3
[REFACTOR/#227] safeApiCall try-catch 구조로 리팩토링 및 CancellationExceptio…
DongChyeon 9efdcaf
[CHORE/#227] 사용하지 않는 라이브러리 제거 및 room-testing 라이브러리 추가
DongChyeon 1a60d25
[CHORE/#227] 테스트 설정 함수 분리 및 JUnit Android 설정 통합
DongChyeon 3e42d61
[FEAT/#227] Room Migration 1->2 테스트 코드 추가
DongChyeon bb07d3c
[CHORE/#227] api -> implementation 의존성 수정
DongChyeon f8f4a4b
[FEAT/#227] MissionTypeConverter에서 잘못된 missionType 문자열 파싱
DongChyeon e69cd5f
[FIX/#227] return 구문 중첩 오류 수정 및 메소드명 수정
DongChyeon 046dff7
[FIX/#227] MissionTypeConverter Int <-> MissionType 변환으로 수정
DongChyeon 67455bd
[RENAME/#227] 마이그레이션 테스트 함수 이름 변경
DongChyeon File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| /build |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| import com.yapp.convention.setNamespace | ||
|
|
||
| plugins { | ||
| id("orbit.android.library") | ||
| id("androidx.room") | ||
| } | ||
|
|
||
| android { | ||
| setNamespace("core.database") | ||
|
|
||
| sourceSets { getByName("androidTest").assets.srcDir("$projectDir/schemas") } | ||
| } | ||
|
|
||
| room { | ||
| schemaDirectory("$projectDir/schemas") | ||
| } | ||
|
|
||
| dependencies { | ||
| implementation(projects.domain) | ||
|
|
||
| ksp(libs.androidx.room.compiler) | ||
| implementation(libs.androidx.room.ktx) | ||
| implementation(libs.androidx.room.runtime) | ||
|
|
||
| androidTestImplementation(libs.androidx.room.testing) | ||
| } |
Empty file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| # Add project specific ProGuard rules here. | ||
| # You can control the set of applied configuration files using the | ||
| # proguardFiles setting in build.gradle. | ||
| # | ||
| # For more details, see | ||
| # http://developer.android.com/guide/developing/tools/proguard.html | ||
|
|
||
| # If your project uses WebView with JS, uncomment the following | ||
| # and specify the fully qualified class name to the JavaScript interface | ||
| # class: | ||
| #-keepclassmembers class fqcn.of.javascript.interface.for.webview { | ||
| # public *; | ||
| #} | ||
|
|
||
| # Uncomment this to preserve the line number information for | ||
| # debugging stack traces. | ||
| #-keepattributes SourceFile,LineNumberTable | ||
|
|
||
| # If you keep the line number information, uncomment this to | ||
| # hide the original source file name. | ||
| #-renamesourcefileattribute SourceFile |
118 changes: 118 additions & 0 deletions
118
core/database/schemas/com.yapp.database.AlarmDatabase/1.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,118 @@ | ||
| { | ||
| "formatVersion": 1, | ||
| "database": { | ||
| "version": 1, | ||
| "identityHash": "d9643e982a8885da158bcd94c55931ff", | ||
| "entities": [ | ||
| { | ||
| "tableName": "alarm_database", | ||
| "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `isAm` INTEGER NOT NULL, `hour` INTEGER NOT NULL, `minute` INTEGER NOT NULL, `second` INTEGER NOT NULL, `repeatDays` INTEGER NOT NULL, `isHolidayAlarmOff` INTEGER NOT NULL, `isSnoozeEnabled` INTEGER NOT NULL, `snoozeInterval` INTEGER NOT NULL, `snoozeCount` INTEGER NOT NULL, `isVibrationEnabled` INTEGER NOT NULL, `isSoundEnabled` INTEGER NOT NULL, `soundUri` TEXT NOT NULL, `soundVolume` INTEGER NOT NULL, `isAlarmActive` INTEGER NOT NULL)", | ||
| "fields": [ | ||
| { | ||
| "fieldPath": "id", | ||
| "columnName": "id", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isAm", | ||
| "columnName": "isAm", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "hour", | ||
| "columnName": "hour", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "minute", | ||
| "columnName": "minute", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "second", | ||
| "columnName": "second", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "repeatDays", | ||
| "columnName": "repeatDays", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isHolidayAlarmOff", | ||
| "columnName": "isHolidayAlarmOff", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isSnoozeEnabled", | ||
| "columnName": "isSnoozeEnabled", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "snoozeInterval", | ||
| "columnName": "snoozeInterval", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "snoozeCount", | ||
| "columnName": "snoozeCount", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isVibrationEnabled", | ||
| "columnName": "isVibrationEnabled", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isSoundEnabled", | ||
| "columnName": "isSoundEnabled", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "soundUri", | ||
| "columnName": "soundUri", | ||
| "affinity": "TEXT", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "soundVolume", | ||
| "columnName": "soundVolume", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isAlarmActive", | ||
| "columnName": "isAlarmActive", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| } | ||
| ], | ||
| "primaryKey": { | ||
| "autoGenerate": true, | ||
| "columnNames": [ | ||
| "id" | ||
| ] | ||
| }, | ||
| "indices": [], | ||
| "foreignKeys": [] | ||
| } | ||
| ], | ||
| "views": [], | ||
| "setupQueries": [ | ||
| "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)", | ||
| "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, 'd9643e982a8885da158bcd94c55931ff')" | ||
| ] | ||
| } | ||
| } |
127 changes: 127 additions & 0 deletions
127
core/database/schemas/com.yapp.database.AlarmDatabase/2.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,127 @@ | ||
| { | ||
| "formatVersion": 1, | ||
| "database": { | ||
| "version": 2, | ||
| "identityHash": "c92b2b14e449f0f966e7074359903eed", | ||
| "entities": [ | ||
| { | ||
| "tableName": "alarm_database", | ||
| "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `isAm` INTEGER NOT NULL, `hour` INTEGER NOT NULL, `minute` INTEGER NOT NULL, `second` INTEGER NOT NULL, `repeatDays` INTEGER NOT NULL, `isHolidayAlarmOff` INTEGER NOT NULL, `isSnoozeEnabled` INTEGER NOT NULL, `snoozeInterval` INTEGER NOT NULL, `snoozeCount` INTEGER NOT NULL, `isVibrationEnabled` INTEGER NOT NULL, `isSoundEnabled` INTEGER NOT NULL, `soundUri` TEXT NOT NULL, `soundVolume` INTEGER NOT NULL, `isAlarmActive` INTEGER NOT NULL, `missionType` TEXT NOT NULL, `missionCount` INTEGER NOT NULL)", | ||
| "fields": [ | ||
| { | ||
| "fieldPath": "id", | ||
| "columnName": "id", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isAm", | ||
| "columnName": "isAm", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "hour", | ||
| "columnName": "hour", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "minute", | ||
| "columnName": "minute", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "second", | ||
| "columnName": "second", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "repeatDays", | ||
| "columnName": "repeatDays", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isHolidayAlarmOff", | ||
| "columnName": "isHolidayAlarmOff", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isSnoozeEnabled", | ||
| "columnName": "isSnoozeEnabled", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "snoozeInterval", | ||
| "columnName": "snoozeInterval", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "snoozeCount", | ||
| "columnName": "snoozeCount", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isVibrationEnabled", | ||
| "columnName": "isVibrationEnabled", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isSoundEnabled", | ||
| "columnName": "isSoundEnabled", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "soundUri", | ||
| "columnName": "soundUri", | ||
| "affinity": "TEXT", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "soundVolume", | ||
| "columnName": "soundVolume", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "isAlarmActive", | ||
| "columnName": "isAlarmActive", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "missionType", | ||
| "columnName": "missionType", | ||
| "affinity": "TEXT", | ||
| "notNull": true | ||
| }, | ||
| { | ||
| "fieldPath": "missionCount", | ||
| "columnName": "missionCount", | ||
| "affinity": "INTEGER", | ||
| "notNull": true | ||
| } | ||
| ], | ||
| "primaryKey": { | ||
| "autoGenerate": true, | ||
| "columnNames": [ | ||
| "id" | ||
| ] | ||
| } | ||
| } | ||
| ], | ||
| "setupQueries": [ | ||
| "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)", | ||
| "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, 'c92b2b14e449f0f966e7074359903eed')" | ||
| ] | ||
| } | ||
| } | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.