OpenZeppelin contracts-upgradeable로 UUPS·Transparent 프록시 배포와 업그레이드 가이드
개요 OpenZeppelin의 contracts-upgradeable은 업그레이드 가능한 스마트 컨트랙트를 안전하게 구현하기 위한 베이스 라이브러리 프록시 Proxy 패턴으로 사용자 호출 주소와 로직 컨트랙트를 분리하고 delegatecall로 로직을 실행 Transparent Proxy와 UUPS 두 방식을 공식 지원 이 글은 Hardhat 환경에서 @openzeppelin/hardhat-upgrades 플러그인과 함께 UUPS를 중심으로 배포와 업그레이드 흐름을 정리하고, Transparent와의 차이점을 요약 핵심 개념 Proxy 컨트랙트와 Implementation 컨트랙트를 분리하여 배포 사용자는 Proxy 주소로 상호작용, Proxy는 delegatecall로 Implementation의 로직 실행 업그레이드는 Proxy가 가리키는 Implementation 주소를 교체하는 방식 EIP-1967 표준 슬롯을 사용해 Implementation 주소 보관 방식 요약 ...