Kibotos
API referencekibotos.ctrl.v1

FilesystemService

This page lists the methods of FilesystemService in kibotos.ctrl.v1 with the messages and enums each one uses, generated from ctrl.proto and its comments. Those that several services use are on kibotos.ctrl.v1 types.

Node data planeCalled at the endpoint of a data-plane session, with its credential in Authorization: Bearer.How to call it

FilesystemService performs metadata operations on the Workspace filesystem: stat, listing, directory creation, move, removal, and directory watching. File content is read and written through the /v1/files HTTP endpoint on the same data-plane listener. Stat, ListDir and WatchDir require FILE_READ; the rest require FILE_WRITE. A path, here and on /v1/files, is absolute or relative to the home directory of the identity user selects; responses always name entries by their cleaned absolute path.

Stat

POST/kibotos.ctrl.v1.FilesystemService/StatUnary
RequestStatRequest
  • pathstring= 1
  • userstring= 2

    user selects the identity the operation runs as: empty for the Template default, the declared account name, or root.

ResponseStatResponse

ListDir

POST/kibotos.ctrl.v1.FilesystemService/ListDirUnary
RequestListDirRequest
  • pathstring= 1
  • depthuint32= 2

    depth is the maximum relative depth of returned entries; 1 lists direct children. It must be within the profile bound.

  • userstring= 3

    user selects the identity the operation runs as: empty for the Template default, the declared account name, or root.

ResponseListDirResponse
  • entriesrepeatedEntryInfo= 1

    entries are sorted by path and never include the listed root itself.

MakeDir

POST/kibotos.ctrl.v1.FilesystemService/MakeDirUnary
RequestMakeDirRequest
  • pathstring= 1
  • modeuint32= 2

    mode carries permission bits only; zero selects 0755.

  • userstring= 3

    user selects the identity the operation runs as: empty for the Template default, the declared account name, or root.

ResponseMakeDirResponse

Move

POST/kibotos.ctrl.v1.FilesystemService/MoveUnary
RequestMoveRequest
  • sourcestring= 1
  • destinationstring= 2
  • userstring= 3

    user selects the identity the operation runs as: empty for the Template default, the declared account name, or root.

ResponseMoveResponse

Remove

POST/kibotos.ctrl.v1.FilesystemService/RemoveUnary
RequestRemoveRequest
  • pathstring= 1
  • userstring= 2

    user selects the identity the operation runs as: empty for the Template default, the declared account name, or root.

ResponseRemoveResponse

No fields.

WatchDir

WatchDir reports changes to the entries of one directory. It sends started once the watch is in place; from then on every change yields at least one event or the stream ends with RESOURCE_EXHAUSTED. Events only say which path may have changed: callers list the directory after started and again after the stream ends. The stream never ends with OK. The server announces it as workspace.filesystem.watch_dir.

POST/kibotos.ctrl.v1.FilesystemService/WatchDirServer streaming
RequestWatchDirRequest
  • pathstring= 1

    path names the directory to watch. A symbolic link to a directory is followed; event paths stay under the requested path.

  • include_entry attaches the affected entry to CREATE, WRITE and CHMOD events while the entry still exists.

  • userstring= 3

    user selects the identity the operation runs as: empty for the Template default, the declared account name, or root. The identity must be able to read the directory.

Responsestream ofWatchDirResponse

WatchDirStartedEvent

WatchDirStartedEvent is the first message of every watch stream.

This message has no fields.

WatchDirHeartbeatEvent

This message has no fields.

FilesystemEvent

FilesystemEvent reports that one entry of the watched directory may have changed. Changes inside subdirectories are not reported.

  • pathstring= 1

    path is the cleaned absolute path of the entry: the requested directory joined with the entry name.

  • entry is the entry as seen when the event was handled. It is absent for REMOVE and RENAME, without include_entry, and when the entry is gone.

FilesystemEventType

  • FILESYSTEM_EVENT_TYPE_UNSPECIFIED= 0
  • FILESYSTEM_EVENT_TYPE_CREATE= 1

    CREATE: the entry was created or moved into the directory.

  • FILESYSTEM_EVENT_TYPE_WRITE= 2

    WRITE: the file content was written.

  • FILESYSTEM_EVENT_TYPE_REMOVE= 3

    REMOVE: the entry was deleted.

  • FILESYSTEM_EVENT_TYPE_RENAME= 4

    RENAME: the entry was moved away; path is where it was.

  • FILESYSTEM_EVENT_TYPE_CHMOD= 5

    CHMOD: permissions, ownership, timestamps or another attribute changed.

Messages and enums

Several methods of FilesystemService use these messages and enums.

EntryInfo

EntryInfo describes one filesystem entry without following a trailing symbolic link.

EntryType

  • ENTRY_TYPE_UNSPECIFIED= 0
  • ENTRY_TYPE_FILE= 1
  • ENTRY_TYPE_DIRECTORY= 2
  • ENTRY_TYPE_SYMLINK= 3
  • ENTRY_TYPE_OTHER= 4

On this page