Welcome to highlight.io
Company
Mission & Values
Compliance & Security
Open Source
Getting Started
Overview
Fullstack Mapping
Backend / Server
Frontend / Client
Fullstack Frameworks
Product Features
Session Replay
Error Monitoring
General Features
Logging
Integrations
Integrations Overview
Amplitude Integration
ClickUp Integration
Discord Integration
Electron Support
Front Integration
Height Integration
Intercom Integration
Linear Integration
Mixpanel Integration
Segment Integration
Slack Integration
Vercel Integration
Tips
Content-Security-Policy
Local Development
Monkey Patches
Performance Impact
Proxying Highlight
Session Search Deep Linking
Troubleshooting
Upgrading Highlight
Highlight.io Changelog
Changelog 12 (02/17)
Menu
Apollo Server
Highlight ships @highlight-run/node
with a plugin ApolloServerHighlightPlugin
specifically for the apollo server.
The plugin will trace graphql resolver errors and report them to Highlight.
Usage
The usage of the Apollo plugin requires the Node.js integration to be configured.
Ensure that @highlight-run/node
updated to version 2.2.0 or greater. Then, add ApolloServerHighlightPlugin
to
your ApolloServer
plugins definition.
import { ApolloServer } from '@apollo/server' import { ApolloServerHighlightPlugin } from '@highlight-run/node'; // ... const server = new ApolloServer({ typeDefs, resolvers, plugins: [ApolloServerHighlightPlugin({projectID: 'YOUR_PROJECT_ID'})] });
Usage on Apollo Server v3 (deprecated)
The following example is for the deprecated ApolloServer v3 (importing from apollo-server-express).
import { ApolloServer } from 'apollo-server-express'; import { ApolloServerV3HighlightPlugin } from '@highlight-run/node'; // ... const server = new ApolloServer({ typeDefs, resolvers, plugins: [ApolloServerV3HighlightPlugin({projectID: 'YOUR_PROJECT_ID'})] });
Verify
To validate your Highlight backend setup, you can have a graphql resolver throw an error and check that the error is visible on app.highlight.io.