Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🔌 Plugin: Inventory #2461

Open
3 tasks done
christoph-jerolimov opened this issue Jan 7, 2025 · 3 comments
Open
3 tasks done

🔌 Plugin: Inventory #2461

christoph-jerolimov opened this issue Jan 7, 2025 · 3 comments
Assignees
Labels

Comments

@christoph-jerolimov
Copy link
Member

🔖 Summary

I like to build an inventory plugin that saves items in the software catalog.

It should be possible to use it for 'personal' belongings and be scalable for corporates. Scalable in the way that it supports different optional levels of abstracts and types of locations.

To be 💯% clear: I'm realistic that it will not replace an inventory solution where companies track all their hardware.

I share this here to get initial feedback and maybe people that want contribute from the beginning.

Inventory model

It should have primary two kinds of objects:

  1. Items
    • Items like a caffee machine, a notebook, etc. The resource should have attributes to save an assignee and/or a location where the item 'should be'. A note, a picture, multiple IDs or serial numbers and when and where it was last seen.
    • Containers that can contains multiple items and have their own location, for example in a garage or shelf.
  2. Locations
    • Shelf
    • Rooms
    • Floors
    • Buildings
    • Campus

You might want to save also movable items like cars, trucks, bikes with their location. But I like to define that out of scope until someone wants help with that. 😏

Initial idea of the catalog types

API Version

Is inventory.backstage.io/v1alpha1 fine?

inventory.community-plugins.backstage.io/v1alpha1 looks too long to me.

Item

Will use metadata name, title as defined in https://backstage.io/docs/features/software-catalog/descriptor-format

Spec:

  • assigned or responsible user (I guess owner is misleading here)
  • expected location (ref to a location entity
  • last seen location (ref to a location entity)
  • rented to (more for personal belongings)
  • identifiers (a record of IDs and serial numbers)
  • a note?
  • picture(s)?
  • history?

Example:

apiVersion: inventory.backstage.io/v1alpha1
kind: Item
metadata:
  name: coffee-machine
spec:
  location: kitchen

Location

Mostly a name and title from the entity and a uni-directional link to a parent location.

Example:

apiVersion: inventory.backstage.io/v1alpha1
kind: Location
metadata:
  name: home
spec:
  type: building
---
apiVersion: inventory.backstage.io/v1alpha1
kind: Location
metadata:
  name: kitchen
spec:
  type: room
  parent: home

I noticed already an issue with kind: Location. That would be displayed in the catalog together with backstage.io/Locations which looks be confusing.

Alternative:

apiVersion: inventory.backstage.io/v1alpha1
kind: Building
metadata:
  name: home
---
apiVersion: inventory.backstage.io/v1alpha1
kind: Room
metadata:
  name: kitchen
spec:
  parent: building:home  # I see this as a pro and con

Relations

  • Unsure if items could be saved in other items.
  • Items could be saved in locations.
  • Locations could be in other locations.

Personal belonging example:

  graph LR;
      CM[Coffee machine]-->Kitchen-->Home;
      ItemA[Personal belonging A]-->ContainerA[Container top left in the first shelf]-->Garage;
      ItemB[Personal belonging B]-->ContainerA[Container top left in the first shelf];
      ItemC[Personal belonging C]-->ContainerB[Container top right in the first shelf]-->Garage;
      ItemD[Personal belonging D]-->ContainerB[Container top right in the first shelf];
Loading

Corporate example:

  graph LR;
      Keyboard-->Room312[Room 312]-->Floor3[Floor 3]-->Building-->Campus;
      Monitor[Monitor with SN ...]-->Room312[Room 312];
      PC[PC with SN ...]-->Room312[Room 312];
Loading

🌐 Project website (if applicable)

No response

✌️ Context

No response

👀 Have you spent some time to check if this plugin request has been raised before?

  • I checked and didn't find similar issue

✍️ Are you willing to maintain the plugin?

🏢 Have you read the Code of Conduct?

Are you willing to submit PR?

Yes I am willing to submit a PR!

@vinzscam
Copy link
Member

Thanks. Could you share a bit more about who you see using this plugin?

@christoph-jerolimov
Copy link
Member Author

Thanks. Could you share a bit more about who you see using this plugin?

A bit of joking and a bit of truth: You never know at the beginning. I just thought about using Backstage personally for it and thought it's worth doinging it community-driven from the start and OpenSource by default. ;)

@vinzscam
Copy link
Member

I feel like this is a great example of how the catalog can be versatile, however I also think it should exist outside of community-plugins as a starting point to validate its value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants