January 2023 Summaries
4 posts from Highlight.io
Filter
Month:
Year:
Post Summaries
Back to Blog
Publishing an npm package with private pnpm monorepo dependencies involves navigating a complex setup, as outlined by software engineer Vadim Korolik from highlight.io. A monorepo is a code repository that stores multiple distinct projects side by side, allowing packages to use one another directly without external syncing. The process includes using yarn v3 workspaces for organizing JavaScript and TypeScript packages, enabling seamless local package references that mimic npm imports. Challenges arise when private packages, like the internal client library at highlight.io, must be referenced without being publicly published, which can lead to large bundle sizes in the npm package. The solution involves using relative path imports and code splitting to manage bundle size efficiently. Additionally, transitioning from yarn to pnpm requires configuration updates such as adjusting tsconfig.json and setting up pnpm-workspace.yaml. The guide also highlights the importance of automating build processes with tools like turborepo or Nx to streamline package bundling for production.
Jan 27, 2023
1,163 words in the original blog post.
Logging is an essential component for monitoring applications in production, allowing developers to track application activities and diagnose issues. Good logs provide severity levels, timestamps, and are formatted in a machine-readable way, such as JSON. While Go comes with a basic logging library, the language offers more than 50 third-party libraries that enhance logging capabilities. The article explores five top logging libraries for Go: Zap, Zerolog, Slog, apex/log, and Logrus, each offering structured logging, custom fields, and multi-destination log forwarding. Zap, developed by Uber, is noted for its high performance and configurability, while Zerolog provides an optimized logger with a simple API. Slog, set to become part of Go's standard library, introduces structured logging and levels. Apex/log allows for message customization and filtering, whereas Logrus, although in maintenance mode, remains popular for its structured logging support. The article suggests choosing Zap for new projects, while keeping an eye on Slog for future integration into the Go standard library.
Jan 09, 2023
3,176 words in the original blog post.
InfluxDB's time series database is utilized by Highlight to efficiently visualize and manage millions of metrics from full stack applications, addressing challenges like performance bottlenecks and data expiration that arise with traditional SQL databases. Highlight initially used PostgreSQL for its ease of querying and familiarity but encountered issues with the unbounded nature of metric data, which led to long query times and performance constraints. Transitioning to InfluxDB allowed for automatic time-based data expiration and better handling of high cardinality, although it introduced new hurdles such as managing cardinality limits and bucket-specific tasks. The company mitigated these issues by assigning each customer project to a separate InfluxDB bucket, controlling cardinality growth within manageable limits, despite the added complexity and cost. Highlight's platform provides customers with insightful metrics visualization and real-time debugging tools, enhancing their ability to resolve regressions and analyze infrastructure efficiency.
Jan 06, 2023
932 words in the original blog post.
Francois Wouts, the creator of the open-source library Preview.js, discussed how his tool allows developers to preview UI components directly within their editors, thereby reducing the feedback loop for UI modifications. Unlike Storybook, Preview.js offers this functionality without any setup, and there is a Storybook integration in development. The interview was conducted by Jay Khatri, Co-founder, Hype-man, and CEO, who aimed to highlight the advantages of using Preview.js in enhancing the efficiency of UI development workflows.
Jan 04, 2023
160 words in the original blog post.