Giter Site home page Giter Site logo

shrtn's Introduction

shrtn

Simple URL shortener

I started this project to learn more about Dropwizard and building web services.

shrtn's People

Contributors

mpeng3 avatar stdvectorbool avatar

Watchers

 avatar

shrtn's Issues

Log data each time a URL is expanded

Each time a URL is expanded, log as much data as possible (either to the DB or to a dedicated logging/messaging service).

Examples of data to log include:

  • date/time of access
  • IP address of requestor
  • the URL being expanded
  • the user agent performing the expansion

This data could later be used to compute useful statistics/graphs on expansions.

Support HTTPS

"http://" protocol is currently hardcoded. This should be dynamic so that it could operate via https as well.

Basic de-duplication

Should return the same shortened URL when given a previously seen long URL. Duplicate requests for a trending site might eat up lots of storage and can also affect query cache performance.

Add validation for URLs

The UrlShortenerResource "redirectUrl" function now converts the stored String to a URI before sending the response. We should make sure that only valid URIs can be created in the DB by the user to report potential problems to the user at time of creation.

Clean up compiler warnings

maven-shade-plugin has detected that some .class files
are present in two or more JARs. When this happens, only
one single version of the class is copied in the uberjar.
Usually this is not harmful and you can skeep these
warnings, otherwise try to manually exclude artifacts
based on mvn dependency:tree -Ddetail=true and the above
output

Ability to disable shortened URLs

It should be possible to disable a malicious URL or maybe any URL (DMCA claim, etc). However, the disabled URL state should be permanent to prevent:

  • hijacking a shortened URL to point to different content
  • simply running the URL through the shortener again

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.