Giter Club home page Giter Club logo

httpfileuploadcomponent's Introduction

HTTP File Upload Component

Build Status Docker Build Status

About

This application allows occupants of an XMPP multi-user chat room to share data (images and such) with each-other.

More specifically, this is a Jabber Component that implements XEP-0363: HTTP File Upload

Download

The compiled application, as well as the source code, is available for download on the 'releases' page of this project.

Building

This project is using a Maven-based build process. To build this project yourself, ensure that the following are available on your local host:

  • A Java Development Kit, version 8.
  • Apache Maven 3

To build this project, invoke on a command shell:

$ mvn clean package

Upon completion, the application will be available in the target directory.

Usage

To run the application, execute

java -jar httpfileuploadcomponent-<versionnumber>-jar-with-dependencies.jar

A number of arguments can (and probably should) be added. A common execution is:

java -jar httpfileuploadcomponent-<versionnumber>-jar-with-dependencies.jar \
   --xmppHost openfire1.example.org \
   --sharedSecret hqcUrfHtgE73FktcXwfrP

This will start the application, connect it to an XMPP server with the provided shared secret, and launch a webserver on a non-local interface of the machine on which the application is executed.

When end-users should interact with the webserver using a different address, the announcedWebHost argument can be used. This provides a convenient way to work with remote proxies or port-forwarded network topologies.

A full set of usage instructions are provided by adding the --help argument:

$ java -jar httpfileuploadcomponent-1.0-jar-with-dependencies.jar --help
usage: arguments
        --announcedWebHost <arg>       The hostname or IP address that is to
                                       be used by the end users (when
                                       different from webHost). Defaults to
                                       the webHost address.
        --announcedWebPort <arg>       The TCP port number that is to be used
                                       by the end users (when different from
                                       webPort). Defaults to the webPort
                                       value.
        --announcedWebProtocol <arg>   The Protocol that is to be used by the
                                       end users. Defaults to http
        --domain <arg>                 The domain that will be used for the
                                       component with the XMPP domain.
        --fileRepo <arg>               Store files in a directory provided by
                                       the file system. Provide the desired
                                       path as a value. Path must exist.
     -h,--help                         Displays this help text.
        --maxFileSize <arg>            The maximum allowed size per file, in
                                       bytes. Use -1 to disable file size
                                       limit. Defaults to 5242880 (five MB).
        --sharedSecret <arg>           The shared secret, that authenticates
                                       this component with the XMPP domain.
        --tempFileRepo                 Store files in the temporary directory
                                       provided by the file system.
        --webHost <arg>                The hostname or IP address on which the
                                       webserver will be ran. Defaults to an
                                       arbitrary, non-local address of this
                                       machine.
        --webPort <arg>                The TCP port number of the webserver.
                                       Defaults to 12121.
        --xmppHost <arg>               The FQDN or IP address (not XMPP domain
                                       name) of the XMPP domain that this
                                       component will connect to. Defaults to
                                       'localhost'.
        --xmppPort <arg>               The TCP port number on the xmppHost, to
                                       which a connection will be made.
                                       Defaults to 5275.

httpfileuploadcomponent's People

Contributors

deleolajide avatar fank avatar guusdk avatar

Watchers

 avatar  avatar

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.