question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

stripPath not working

See original GitHub issue

Hi, I’m trying to use stripPath to remove path from apiEndpoints. All others path options behave as expected (prependPath and ignorePath).

I’m doing an gateway to RestHeart. When I enter the URL:

http://localhost:8081/api/mongo_collection which points to gateway, I expect redirecting to RestHeart without /api/ path, only the mongo_collection, but RH log keeps saying it’s received:

GET http://localhost:8080/api/mongo_collection from /192.168.0.1:45782

Below is my gateway.config.yml

http:
  port: 8081
admin:
  port: 9876
  hostname: localhost
apiEndpoints:
  restheart:
    host: '*'
    path: '/api/*'
serviceEndpoints:
  restheart:
    url: 'http://localhost:8080/'
pipelines:
  default:
    apiEndpoints:
      - restheart
    policies:
      - proxy:
          - action:
              serviceEndpoint: restheart
              changeOrigin: true
              #ignorePath: true  <--- works normal
              #prependPath: true  <--- works normal
              stripPath: true  <--- not working

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
XVincentXcommented, Aug 17, 2018

@johnnywiller Published.

1reaction
XVincentXcommented, Aug 16, 2018

It is not unfortunately. The documentation you’re looking at is the one for 1.11.0 😃

I hope to release it tomorrow, in any case not later than next week.

V.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Kong for K8 does not honor strip-path annotations in the ...
Summary Kong for K8 does not honor strip-path annotations in the ingress resource. ... If that does not work, or you're using DB-less...
Read more >
Strip path from filename - python - Stack Overflow
path.basename(filename), when I do I am unable to specify an absolute path for filename because k.set_contents_from_filename will not longer ...
Read more >
Strip Path VI error on exe version? - NI Community
Anyone having problems with the "Strip Path" VI not working on the Exe version of your application? I've attached the culprit application.
Read more >
Strip Path on network path can crash LV - LabVIEW Bugs - LAVA
The problem comes when you want to strip a network path that looks like this "\\server\dir\subdir". When stripping the path with the "Strip...
Read more >
Does it help if we can only strip-path portions of the paths, and ...
For one project, I found 44 paths for the strip-path parameters to ... was not finished reviewing the CSV file from the outstanding...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found