Node.js와 Edge 런타임의 기능 차이를 요구사항으로 판단합니다.
배포 runtime은 DB driver, native module, 지역 지연, 실행 시간과 플랫폼 지원을 기준으로 선택합니다. 단순히 Edge가 항상 빠르다고 가정하지 않습니다.
선택한 runtime에서 사용하는 라이브러리와 API가 지원되는지 build와 통합 테스트로 확인합니다.
환경변수, 파일 시스템, connection pooling과 cold start 정책이 플랫폼마다 다릅니다.
로컬 Node에서 성공한 native addon이 Edge에서도 동작한다고 가정하지 마세요.
로컬 프로젝트에서 확인해보세요이미지 처리와 DB transaction 기능에 적합한 runtime을 표에 추가하세요.
const decisions = [
{ need: "긴 DB 트랜잭션", runtime: "Node.js", reason: "driver와 연결 관리" },
{ need: "짧은 지역별 개인화", runtime: "Edge 검토", reason: "지원 API 확인" },
];
export default function Page() {
return (
<main>
<h1>런타임 선택 기록</h1>
<table>
<thead>
<tr>
<th>요구</th>
<th>선택</th>
<th>근거</th>
</tr>
</thead>
<tbody>
{decisions.map((x) => (
<tr key={x.need}>
<td>{x.need}</td>
<td>{x.runtime}</td>
<td>{x.reason}</td>
</tr>
))}
</tbody>
</table>
</main>
);
}