Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a URL shortener that works with really long data URIs? [closed]

I have an app that generates web-pages as data URIs. These data URIs can be really long. I have a page that has a Data URI that is 103,828 characters long, for instance. Everything about the app works and it's no problem, it's just slightly painful to pass around urls that are 100,000 chars long :P, so I was had the wild idea of trying to use a URL shortener to shorten these URLs.

Seems like someone has written about this: http://softwareas.com/the-url-shortener-as-a-cloud-database . The author mentions character limits for popular url shortener services, and the highest seems to be tinyurl, at about 65,000 chars. Am just wondering if anyone knows of an existing solution / service that would allow shortening of such long urls (over 100,000 chars)?

Am tempted to implement my own shortener, but would like to avoid it if something exists that would allow for this.

like image 219
sanjayb Avatar asked Jul 10 '11 02:07

sanjayb


People also ask

Can you shorten a long URL?

You can shorten a URL by using an URL shortener website, which will shrink your URL for free. Popular link shorteners on the internet include Bitly, TinyURL, and Rebrandly. You'll need a premium account on these sites to unlock the full range of link customization options.

How long do URL shorteners last?

Bitly links never expire. If you use a custom domain to shorten your links they will continue to work as long as your DNS is still pointing at Bitly and the custom domain is attached to a Bitly account.


2 Answers

I think one of the main motivations for url shortening services was social networking services (such as Twitter) with message length limits. I expect that you will not likely find such a services suiting your particular desires. The article you referenced in your question was quite interesting. (especially re: TinyURL's large limit.)

Everything about the app works and it's no problem, it's just slightly painful to pass around urls that are 100,000 chars long

I might fall back on that old saying, "If it ain't broke... don't fix it."

like image 81
David Avatar answered Oct 04 '22 12:10

David


Browsers all have limit on the URL length, from what I know IE around 2083 chars, and other like Chrome are similar. Check out StackOverflow answers here:

http://9to.one/gV0XOQ

I would like to suggest you create one of those REST server by yourself, steps: * Pick a Hash algorithm * Create a REST service by using Jersey in Java or any other language you like * Use RIAK database to save your key/long_link

like image 25
9to.one Avatar answered Oct 04 '22 12:10

9to.one