Skip to content

v0.4.0 - Spine v0.6.0 and Echo Platform v0.1.0 | Spine v0.6.0과 Echo 플랫폼 v0.1.0 지원

Choose a tag to compare

@NARUBROWN NARUBROWN released this 02 Nov 03:28
· 202 commits to preview since this release
bf2ac43
Spine

🦴 Spine CLI v0.4.0

Spine v0.6.0, Echo Platform v0.1.0, HTTP Adapter v2 | Spine v0.6.0, Echo 플랫폼 v0.1.0, HTTP 어댑터 v2

Spine CLI v0.4.0은 new와 update가 Spine v0.6.0과 Echo 플랫폼 v0.1.0의 공개 릴리스 조합을 사용하도록 갱신합니다. 새 프로젝트는 플랫폼 연결, 의존성 설치, 정적 계약 검사와 빌드를 마친 뒤 생성되며, spine dev로 실행할 수 있습니다.

이 릴리스 노트는 CLI v0.3.0 태그 이후의 변경을 정리합니다. HTTP 어댑터 v2 구성 분석, typed Echo 설정 인식과 제거된 API 진단을 포함합니다.

Spine CLI v0.4.0 updates new and update to use the public releases of Spine v0.6.0 and Echo platform v0.1.0. New projects are created after platform configuration, dependency installation, static contract checks, and compilation, and can then be started with spine dev.

These release notes cover changes since CLI v0.3.0: HTTP adapter v2 composition analysis, recognition of typed Echo configuration, and diagnostics for removed APIs.


✨ 주요 변경 사항 | Highlights

  • new/update의 기본 조합을 Spine v0.6.0, Echo 플랫폼 v0.1.0, Echo v5.4.4로 갱신
  • spine.http-adapter/v2 지원과 선택된 Spine 버전에 따른 기존 v1 정적 분석 유지
  • platform.New, platform.Option, platform.NewFactory의 알려진 WithEcho 옵션 인식
  • 제거된 NewWithHTTPAdapter와 App.Transport에 구체적인 전환 진단 제공
  • app.Prepare, 실제 HTTP/WS와 종료 동작을 공개 모듈 조합으로 재검증
  • Set the default new/update combination to Spine v0.6.0, Echo platform v0.1.0, and Echo v5.4.4
  • Added spine.http-adapter/v2 support while retaining v1 static analysis according to the selected Spine version
  • Recognize known WithEcho options in platform.New, platform.Option, and platform.NewFactory
  • Added migration diagnostics for removed NewWithHTTPAdapter and App.Transport APIs
  • Revalidated app.Prepare, real HTTP/WS behavior, and shutdown against the public module releases

🚀 주요 변경 사항 상세 | Detailed Changes

공개 릴리스로 프로젝트 생성과 갱신 | Project Creation and Updates with Public Releases

기본 레시피는 이전 개발 의사버전에서 echo-v0.1.0-spine-v0.6.0으로 바뀝니다. 생성한 go.mod와 Go가 실제 선택한 모듈 그래프에서 아래 조합을 검사합니다.

The default recipe changes from the previous development pseudo-versions to echo-v0.1.0-spine-v0.6.0. The CLI checks the generated go.mod and the versions actually selected by Go against this combination.

모듈 / Module 버전 / Version
github.com/NARUBROWN/spine v0.6.0
github.com/NARUBROWN/spine-echo-platform v0.1.0
github.com/labstack/echo/v5 v5.4.4

new의 생성, 의존성 설치, 모듈 조합 검사, 정적 계약 검사, 빌드와 최종 게시의 6단계는 유지합니다. update는 임시 복사본에서 검증한 뒤 go.mod/go.sum만 반영합니다. 두 명령 모두 앱 초기화, 테스트나 listener를 실행하지 않습니다.

new retains its six stages: scaffold, dependencies, module checks, static contract checks, build, and publish. update validates a temporary project copy before applying only go.mod/go.sum. Neither command runs application initialization, tests, or a listener.

HTTP 어댑터 v2 구성 분석 | HTTP Adapter v2 Composition Analysis

CLI는 선택된 Spine 버전으로 기대하는 어댑터 계약을 결정합니다. Spine v0.6.0부터는 spine.http-adapter/v2를 기대하며, 이전 HTTP v1 개발 조합의 정적 분석도 유지합니다.

다음 생성식과 각각에 들어가는 알려진 platform.WithEcho(...) 옵션을 인식합니다. 아래 코드는 분석 가능한 생성식의 예시입니다.

The expected adapter contract follows the selected Spine version. Spine v0.6.0 uses spine.http-adapter/v2; static analysis of the previous HTTP v1 development combination remains available.

The analyzer recognizes these construction forms and known platform.WithEcho(...) options within them. The following expressions illustrate supported composition forms.

platform.New()
spine.New(platform.Option())
spine.New(spine.WithHTTPAdapter(platform.NewFactory()))

platform.New(platform.WithEcho(func(e *echo.Echo) {
    e.GET("/native", func(ctx *echo.Context) error {
        return ctx.String(200, "native")
    })
}))

정적 분석은 Echo 설정 콜백을 실행하거나 콜백 내부의 native route를 Spine 계약에 추가하지 않습니다. 임의 옵션과 options... 같은 가변 목록은 미해결로 남깁니다.

Static analysis does not execute Echo configuration callbacks or add native routes inside them to the Spine contract. Arbitrary options and expanded lists such as options... remain unresolved.


🧩 호환성/마이그레이션 메모 | Compatibility Notes

기존 프로젝트 갱신 | Updating Existing Projects

CLI v0.3.0은 이전 HTTP v1 개발 조합을 생성합니다. CLI v0.4.0으로 바꿔도 기존 프로젝트의 의존성이나 업무 소스는 자동으로 변경되지 않습니다.

spine update는 의존성을 갱신하며 소스를 마이그레이션하지 않습니다. 다음 API를 사용하는 프로젝트는 소스를 먼저 수정해야 합니다.

CLI v0.3.0 generates the previous HTTP v1 development combination. Installing CLI v0.4.0 does not automatically change an existing project's dependencies or application source.

spine update updates dependencies and does not migrate source code. Projects using these APIs must update their source first.

이전 API / Previous API 전환 / Replacement CLI 진단 / Diagnostic
spine.NewWithHTTPAdapter(factory) spine.New(spine.WithHTTPAdapter(factory)) HTTP_ADAPTER_API_REMOVED
app.Transport(func(any)) platform.WithEcho(func(*echo.Echo)) HTTP_NATIVE_HOOK_API_REMOVED
spine.Prepare(ctx, app, options) app.Prepare(ctx, options) Go 빌드 검사 / Go build check

선택된 Spine이 v0.6.0일 때 제거된 생성자와 native hook API를 진단합니다. 검증이 실패한 update는 원본 go.mod/go.sum을 유지합니다. 호환되는 프로젝트는 계획을 검토한 뒤 갱신할 수 있습니다.

The removed constructor and native hook APIs are diagnosed when the selected Spine version is v0.6.0. If update validation fails, the original go.mod/go.sum remain unchanged. Compatible projects can review and apply the update plan.

spine update --dry-run --json
spine update --if-match <base_hash> --json
spine contract check --json
spine verify --json

<base_hash>에는 검토한 dry-run 결과의 result.base_hash를 사용합니다. HTTP 요청, WebSocket과 외부 인프라 검증은 갱신 후 별도로 수행하세요.

Replace <base_hash> with result.base_hash from the reviewed dry run. Verify HTTP requests, WebSockets, and external infrastructure separately after updating.

상세 전환 안내 / Migration details: Spine HTTP 플랫폼 전환 가이드 / HTTP platform migration guide.


🧪 테스트 범위 | Test Coverage Boundary

이번 호환 수정은 정식 공개 태그 조합으로 다음 항목을 검증했습니다.

  • CLI 전체 go test -race ./... -count=1과 go vet ./...
  • 별도의 빈 Go 모듈 캐시와 빈 빌드 캐시에서 new의 6단계 통과
  • 수동 go mod tidy나 앱 Go 소스 수정 없이 dev와 최초 /health의 200 OK
  • 생성 앱의 HTTP 입력과 응답, WebSocket 왕복, 열린 연결의 종료와 포트 반환
  • app.Prepare, typed native hook, Close 후 503과 외부 listener 소유권
  • 재고 API HTTP 회귀 단언 54/54와 추가 생성/갱신/실패/실행 사례 8/8
  • 기존 v1 프로젝트의 업무 Go 소스 해시를 유지한 의존성 갱신과 실제 HTTP 201
  • CLI와 생성 앱의 Windows amd64 빌드

검증은 로컬 Go 검사와 실제 로컬 HTTP/WS 실행 범위입니다. 재고 앱은 기존 업무 fixture를 재사용한 회귀 검사이며 새 독립 휴먼 실험이 아닙니다. Windows 실행, 실제 DB와 Kafka/RabbitMQ 브로커, 운영 배포는 포함하지 않습니다.

The compatibility changes were validated against the public release tags with:

  • The full CLI go test -race ./... -count=1 suite and go vet ./...
  • All six new stages with separate, initially empty Go module and build caches
  • dev and the first /health response returning 200 OK without manual go mod tidy or application Go source edits
  • Generated-app HTTP input/output, WebSocket round trips, open-connection shutdown, and port release
  • app.Prepare, typed native hooks, 503 after Close, and external listener ownership
  • 54/54 inventory HTTP regression assertions and 8/8 additional creation, update, failure, and runtime cases
  • A dependency update of an existing v1 project preserving application Go source hashes and returning a real HTTP 201
  • Windows amd64 builds of the CLI and a generated application

These results cover local Go checks and real local HTTP/WS execution. The inventory app reuses an existing business fixture for regression testing; it is not a new independent human study. Windows execution, live databases, Kafka/RabbitMQ brokers, and production deployments are outside this validation.


📦 설치 | Installation

최소 Go 버전은 1.25.5입니다. spine 명령으로 설치하려면 다음 경로를 사용합니다.

The minimum Go version is 1.25.5. Install the spine command with:

go install github.com/NARUBROWN/spine-cli/cmd/spine@v0.4.0
spine version
# spine-cli 0.4.0

spine new todo-api --module github.com/acme/todo-api
cd todo-api
spine dev

다른 터미널에서 기본 health endpoint를 확인합니다. 200 OK와 {"status":"ok"}가 반환됩니다.

In another terminal, check the default health endpoint. It returns 200 OK and {"status":"ok"}.

curl http://localhost:8080/health

기존 spine-cli 실행 파일 이름으로 설치하려면 루트 경로를 사용합니다.

To keep the spine-cli executable name, install from the module root.

go install github.com/NARUBROWN/spine-cli@v0.4.0
spine-cli version
# spine-cli 0.4.0

new는 설치와 빌드를 완료한 뒤 프로젝트를 생성합니다. --skip-install로 파일만 생성한 경우에는 go mod tidy를 별도로 실행하세요. 설치, 생성과 갱신의 상세 동작은 README를 참고하세요.

new creates the project after installation and compilation succeed. If you generate files only with --skip-install, run go mod tidy separately. See the README for installation, generation, and update details.

관련 PR / Pull request: #24

Full Changelog: v0.3.0...v0.4.0