Skip to content
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

Running CheerpJ application locally #138

Closed
christislord12 opened this issue Feb 1, 2022 · 4 comments
Closed

Running CheerpJ application locally #138

christislord12 opened this issue Feb 1, 2022 · 4 comments

Comments

@christislord12
Copy link

christislord12 commented Feb 1, 2022

I have a CheerpJ application that I want to have so it can be run offline locally without internet access. Currently, my application utilizes "https://cjrtnc.leaningtech.com/2.2/loader.js" to load the runtime. Would it be possible to somehow download all of the runtime files so I can run CheerpJ applications locally?

@alexp-sssup
Copy link
Member

We can provide self-hosting packages, but that is only allowed as part of a commercial license. Please contact sales@leaningtech.com if interested.

@liangklfangl
Copy link

liangklfangl commented May 17, 2023

I have a similar question. Some CDN resources on http://cjrtnc.leaningtech.com is extremely slow,is there any way to solve this problem? @christislord12

@alexp-sssup
Copy link
Member

alexp-sssup commented May 17, 2023

Can you point to specific files that are loaded slowly? We use the Cloudflare CDN that is globally distributed, it's seems quite unlikely that the performance is unsatisfactory.

As previously mentioned it is possible to self-host CheerpJ as part of a commercial license. Get in touch with sales@leaningtech.com if interested

@pengan1987
Copy link

I have a similar question. Some CDN resources on http://cjrtnc.leaningtech.com is extremely slow,is there any way to solve this problem? @christislord12

I've recently had the same problem as you, and it's especially bad in China

  1. Cloudflare China Network and Global Network are not interoperable due to policy regulations, which results in cjrtnc.leaningtech.com not having a China node.
  2. Due to (1), cjrtnc.leaningtech.com is most likely not pointed by DNS to a more optimized node, and when it resolves to a node outside of Asia or the US, it will be significantly slower in China, on my network, the default resolved node is in Germany.
  3. Cloudflare enables HTTP3/QUIC by default for newer browsers while they are UDP based, but many ISPs throttling UDP traffic which causes it to be slower. In my case, this one had the most obvious impact.

One of my use cases requires a total of about 30MB of resources to be loaded

  • If I use a proxy server, the load time is about 30 seconds
  • If I don't make any changes to the browser, load can't be finished, in the developer tools I've observed roughly 30KB/s load speed, which may take 20 minutes to load if it doesn't time out.
  • Turning off QUIC allows me to complete the load without proxy server, which takes about 90 seconds.

Also I observed that server response time for HTTP3/QUIC requests from Cloudflare sometimes exceeds 10 seconds, which seems to be a bug in Cloudflare: cloudflare/cloudflared#895

Considering that UDP throttling is widely used in many ISPs/firewalls/routers, perhaps CheerpJ just turning off QUIC on the CDN side and staying at HTTP/2 would be the most straightforward improvement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants