Accepting request 297789 from devel:languages:perl:autoupdate

automatic update

OBS-URL: https://build.opensuse.org/request/show/297789
OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Dancer-Plugin-Database?expand=0&rev=9
This commit is contained in:
Stephan Kulow
2015-04-17 17:31:54 +00:00
committed by Git OBS Bridge
parent 229bffc91d
commit e34f594cd8
6 changed files with 214 additions and 33 deletions

View File

@@ -1,7 +1,7 @@
#
# spec file for package perl-Dancer-Plugin-Database (Version 0.08)
# spec file for package perl-Dancer-Plugin-Database
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -15,34 +15,50 @@
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# norootforbuild
Name: perl-Dancer-Plugin-Database
Version: 2.10
Release: 0
%define cpan_name Dancer-Plugin-Database
Summary: Easy database connections for Dancer applications
Version: 1.24
Release: 1
License: GPL+ or Artistic
Summary: Easy Database Connections for Dancer Applications
License: Artistic-1.0 or GPL-1.0+
Group: Development/Libraries/Perl
Url: http://search.cpan.org/dist/Dancer-Plugin-Database/
#Source: http://www.cpan.org/authors/id/B/BI/BIGPRESH/Dancer-Plugin-Database-%{version}.tar.gz
Source: %{cpan_name}-%{version}.tar.bz2
Source0: http://www.cpan.org/authors/id/A/AM/AMBS/%{cpan_name}-%{version}.tar.gz
Source1: cpanspec.yml
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%{perl_requires}
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: perl(Dancer) >= 1.175
BuildRequires: perl(DBI)
BuildRequires: perl(DBD::SQLite)
BuildRequires: perl(Test::Pod)
BuildRequires: perl(Test::Pod::Coverage)
Requires: perl(Dancer) >= 1.175
Requires: perl(DBI)
BuildRequires: perl(Dancer) >= 1.3099
BuildRequires: perl(Dancer::Plugin::Database::Core) >= 0.08
Requires: perl(Dancer) >= 1.3099
Requires: perl(Dancer::Plugin::Database::Core) >= 0.08
%{perl_requires}
%description
Provides an easy way to obtain a connected DBI database handle by simply
calling the database keyword within your Dancer application.
calling the database keyword within your the Dancer manpage application
Returns a the Dancer::Plugin::Database::Core::Handle manpage object, which
is a subclass of the DBI manpage's 'DBI::db' connection handle object, so
it does everything you'd expect to do with DBI, but also adds a few
convenience methods. See the documentation for the
Dancer::Plugin::Database::Core::Handle manpage for full details of those.
Takes care of ensuring that the database handle is still connected and
valid. If the handle was last asked for more than
'connection_check_threshold' seconds ago, it will check that the connection
is still alive, using either the '$dbh->ping' method if the DBD driver
supports it, or performing a simple no-op query against the database if
not. If the connection has gone away, a new connection will be obtained and
returned. This avoids any problems for a long-running script where the
connection to the database might go away.
Care is taken that handles are not shared across processes/threads, so this
should be thread-safe with no issues with transactions etc. (Thanks to Matt
S Trout for pointing out the previous lack of thread safety. Inspiration
was drawn from DBIx::Connector.)
%prep
%setup -q -n %{cpan_name}-%{version}
@@ -56,18 +72,11 @@ calling the database keyword within your Dancer application.
%install
%perl_make_install
# do not perl_process_packlist (noarch)
# remove .packlist file
%{__rm} -rf $RPM_BUILD_ROOT%perl_vendorarch
# remove perllocal.pod file
%{__rm} -rf $RPM_BUILD_ROOT%perl_archlib
%perl_process_packlist
%perl_gen_filelist
%clean
%{__rm} -rf $RPM_BUILD_ROOT
%files -f %{name}.files
%defattr(-,root,root,-)
%defattr(-,root,root,755)
%doc Changes README
%changelog