Giter Club home page Giter Club logo

forker's Introduction

Forker

Forker is a set of utilities and helpers for executing operating system commands from Java. It can be used in a number of ways :-

Forker Client

Forker Client provides a set of utilities, OSCommand, and the ProcessBuilder replacement ForkerBuilder. See forker-client/README.md for more information.

OSCommand

Generally this is a simply case of a single call and Forker will deal with checking the exit code and redirecting or capturing standard output and error output. OS commands can be run either as the current user or as an administrator.

ForkerBuilder

The replacement to ProcessBuilder, ForkerBuilder uses different methods depending on the type of I/O used, and also allows processes to be run as an administrator (or any other user). Depending on whether input, output, or I/O is needed (which should be provided as hint to the API), popen, system or a standard process will be used.

A very useful feature is the ability to use non-blocking I/O on supported platforms, which can make for cleaner code and much better memory usage when launching lots of processes. This feature also uses vfork on Linux, which doesn't have the high fork cost associated with standard Java.

Pseudo Terminal Support

Execute commands and shells with a pseudo terminal (or 'pty'), providing command line editing and full interactive I/O. This is achieved using Pty4J. This could be used for example to create a Java based telnet or SSH terminal server.

See forker-pty/README.md

Forker Wrapper

A 'wrapper' to execute services in Java. Similar to JSW (Java Service Wrapper) and YAJSW, Forker Wrapper can be used to launch processes in the background, track the process ID, capture output to log, automatically restart a hung or crashed JVM and more. Forker Wrapper is lightweight and powerful.

See forker-wrapper/README.md

Forker Updater

Builds on Forker Wrapper to provide an Install / Update system. Currently Linux only for all features, Windows support in progress.

See forker-updater/README.md

There are several modules that cover Updater's functionality.

  • forker-updater - The core
  • forker-updater-console - Plugin for console install / updates
  • forker-updater-swt - Plugin for GUI install / updates (WIP)
  • forker-updater-example - An example installable and updateable application.
  • forker-updater-maven-plugin - Build updater images and bootstrap installers.

Forker Services

This allows you to control local system services in a cross platform way. Support is provided for Linux and Windows currently, and allows enumerating of services and their states, as well as control services and configuring their start on boot setting.

See forker-services/README.md.

Forker Pipes

Cross platform API to pipe-like OS specific streams (i.e. Unix Sockets on Linux, Named Pipes on Windows).

See forker-pipes/README.md.

forker's People

Contributors

brett-smith avatar ludup avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  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.