-
Notifications
You must be signed in to change notification settings - Fork 23
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
Zipkin exporter #11
Comments
Hi, Thanks for that! I started a branch with your suggestion => https://github.com/jufab/opentelemetry-angular-interceptor/tree/zipkin_webpack It works But this modification is possible only on the application, not on the library. So if i insert that, this library will be not compatible with a default angular application (ng new) I prefer to wait for a zipkin "browser" compatible. I conserve this branch for the moment ;) |
This is indeed purely informative, it's a good way to "pre-test" the zipkin exporter and for users to have some pieces of information on how to setup the zipkin exporter with an angular project. I totally understand and agree with you, it's best to wait for the official browser support. |
FYI, Zipkin is officially supported in browser now: open-telemetry/opentelemetry-js#1399 (comment) |
Thanks. I just wait the next release ;) |
Hello,
I just want to provide some more info about Zipkin exporter because it's in a grey area right now for the web browser support.
In the ZipkinExporterService, it's is stated that
ZipkinExporter isn't operationnal for the moment in web application.
which isn't 100% true.The Opentelemetry Zipkin exporter is based on few node.js global modules such as http and https which should make the library incompatible with the browser. Nevertheless, webpack provides some polyfills that makes it possible to run the Zipkin exporter in the browser.
By default, Angular's webpack configuration turns off node polyfills (node: false) but it's possible to extend the webpack configuration to turn it on thus making Zipkin exporter work.
To do so, some simple steps are required:
@angular-builders/custom-webpack
angular.json
(projects.project-name.architect.build.builder)angular.json
(projects.project-name.architect.build.options):angular.json
(projects.project-name.architect.serve.builder)webpack.config-extension.js
at the same level than angular.jsonWith this manipulation, the module
@opentelemetry/exporter-zipkin
can be used in Angular (and, by extension, in the browser).It is important to note that I don't know the possible side-effects of allowing node globals in the webpack configuration and the impact on the Angular app.
The text was updated successfully, but these errors were encountered: