Banana Recognizer Admin Panel

This project's goal is to display summary data to the admin users.

Address: https://banana-recog.dev.dac.systems/

Access to the app is granted based on the connected wallet address. Only permitted wallets have access to the page.

Displayed data

  • wallet address
  • username
  • score
  • token balance

The table is refreshed every 15 seconds.

Deployment

  • Docker container is a result of CI/CD build (.gitlab-ci.yml)
  • Container is being deployed to DAC internal K8S cluster
  • In case of failure of one machine pods will be recreated automatically

What can be improved?

  • allow to choose wallet on the login page (currently we take the first returned wallet)
  • change short pooling implementation to websocets (refresh data only if really has changed on the backend side)
  • use proxy pass to avoid CORS exposure

ADRs

  1. User incrementing it's score on demand is risky because user with some technical knowledge may increase his score even if banana was not found, better approach would be to allow backend wallet and only this wallet to increment score when photo would contain banana, this way we are securing smart contract from any unwanted actions. This would also require users on Mobile to pay backend wallet before doing any analysis so we don't waste our own funds, we can obtain fees
  2. Edge processing may speed things up as we dont need to communicate with the backend but it is also risky because user with technical knowledge may omit photo recognition and increment score without that (because smart contract will allow him to it since it's his score). If recognition happens on the backend we have oracle which is responsible for recognition and score incrementation and it cannot be fooled