Skip to content

Instantly share code, notes, and snippets.

@yuvalif
Created October 23, 2023 12:13
Show Gist options
  • Save yuvalif/e49b36598964bec99d415e1d6d046822 to your computer and use it in GitHub Desktop.
Save yuvalif/e49b36598964bec99d415e1d6d046822 to your computer and use it in GitHub Desktop.

Usecases

Code

  • user docs
  • code walkthrough
  • rgw_lua.cc/h lua management code for scripts and packages (which is not specific to backend)
  • since the lua scripts and package list are stored in RADOS, some of the management script is also in: `driver/rados/rgw_sal_rados.cc/h'
  • rgw_admin.cc for the script and package management commands
  • rgw_lua_utils.cc/h infrastructure for linking between lua and RGW C++ code
  • rgw_lua_background.cc/h the global background context
  • rgw_lua_request.cc/h the per S3 request contexts (pre/post request)
  • rgw_lua_data_filter.cc/h the get/put object data context

TODO

Productizing

  • allow for multiple scripts in the same context
  • lua debug hook to limit time/cycles per execution
  • sandboxed lua with preinstalled packages

Performance

  • locking scheme of background context
  • compiled lua scripts
  • yielding lua async operations

Functionality

  • lazy attribute rerieval
  • add new lua contexts (which?)
  • lua support in rook

RADOS

  • lua rados binding
  • lua rgw rados binding
  • lua cls binding
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment