Comments (8)
After a very helpful hangouts, it was discovered that the specific endpoint we were using to test this "issue" was returning a content type of text/plain
on the candidate side. After enabling DEBUG logging for ai.diffy.lifter.HttpLifter
the stack traced showed a parse error. @puneetkhanduri confirmed that Diffy does not support that content type at this point, only the usual HTML and JSON suspects.
For our use case this is fine because all normal application endpoints use one of those.
from diffy.
Can you ping me at [email protected]. It might be easier to debug this with screen sharing via hangouts.
from diffy.
That is strange. Diffy is designed to work with 4XX responses just as well as it does with 200.
I just tested some endpoints hardcoded to return 400 status codes and am able to see them on the UI. Are you able to verify the networking and see that your primary, secondary and candidate instances are receiving traffic from Diffy?
from diffy.
(coworker here) We have found that if the Primary/Secondary returns a 404 and the Candidate returns a 200, nothing is shown in the Diffy webUI. The opposite appears to work just fine.
Is this working as intended?
from diffy.
No. You should be able to see the differences in both cases. I also just verified this behavior. Can you share the differences.log file generated by diffy.
from diffy.
from diffy.
deleted and re-created docker container (diffy/diffy), cleaned up differences.log with echo "" > differences.log
(it seems to have some test data already there from when the container was built?), verified that it was empty.
Sent a request with an endpoint that only exists in the candidate (/ping
). Nothing is written to differences.log, nothing in webui. Admin web ui shows successful requests to all 3 backends.
Sent another requests to an endpoint that does not exist in both candidate and current backends and that worked (there was a diff in the webui and in differences.log)
Also (but unrelated since same behaviour happens without it) we have nginx reverse proxying all requests on port 80 back to the candidate node with a mirror option that then mirrors the request to diffy (as this allows us to see a response when submitting the requests). Running the /ping
request replies with the appropriate response (pong
).
The image you linked is what shows up when we have a primary return 200 and candidate return 404, just not the opposite for some reason.
EDIT: our docker run arguments:
-p 8080:8080 -p 8881:8881 -p 8888:8888 \
artifacts.slu.bskyb.com:5003/diffy/diffy \
-candidate=CANDIDATE:80 \
-master.primary=OLDAPI01:4031 \
-master.secondary=OLDAPI01:4031 \
-service.protocol=http \
-serviceName="some-api" \
-proxy.port=:8080 \
-admin.port=:8881 \
-http.port=:8888 \
-rootUrl=localhost:8888 -excludeHttpHeadersComparison=true
Requesting directly (without nginx):
curl -v localhost:8080/ping
* About to connect() to localhost port 8080 (#0)
* Trying 127.0.0.1...
* Connected to localhost (127.0.0.1) port 8080 (#0)
> GET /ping HTTP/1.1
> User-Agent: curl/7.29.0
> Host: localhost:8080
> Accept: */*
>
< HTTP/1.1 200 OK
< Content-Length: 0
<
from diffy.
Turns out this was a case of unsupported content-type where the response header did not contain application/json or text/html. Issue was fixed by having the downstream targets supply the expected content-type header values.
from diffy.
Related Issues (20)
- Differences Not Showing in Right Panel of Dashboard HOT 1
- com.twitter.common#metrics;0.0.29: not found
- fail to get started diffy HOT 1
- sbt.ResolveException: unresolved dependency: org.apache.thrift#libthrift;0.5.0-1: not found HOT 1
- how to make mobile testing
- Feature request: supporting text/plain HOT 4
- Is this tool still in updating? HOT 1
- how to process the difference of data? HOT 4
- Diffy admin won't load, no errors, StaticLoggerBinder warning HOT 5
- latency diffing
- Add Opentracing to diffy. HOT 2
- How to ignore the certificate when I use the https protocol
- How to change the header when sending a request to a different service. For example, when sending a request to cadidate and primary, the Header is different.
- Error: unknown artifact in the build.sbt file,and error:cannot resovle symbol in some files
- Dashboard script files path HOT 1
- readme error: using diffy with docker HOT 1
- Docker: proxy forwards with the wrong header parameter
- manifest for hseeberger/scala-sbt not found HOT 3
- How to show secondary response to the web page HOT 1
- is not in a section HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from diffy.