Hosting Standalone.zip on a CDN

Bringing your stacks to the web

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
gsillevis
Posts: 40
Joined: Tue Oct 13, 2020 10:55 pm

Hosting Standalone.zip on a CDN

Post by gsillevis » Fri Dec 04, 2020 12:44 pm

Is there a way to host the game zip on a cdn and not my web server? Do the standalone js file and the game zip need to be in the same directory?

What I am trying to achieve is faster download times of my game zip and the theory is a cdn(or drop box or s3) will help

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9249
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Hosting Standalone.zip on a CDN

Post by richmond62 » Fri Dec 04, 2020 12:48 pm

Sorry, but why would the standalone file be a javascript file?

LiveCode standalones are monolithic.

gsillevis
Posts: 40
Joined: Tue Oct 13, 2020 10:55 pm

Re: Hosting Standalone.zip on a CDN

Post by gsillevis » Fri Dec 04, 2020 12:53 pm

What do you mean by monolithic?

There are two files. Standalone.zip and standalone-community-9.5.1.js

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9249
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Hosting Standalone.zip on a CDN

Post by richmond62 » Sat Dec 05, 2020 5:26 pm

By monolithic I mean monolithic.

Desktop standalones generate a single file.

The HTML5 option generates 4 files: 2 of which are standalone.zip and standalone-community-9.6.1.js

BUT, you did not mention that your question/problem related to an HTML5 build, and as I have only generated
an HTML5 build twice (the second being one to see what you were on about just now) I didn't know
what you were writing about.

To avoid confusion it might not be a bad idea to contextualise things a bit more in postings.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9249
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Hosting Standalone.zip on a CDN

Post by richmond62 » Sat Dec 05, 2020 5:49 pm

I don't think your idea will work from DropBox as you cannot open a file directly in DropBox but have to download it first.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Hosting Standalone.zip on a CDN

Post by FourthWorld » Sun Dec 06, 2020 12:55 am

richmond62 wrote:
Sat Dec 05, 2020 5:26 pm
By monolithic I mean monolithic.

Desktop standalones generate a single file.

The HTML5 option generates 4 files: 2 of which are standalone.zip and standalone-community-9.6.1.js

BUT, you did not mention that your question/problem related to an HTML5 build, and as I have only generated
an HTML5 build twice (the second being one to see what you were on about just now) I didn't know
what you were writing about.

To avoid confusion it might not be a bad idea to contextualise things a bit more in postings.
The context is provided by the forum where he chose to post the query: "HTML5", under the "Platform-Specific" category.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9249
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Hosting Standalone.zip on a CDN

Post by richmond62 » Sun Dec 06, 2020 8:30 am

The context is provided by the forum where he chose to post the query: "HTML5", under the "Platform-Specific" category.
Ouch, sorry: tend to open posyings that pop up in the NEW listings without refering to those. My bad.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Hosting Standalone.zip on a CDN

Post by FourthWorld » Sun Dec 06, 2020 4:04 pm

richmond62 wrote:
Sun Dec 06, 2020 8:30 am
Ouch, sorry: tend to open posyings that pop up in the NEW listings without refering to those. My bad.
I've done that more than a few times myself.

No worries. I spend so much time moving threads to their appropriate section that I was uncommonly pleased to see gsillevis had taken the time to place this one so thoughtfully.

@gsillevis: You might try a CDN to see if it helps, but unless you have particularly noisy neighbors on a shared host it probably won't make a huge difference.

And beyond the download time, a good deal of the delay you see is the initialization of the LC engine JS lib, and at this time there isn't much we can do about that part.

The team is working on a new option to output the engine as WebAssembly rather than JS. It's too early to have a firm sense of the differences, but I'd guess it may shorten download times by somewhere between 20 and 30%, and reduce init time much more.

They do not yet have an estimated delivery date for that overhaul, though.

Another option may be to consider deploying a standalone that downloads everything it needs - even your UI stacks and libraries - over the web. This one-time install is often quite acceptable to the audiences for which LC's HTML export would be acceptable, but with many advantages: simpler to deploy, full scope of LC features available, UI dedicated to your app's functionality (no Back button or other features not relevant - sometimes even disruptive -of your app), integration with local OS features beyond what browsers can offer (file I/O, calling other apps, basically everything LC can do), so much more...

http://forums.livecode.com/viewtopic.php?t=15252#p76174

Streaming apps this way in LiveCode is similar to what Adobe Creative Suite, MS Office 365, and other major players have been doing in recent years, but we've had this capability since the beginning.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

Post Reply

Return to “HTML5”