{"id":21665104,"url":"https://github.com/galan/commons","last_synced_at":"2025-04-12T00:32:33.092Z","repository":{"id":12892983,"uuid":"15569791","full_name":"galan/commons","owner":"galan","description":"Generic functionality, utility classes and test-helper, that have been prooven to be useful in Java","archived":false,"fork":false,"pushed_at":"2024-02-26T15:21:21.000Z","size":488,"stargazers_count":5,"open_issues_count":1,"forks_count":5,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-25T20:12:59.241Z","etag":null,"topics":["java","logging","time","utilities","utility-library"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/galan.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2014-01-01T20:39:39.000Z","updated_at":"2022-01-04T18:35:09.000Z","dependencies_parsed_at":"2024-02-26T09:51:54.635Z","dependency_job_id":"c9828dc7-5575-4fb3-ad75-4b79ce57aa9a","html_url":"https://github.com/galan/commons","commit_stats":null,"previous_names":[],"tags_count":40,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/galan%2Fcommons","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/galan%2Fcommons/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/galan%2Fcommons/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/galan%2Fcommons/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/galan","download_url":"https://codeload.github.com/galan/commons/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248501233,"owners_count":21114635,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","logging","time","utilities","utility-library"],"created_at":"2024-11-25T10:48:59.633Z","updated_at":"2025-04-12T00:32:33.066Z","avatar_url":"https://github.com/galan.png","language":"Java","readme":"[![Maven Central](https://img.shields.io/maven-central/v/de.galan/commons.svg?style=flat)](https://maven-badges.herokuapp.com/maven-central/de.galan/commons)\n[![License](https://img.shields.io/github/license/galan/commons.svg?style=flat)](https://www.apache.org/licenses/LICENSE-2.0.html)\n\n# commons\n\nSupportive basic but missing functionality, that simplifies Java delopment.\n\n\n# Integration with Maven\n\nJust add the following dependency (see [tags](https://github.com/galan/commons/tags) for latest version):\n\n    \u003cdependency\u003e\n    \t\u003cgroupId\u003ede.galan\u003c/groupId\u003e\n    \t\u003cartifactId\u003ecommons\u003c/artifactId\u003e\n    \t\u003cversion\u003ex.y.z\u003c/version\u003e\n    \u003c/dependency\u003e\n\n\n# Overview\n\n## de.galan.commons.func.supplier\n\nVarious `Supplier` for eg. Long-sequences and random alphanumeric strings.\n\n## de.galan.commons.logging\n\nLogging facades and utilities, based on log4j2-api so they can be used with any logging-framework such as log4j, log4j2, logback, slf4j, etc..\n\n* [Say](https://github.com/galan/commons/blob/master/documentation/logging.Say.md) - Facade to log without the need to declare a logger. Messages paramters can be passed as\n  MDC/ThreadContext json-field (useful for logstash). Take a look at the examples.\n* Slogr - Retrieves the Slf4j Logger without passing the actual calling class, which is a typical copy\u0026paste pitfall. Can be avoided by using Say.\n\n## de.galan.commons.net\n\n* CommonProxy - Simple wrapper for a proxy in the format [username[:password]@]host[:port]\n* UrlUtil - Decoding/encoding urls with `Charset`\n\n## de.galan.commons.net.flux\n\n* [Flux](https://github.com/galan/commons/blob/master/documentation/net.flux.Flux.md) - A fluent http/rest-client interface for Java\n\n## de.galan.commons.net.mail\n\n* MailMessenger - Sending multipart mails using a fluent interface.\n\n## de.galan.commons.test\n\n* AbstractTestParent - Resets the `ApplicationClock` and prints the name of each test-method executed\n* FixedDateSupplier - Sets the `ApplicationClock` to a fixed time (best used with Instants)\n* SimpleWebserverTestParent - Test containing an lightweight\n  http-server ([simpleframework](http://www.simpleframework.org/)).\n* Tests - Helping methods in tests for eg. loading and comparing test resources, some date assertions, test directory handling.\n\n## de.galan.commons.time\n\n* ApplicationClock - Clock that acts as time emitter for an application. Uses a java.time.clock.SystemClock (UTC) by default.\n* [Durations](https://github.com/galan/commons/blob/master/documentation/time.Durations.md) - Utility class to handle and calculate human readable time durations, such as \"2h 30m\"\n* [Instants](https://github.com/galan/commons/blob/master/documentation/time.Instants.md) - Fluent simplified time creation and modification.\n* [Times](https://github.com/galan/commons/blob/master/documentation/time.Times.md) - Fluent time comparision\n* Sleeper - Sleeps a duration (long or human readable String - as in `Durations`) without throwing an InterruptedException\n\n## de.galan.commons.util\n\nVarious common functionality, eg.\n\n* BOM - Adding and remove BOM (byteordermark) UTF-8 headers\n* Contained - Checks if an element is in an (vararg) array\n* Generics - Helper for generics, eg casting to get rid of unchecked warnings.\n* JvmUtil - Provides access to information about the currently running JVM and some process-control (eg. fluent Termination of JVM, ShutdownHook methods).\n* JmxUtil - Helpermethod to register MBeans\n* [Measure](https://github.com/galan/commons/blob/master/documentation/util.Measure.md) - Measures and logs duration of Callable or Runnables, if required only every n-invokations.\n* MessageBox - Draws a nice messagebox to the logged output.\n* Pair - Simplified key/value class\n* [Retryable](https://github.com/galan/commons/blob/master/documentation/util.Retryable.md) - Runs a `Callable` or `ExceptionalRunnable` (`Runnable` with Exceptions) until it runs\n  without Exception at least for the specified times of retries in a compact fluent manner.\n\n\n# Changelog\n\nRead the [CHANGELOG.md](CHANGELOG.md) for curated release information.\n\n\n# Compatibility\n\n* Latest Java 8 version: 0.16.4\n* Latest Java 11 version: 1.4.0\n* Starting Java 17 with 2.0.0\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgalan%2Fcommons","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgalan%2Fcommons","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgalan%2Fcommons/lists"}