Files
failsafe/failsafe.spec

83 lines
2.4 KiB
RPMSpec

#
# spec file for package failsafe
#
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: failsafe
Version: 3.3.2
Release: 0
Summary: Fault tolerance and resilience patterns for the JVM
License: Apache-2.0
Group: Development/Libraries/Java
URL: https://failsafe.dev/
Source0: https://github.com/failsafe-lib/%{name}/archive/refs/tags/%{name}-parent-%{version}.tar.gz
BuildRequires: fdupes
BuildRequires: maven-local
BuildRequires: mvn(org.apache.felix:maven-bundle-plugin)
BuildRequires: mvn(org.moditect:moditect-maven-plugin)
BuildArch: noarch
%description
Failsafe is a lightweight, zero-dependency library for handling failures in
Java 8+, with a concise API for handling everyday use cases and the flexibility
to handle everything else. It works by wrapping executable logic with one or
more resilience policies, which can be combined and composed as needed.
Policies include Retry, CircuitBreaker, RateLimiter, Timeout, Bulkhead, and
Fallback.
%package javadoc
Summary: API documentation for %{name}
Group: Documentation/HTML
%description javadoc
API documentation for %{name}.
%prep
%autosetup -n %{name}-%{name}-parent-%{version}
%pom_disable_module modules/okhttp
%pom_disable_module modules/retrofit
%pom_remove_plugin org.jacoco:jacoco-maven-plugin
%pom_remove_plugin :maven-javadoc-plugin
%pom_xpath_remove pom:jdepsExtraArgs
%pom_xpath_set pom:jvmVersion "base"
%{mvn_file} :'{*}' %{name}/@1
%build
%{mvn_build} -f -- \
%if %{?pkg_vcmp:%pkg_vcmp java-devel >= 9}%{!?pkg_vcmp:0}
-Dmaven.compiler.release=8 \
%endif
-Dsource=8
%install
%mvn_install
%fdupes %{buildroot}%{_javadocdir}/%{name}
%files -f .mfiles
%license LICENSE
%doc {CHANGELOG,CONTRIBUTING,README}.md
%doc examples
%files javadoc -f .mfiles-javadoc
%license LICENSE
%changelog