Separate local/remote instance at DB level - #44
Open
2chanhaeng wants to merge 6 commits into
Open
Conversation
Add , and remove , when get
Prompt: DB 스키마에서 `instance` 를 Local/Remote 로 분리하고 API 를 수정하면서 기존 스키마/API 에 맞춰놨던 일부 테스트가 문제 되고 있습니다. [instance.test.ts](packages/graphql/src/instance.test.ts) 파일의 20419ce 커밋 변경 사항을 참고해서 문제되는 파일들의 코드를 직접 수정하세요. 문제되는 파일들은 `mise check`, `mise test` 로 찾을 수 있습니다. 추가적으로 리모트 인스턴스를 위한 테스트도 추가하세요. 너무 복잡한 테스트 말고, 생성, host 유일성 체크 정도만 추가하세요. Assisted-by: Codex:gpt-5-6-sol
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Resolves #43.
A
locationcolumn was added to the existingInstancetable to define either aLocalorRemotevalue, and additional tables were created to store the information required for defining local/remote instances. The IDs of the local/remote instance records reference the instance ID and are set to cascade upon removal to maintain DB consistency.However, as the
expirescolumn was separated into the local instance table, theinstances_expires_checkcheck became impossible at the DB level. Therefore, this inevitably has to rely on the server.While the input for the existing
Instancecreation API remains unchanged, the results for both retrieval and creation have been updated. To keep the interface of instance lookup results the same whether they are local or remote, the domainhostis returned. For this purpose, the-r, --root-domainargument is received upon server execution to be used as the root domain. The default value isdrfed.org.Assisted-by: Codex:gpt-5-6-sol