blob: ccc25430566c616c9364a97e6eed039bdb817e0a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<TITLE> [Mageia-dev] Packaging for Mageia
</TITLE>
<LINK REL="Index" HREF="index.html" >
<LINK REL="made" HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20Packaging%20for%20Mageia&In-Reply-To=%3C20110121174856.GF14883%40mongueurs.net%3E">
<META NAME="robots" CONTENT="index,nofollow">
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
<LINK REL="Previous" HREF="002298.html">
<LINK REL="Next" HREF="002297.html">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>[Mageia-dev] Packaging for Mageia</H1>
<B>Jerome Quelin</B>
<A HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20Packaging%20for%20Mageia&In-Reply-To=%3C20110121174856.GF14883%40mongueurs.net%3E"
TITLE="[Mageia-dev] Packaging for Mageia">jquelin at gmail.com
</A><BR>
<I>Fri Jan 21 18:48:56 CET 2011</I>
<P><UL>
<LI>Previous message: <A HREF="002298.html">[Mageia-dev] Packaging for Mageia
</A></li>
<LI>Next message: <A HREF="002297.html">[Mageia-dev] Packaging for Mageia
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#2299">[ date ]</a>
<a href="thread.html#2299">[ thread ]</a>
<a href="subject.html#2299">[ subject ]</a>
<a href="author.html#2299">[ author ]</a>
</LI>
</UL>
<HR>
<!--beginarticle-->
<PRE>On 11/01/21 18:17 +0100, Thierry Vignaud wrote:
><i> On 21 January 2011 16:15, Jerome Quelin <<A HREF="https://www.mageia.org/mailman/listinfo/mageia-dev">jquelin at gmail.com</A>> wrote:
</I>><i> > note to packagers: it's now very easy to throttle in an adaptive way
</I>><i> > (thanks to pascal terjean). just add the following before submitting a
</I>><i> > package:
</I>><i> >
</I>><i> >    sleep $( HEAD <A HREF="http://pkgsubmit.mageia.org/">http://pkgsubmit.mageia.org/</A> | perl -nE '/X-BS-Throttle: (\d+)/ && print $1' )
</I>><i>
</I>><i> WOW!
</I>><i>
</I>><i> I'd use "HEAD <A HREF="http://pkgsubmit.mageia.org/">http://pkgsubmit.mageia.org/</A> | fgrep X-BS-Throttle | cut
</I>><i> -d: -f 2" instead
</I>><i> (less I/O thanks to not loading perl?)
</I>
since i'm not loading any modules, i'm not sure.
demonstration:
$ strace cut 2>&1 | grep open|wc -l
11
$ strace fgrep 2>&1 | grep open|wc -l
12
$ strace perl -e42 2>&1 | grep open|wc -l
22
so, your solution opens 1 more file, and forks 1 more process: i'd say perl wins.
but for such small workloads, i'd say it's even. especially since it's dwarfed
by the internet access! :-)
(aren't we nerds discussing such topics?)
><i> Too sad nobody did that back at mdv in the old days
</I>><i> Hurra Pascal!
</I>
definitely. that's awesome: everybody is now treated the same way
provided we follow this rule...
jérôme
--
<A HREF="https://www.mageia.org/mailman/listinfo/mageia-dev">jquelin at gmail.com</A>
</PRE>
<!--endarticle-->
<HR>
<P><UL>
<!--threads-->
<LI>Previous message: <A HREF="002298.html">[Mageia-dev] Packaging for Mageia
</A></li>
<LI>Next message: <A HREF="002297.html">[Mageia-dev] Packaging for Mageia
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#2299">[ date ]</a>
<a href="thread.html#2299">[ thread ]</a>
<a href="subject.html#2299">[ subject ]</a>
<a href="author.html#2299">[ author ]</a>
</LI>
</UL>
<hr>
<a href="https://www.mageia.org/mailman/listinfo/mageia-dev">More information about the Mageia-dev
mailing list</a><br>
</body></html>
|