Skip to content

aea7/urlShortener

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

URL shortener HTTP service

Required libraries :

go get github.com/lib/pq go get github.com/gorilla/mux

or

go get github.com/gorilla/mux github.com/lib/pq

Then, just run:

go run server.go

http://localhost:8080/HcOdpM - Redirect url endpoint

To simulate concurrent connections with ApacheBench I ran:

ab -n 20000 -c 200 "127.0.0.1:8080/?url=www.google.com" and it showed no problems.

Also included 3 unit tests inside test/api_test.go To run these test under test folder run:

go test

About

URL Shortener written in Go

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages