Skip to content

Commit

Permalink
Updated dependencies.
Browse files Browse the repository at this point in the history
  • Loading branch information
cowwoc committed Dec 29, 2024
1 parent edfc7ad commit b3e9e88
Show file tree
Hide file tree
Showing 5 changed files with 54 additions and 19 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.github.cowwoc.pouch/java/badge.svg)](https://search.maven.org/search?q=g:com.github.cowwoc.pouch) [![API](https://img.shields.io/badge/api_docs-5B45D5.svg)](http://cowwoc.github.io/pouch/5.2/docs/api/) [![Changelog](https://img.shields.io/badge/changelog-A345D5.svg)](docs/Changelog.md)
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.github.cowwoc.pouch/java/badge.svg)](https://search.maven.org/search?q=g:com.github.cowwoc.pouch) [![API](https://img.shields.io/badge/api_docs-5B45D5.svg)](http://cowwoc.github.io/pouch/5.3/docs/api/) [![Changelog](https://img.shields.io/badge/changelog-A345D5.svg)](docs/Changelog.md)
[![build-status](../../workflows/Build/badge.svg)](../../actions?query=workflow%3ABuild)

# <img alt="pouch" src="docs/pouch.svg" width="128" height="146"/> Pouch: Inversion of Control for the Masses
Expand All @@ -20,7 +20,7 @@ To get started, add this Maven dependency:
<dependency>
<groupId>com.github.cowwoc.pouch</groupId>
<artifactId>core</artifactId>
<version>5.2</version>
<version>5.3</version>
</dependency>
```

Expand Down Expand Up @@ -138,7 +138,7 @@ For example, notice how `AbstractDatabaseScope.getRunMode()` delegates to `JvmSc
When running in a multi-threaded environment, such as a web server, you might want to wait for ongoing HTTP
requests to complete before shutting down the server.
You can use the
[ConcurrentChildScopes](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/ConcurrentChildScopes.html)
[ConcurrentChildScopes](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/ConcurrentChildScopes.html)
class to implement this as follows:

```java
Expand Down Expand Up @@ -588,9 +588,9 @@ The scope approach makes it easier to look up multiple values, or pass the scope
The library contains two types of classes: ones that are thread-safe and ones that are not.

For example,
[ConcurrentLazyFactory](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/ConcurrentLazyFactory.html)
[ConcurrentLazyFactory](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/ConcurrentLazyFactory.html)
is the thread-safe equivalent
of [LazyFactory](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyFactory.html).
of [LazyFactory](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyFactory.html).
`LazyFactory` is faster than `ConcurrentLazyFactory`, but doesn't support access from multiple threads.
Classes that are required to support multithreaded access
(such as the application scope) must use the thread-safe classes.
Expand Down
12 changes: 6 additions & 6 deletions docs/frequently_asked_questions.md
Original file line number Diff line number Diff line change
Expand Up @@ -156,12 +156,12 @@ Ease of use and substantially reduced size.

Guava provides comparable functionality:

* [Reference](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/Reference.html) <->
* [Reference](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/Reference.html) <->
[Supplier](https://guava.dev/releases/32.1.1-jre/api/docs/com/google/common/base/Supplier.html)
* [ConstantReference](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/ConstantReference.html)
* [ConstantReference](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/ConstantReference.html)
<->
[Suppliers.ofInstance()](https://guava.dev/releases/32.1.1-jre/api/docs/com/google/common/base/Suppliers.html#ofInstance-T-)
* [LazyReference](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyReference.html) <->
* [LazyReference](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyReference.html) <->
[Suppliers.memoize()](https://guava.dev/releases/32.1.1-jre/api/docs/com/google/common/base/Suppliers.html#memoize-com.google.common.base.Supplier-)

While it is true
Expand All @@ -175,12 +175,12 @@ For example:
1. [Suppliers.memoize()](https://guava.dev/releases/32.1.1-jre/api/docs/com/google/common/base/Suppliers.html#memoize-com.google.common.base.Supplier-)
doesn't provide a mechanism for checking whether the underlying value has been initialized.
This is important because, when implementing
[Factory.close()](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/Factory.html#close()),
[Factory.close()](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/Factory.html#close()),
you'll want to avoid initializing values that have never been initialized before.
2. This library provides convenience classes such as
[LazyFactory](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyFactory.html)
[LazyFactory](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyFactory.html)
which unifies classes
[LazyReference](https://cowwoc.github.io/pouch/5.2/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyReference.html)
[LazyReference](https://cowwoc.github.io/pouch/5.3/docs/api/com.github.cowwoc.pouch.core/com/github/cowwoc/pouch/core/LazyReference.html)
and [Closeable](http://docs.oracle.com/javase/8/docs/api/java/io/Closeable.html) into a single class.

The size of the Guava library is 2.8MB.
Expand Down
5 changes: 3 additions & 2 deletions dropwizard/pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.github.cowwoc.pouch</groupId>
Expand All @@ -11,7 +12,7 @@
<description>Example of integrating Pouch with Dropwizard.</description>

<properties>
<dropwizard.version>4.0.10</dropwizard.version>
<dropwizard.version>4.0.11</dropwizard.version>
</properties>
<dependencies>
<dependency>
Expand Down
5 changes: 3 additions & 2 deletions jersey/pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.github.cowwoc.pouch</groupId>
Expand Down Expand Up @@ -74,7 +75,7 @@
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>1.5.12</version>
<version>1.5.15</version>
<scope>test</scope>
</dependency>
</dependencies>
Expand Down
41 changes: 37 additions & 4 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.github.cowwoc.pouch</groupId>
<artifactId>root</artifactId>
Expand Down Expand Up @@ -52,7 +53,7 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.version>3.9.9</maven.version>
<junit.version>5.11.3</junit.version>
<junit.version>5.11.4</junit.version>
</properties>

<build>
Expand All @@ -76,12 +77,12 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.10.1</version>
<version>3.11.2</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.5.1</version>
<version>3.5.2</version>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
Expand Down Expand Up @@ -136,6 +137,38 @@
</altReleaseDeploymentRepository>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.18.0</version>
<configuration>
<ruleSet>
<rules>
<rule>
<groupId>org.apache.maven.plugins</groupId>
<ignoreVersions>
<ignoreVersion>
<type>regex</type>
<version>.+-(alpha|beta).+</version>
</ignoreVersion>
</ignoreVersions>
</rule>
<rule>
<ignoreVersions>
<ignoreVersion>
<type>regex</type>
<version>(.+-SNAPSHOT|.+-M\d)</version>
</ignoreVersion>
<ignoreVersion>
<type>regex</type>
<version>.+-(alpha|beta).+</version>
</ignoreVersion>
</ignoreVersions>
</rule>
</rules>
</ruleSet>
</configuration>
</plugin>
</plugins>
</pluginManagement>

Expand Down

0 comments on commit b3e9e88

Please sign in to comment.