Transformations: Is Kong right for this use case?

Newbie says hi!

TL;DR

We’re mostly a Java / Kotlin shop, and need to perform multiple API transformations. If they’re to be implemented in code, we’d like to do that in a JVM language like Java, not Lua however great it may be. Declarative transformations (e.g. in a YAML file) would be even better.

Is Kong the right tool for us? If not, would anybody recommend another tool for us? We thought Kong was exactly what we needed, now after reading the docs, we’re not so sure…

Details

Here are some examples of things we’d like to do:

  • Our internal backend response may have 417 keys, we want to return 7 of these
    • We may want to rename (some of) these response keys
  • Query serviceA or serviceB depending on the value of keyX or some value in the OAuth2 token
  • ServiceZ is composed by combining the results of two backend requests, Service X and ServiceY
  • Implement /v1/some/api backwards-compatibility by calling /v2/some/api and doing appropriate transforms

Also, can all this be done with the Kong Gateway or will we need Kong Enterprise?

I have since checked out the Kong-supported Request Transformer plugin, which appears too simple for our needs and the Request Transformer Advanced plugin which requires Enterprise, but could sorta fullfill some of these needs. And the similar set for API responses. But even the advanced versions don’t lend themselves to the extensive transformations we have in mind.

And then there is the Template Transformer plugin. Looks handy for a little transformation here and there, but not to the extent we were hoping for.

So I’m guessing from this investigation and the lack of other responses that this indeed is not a good fit for Kong…

Request transformer and request transformer advanced are the same plugins now. We pushed the enterprise only features into open source a year ago. The docs are unfortunately out of date.

1 Like