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

Problem with svg file (xml) through krakend with Gorilla Mux router #443

Closed
ghpgmer opened this issue Dec 29, 2020 · 2 comments
Closed

Problem with svg file (xml) through krakend with Gorilla Mux router #443

ghpgmer opened this issue Dec 29, 2020 · 2 comments

Comments

@ghpgmer
Copy link

ghpgmer commented Dec 29, 2020

I have been using Krakend and it has been working great. I ran into this problem while serving svg file (xml). I use Gorilla Mux as my router. I cannot use "string" for output_encoding as browser does not render the file. I tried using "no-op", but browser complains of "XML parsing error: no root element found".

The URL endpoint as such is correct - I tried serving it without krakend and it works fine (no XML error on browser).

I tried firefox, chrome and safari - all of them have a problem when I go through krakend.

I read the krakend documentation, there is "negotiate" option for other routers but not Mux.

How do I resolve the issue ? please let me know.

Just to check, I tried with html - I see the same problem. I think the browser does not understand what content type is being sent.

My krakend.json looks like this

{
    "endpoint": "a/b",
    "output_encoding": "no-op",
    "headers_to_pass":["*"],
    "method": "GET",
    "backend" [
        {
            "encoding": "no-op",
            "host": ["http://mylocalurl"],
            "url_pattern": "a/b"
        }
    ]
}

@ghpgmer ghpgmer changed the title Problem with svg file (xml) through krakend with Mux router Problem with svg file (xml) through krakend with Gorilla Mux router Dec 30, 2020
@taik0 taik0 closed this as not planned Won't fix, can't repro, duplicate, stale Sep 28, 2023
@taik0 taik0 added the invalid label Sep 28, 2023
@github-actions
Copy link

Hi, thanks for bringing this issue to our attention.

Unfortunately, this issue has been marked invalid and will be closed.
The most common reasons for marking an issue or pull request as invalid is because:

  • It's vague or not clearly actionable
  • It contains insufficient details to reproduce
  • It's plugin review or custom code review
  • It does not use the issue template
  • It's unrelated to the project (e.g., related to one of its libraries)
  • It does not follow the technical philosophy of the project
  • Violates our Code of Conduct
  • It's about KrakenD functionalities (which uses and mantain Lura, but is not part of the Linux Foundation)

You can still make an edit or leave additional comments that lead to reopening this issue.


This is an automated comment. Responding to the bot or mentioning it won't have any effect

Copy link

This issue was marked as resolved a long time ago and now has been automatically locked as there has not been any recent activity after it. You can still open a new issue and reference this link.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants