Coder Social home page Coder Social logo

Comments (4)

DonMartin76 avatar DonMartin76 commented on August 24, 2024

This is actually designed behavior to prevent you making such mistakes.

Deleting an API which is in use by an application is nothing which should just be ignored and and the subscription deleted (I could have done that, and the error message you see is part of the "sanity check" at startup, so I detect these things explicitly).

Before rolling out a new version of the configuration, it is advisable to take out the data using the export API, do either a blue/green kind of deployment, or a test deployment, and import that data into the test environment.

The import API will then do exactly the same checks as the portal API at startup and tell you whether the combination of static and dynamic data fit.

To remedy your problem now you should first revert to an older version of your configuration (I assume you have it in source control, so this shouldn't be difficult), delete the subscriptions to the invalid API, and then redeploy the new configuration. On my "mental todo list" there is a feature to delete all subscriptions to an API for exactly these situations, but until now it hasn't been very pressing.

Deleting an API from a production API portal shouldn't be done often; it will force all the clients to migrate to something else, which usually will be challenging.

Hope that helps. Perhaps we can mindstorm together a little to find a feature set which helps with these things. /Martin

from wicked.haufe.io.

TESAARON avatar TESAARON commented on August 24, 2024

Hi Martin,

Many thanks for reverting. Yes I think the button was pressed by accident by one of our developers and then caused the problem! Anyway, as you mentioned, we were able to revert the changes on Github and restart from there.

Perhaps an extra dialogue box should appear with a warning on the delete? Or perhaps admin privileges to the portal should still be allowed so that he/she can delete the application as a super-user? For now we will just make sure not to press delete anymore!

Regards,
Aaron

from wicked.haufe.io.

DonMartin76 avatar DonMartin76 commented on August 24, 2024

Deleting an abandonded API is perfectly fine and should be possible. I am more thinking along the following API Lifecycle phases:

  • Add a possibility to "depreciate" an API, so that it's no longer possible to subscribe to it, but existing subscriptions are still in effect, as would documentation and Swagger still be available
  • Add a "download subscriptions CSV" functionality which would let an Admin download a list of existing subscriptions for e-mailing actions announcing the retirement of an API
  • Have an Admin functionality which lets an Admin delete all active subscriptions of an API

And in addition to that, yes, it would be good to have a "do you really know what you're doing" kind of alert in the kickstarter when deleting APIs.

Thoughts?

from wicked.haufe.io.

DonMartin76 avatar DonMartin76 commented on August 24, 2024

I'll close this one if you don't mind, and track the idea in the new issue.

from wicked.haufe.io.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.