mapbox / mapbox/node-or-tools

Size too large for deployment. Possibilities to reduce size?

Open
#71 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
155
Forks
47
PR merge metrics
No merged PRs in 30d

Description

Hey, guys. Thanks for making a great library. I'm getting beautifully optimized routes!

My issue revolves around the resulting library size. Pulling from npm, this library comes in at a chunk of 475 MB, and it looks like the biggest piece is libtools.a @ 317 MB.

Is there any way I can reduce this size? We were really hoping to use this in a Lambda function to build optimal routes for our fleet, but the Lambda max is 250 MB. Is there another version of libtools.a or node-or-tools in general that's a bit slimmer?

Thanks a lot for any help!

Edit: Using --build-from-source doesn't work either if it helps.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting the npm package contents, especially libtools.a, and compare them with the result of the mentioned --build-from-source option. Determine whether a slimmer distributable can fit within Lambda's 250 MB limit; done would be a documented size-reduction path or a package that meets that limit.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, node.js
Domain
build-system, cloud, performance
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.