airbloc / airbloc-go

Airbloc Core Implementation using Go
https://airbloc.org/
Apache License 2.0
27 stars 10 forks source link

Fully-Working provide api & DAuth process with 완전체 adapter (Phase2) #116

Closed byeongsu-hong closed 5 years ago

byeongsu-hong commented 5 years ago

지난 PR에서 남아있던 것들 & 해야할 것들

내용

Ethereum 잔해 제거

Klaytn과 Ethereum을 함께 사용하는 경우, secp256k1 라이브러리가 충돌나면서 빌드가 안되는 문제가 생김. 그래서 모든 dependency에서 Ethereum을 제거했고 (airframe), 쓰더라도 최대한 ethereum의 crypto 라이브러리를 사용하지 않게 변경함.

Adapter구조 완성

의존성

ABIEncoderV2를 지원하는 Ethereum에서 abi를 가져온 포크를 사용함. indexed event topic문제 해결 - Hex값이 거꾸로 되어 오는 이상한 경우

API

에러메시지 수정 - 차후에는 타입을 따로 지정하여 최대한 대응할 수 있는 에러의 범위를 크게 할 것. 트랜잭션 에러를 internal error로 바꿈. 원래는 StatusConflict였음. 모든 리소스를 Create/Register할 때, existence를 체크한 뒤 있다면 StatusConflict를 리턴함. 이제 API의 모든 request, response에서 snake_case를 사용함.