Skip to content

Collections #11

@danirod

Description

@danirod

A collection is a group of requests. For instance, when you are working on an API and you have a set of endpoints, each endpoint is a request part of the same collection.

Data structures

  • Collection (new)
  • Request (add fields)
    • Optional collection where the request belongs to (null = standalone request)

File system

At the file system level, a collection is stored as a metadata file in a directory.

I was thinking about just scanning every *.cartero file in the collection directory, but for large projects, it might not be feasible to set a monitor that large, or to recursively scan the whole directory looking for *.cartero files.

Also, it is important to validate that paths (such as the request files) are relative to the collection metadata file. The collection metadata file acts as a chroot, and it is important for Cartero to not access requests outside the collection metadata file.

User interface

I'd like to experiment with the idea of having one window per collection.

The state of the art seems to be a global window with a sidebar that allows to open multiple endpoints from multiple collections, and use a single tab bar to switch between endpoints of any collection.

I'd rather bind a collection to a window. You can open multiple collections as separate windows, and you have a sidebar on each window with the list of endpoints that are part of that collection.

There is still need for the standalone window (currently CarteroWindow) for opening .cartero requests that are not part of any collection.

My stoppers for this are:

  • Make sure that you cannot drag and drop tabs from a specific collection into other. (I think that AdwTabView is too open with the drag and drops, I don't know if I can limit them).
  • What happens if you open a .cartero file that is also being opened by another collection window.

Metadata

Metadata

Assignees

Labels

Depends on another issueThis issue cannot be actioned until a different issue is merged

Projects

Status

Needs Think

Relationships

None yet

Development

No branches or pull requests

Issue actions