1

I'm currently working on my own open source project.

There are two parts to it at the moment, a .NET core web API and an Angular client side app.

I would like to get your views on installation/setup for my users. What I have at the moment is an install endpoint in the API itself and an install component/page on the angular app.

This all works well but after giving it more thought it doesn't feel right. It feels I've ended up coupling the app and API when they should be completely separate and independent of each other. The client app should not really have to be concerned with the installation of the API.

Would it be better to build a CLI responsible for installing/upgrade both the API and APP that can be downloaded and run separately?

1 Answer 1

2

While SRP (Single Responsibility Principle) is useful, and probably motivating your desire to split the functionality up, the end goal is a good User Experience.

So ask yourself what is best for your user base?

  • Does the user want an installer?
  • Does the user want the client to figure out what needs to happen and do it?
  • Does the user want a portable application? (ie on a flashdrive/not a system directory)
  • Does the user want the API to self-update, and proved an updated client?

Whichever is most relevant is how you should be engineering your solution. If several are needed then you'll need enough flexibility to provide for them.

That being said, underneath the hood I would apply the SRP and keep the install feature set as a separate module in both the client and the API. This way should you choose to offer a separate installer, etc... you can easily re-bundle those modules, and offer a consistent UI/Feature set across installation methods. I would also be approaching the rest of the UI and API in this manner, treating the actual client/server each as a bundle of modules.

1
  • Thank you for your response. Your questions regarding the user experience and what is best for them is the reminder I needed really. I already have most parts as standalone modules including the installation, so I will stick with what I have for now and adapt as per user demand and requirements. Thank you.
    – Daveo
    Mar 18, 2019 at 2:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.