Merge lp:~gandelman-a/ubuntu/lucid/facter/lp732953_876130 into lp:ubuntu/lucid-updates/facter

Proposed by Adam Gandelman
Status: Needs review
Proposed branch: lp:~gandelman-a/ubuntu/lucid/facter/lp732953_876130
Merge into: lp:ubuntu/lucid-updates/facter
Diff against target: 51 lines (+18/-2)
3 files modified
debian/changelog (+11/-0)
lib/facter/ec2.rb (+2/-1)
lib/facter/util/collection.rb (+5/-1)
To merge this branch: bzr merge lp:~gandelman-a/ubuntu/lucid/facter/lp732953_876130
Reviewer Review Type Date Requested Status
Luke Yelavich (community) Approve
Review via email: mp+80366@code.launchpad.net

Description of the change

Rebased a previous MP on lucid-updates. Properly versioned and applied patches as per feedback from James Page on original MP:

A few comments that need resolution before we can upload:

1) The branch is currently based on 1.5.6-2ubuntu2 from the lucid release pocket; it needs to be based on 1.5.6-2ubuntu2.1 from lucid-updates - this is why the merge shows a conflict in debian/changelog

2) This package in Lucid uses an earlier version of debhelper and is source format 1.0; so patches don't get automatically applied. The correct course of action (as one patch has already be directly applied in 1.5.6-2ubuntu2.1) is to directly apply the patches to the upstream source tree. Ugly but its the most minimal change for the SRU and does not impact the update that has already been made

To post a comment you must log in.
Revision history for this message
Luke Yelavich (themuso) wrote :

Uploaded, thanks for your work.

review: Approve

Unmerged revisions

14. By Adam Gandelman

Fix series

13. By Adam Gandelman

lib/facter/util/collection.rb: Backported fix from upstream commit
2255abee7bdb9b6478ca228546e3d275dbac0ec3. Reload all facts if the
requested fact is not found. Ensures consistency after facts
have been cleared. (LP: #876130)

12. By Adam Gandelman

lib/facter/ec2.rb: Properly handle ip+port when testing connectivity
of ec2 metadata service.(LP: #732953)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2011-01-26 21:36:23 +0000
+++ debian/changelog 2011-10-25 17:40:30 +0000
@@ -1,3 +1,14 @@
1facter (1.5.6-2ubuntu2.2) lucid-proposed; urgency=low
2
3 * lib/facter/ec2.rb: Properly handle ip+port when testing connectivity
4 of ec2 metadata service.(LP: #732953)
5 * lib/facter/util/collection.rb: Backported fix from upstream commit
6 2255abee7bdb9b6478ca228546e3d275dbac0ec3. Reload all facts if the
7 requested fact is not found. Ensures consistency after facts
8 have been cleared. (LP: #876130)
9
10 -- Adam Gandelman <adamg@canonical.com> Tue, 25 Oct 2011 10:28:17 -0700
11
1facter (1.5.6-2ubuntu2.1) lucid-proposed; urgency=low12facter (1.5.6-2ubuntu2.1) lucid-proposed; urgency=low
213
3 * Cherry-picked KVM detection for 'virtual' fact from upstream commit14 * Cherry-picked KVM detection for 'virtual' fact from upstream commit
415
=== modified file 'lib/facter/ec2.rb'
--- lib/facter/ec2.rb 2009-06-30 00:21:23 +0000
+++ lib/facter/ec2.rb 2011-10-25 17:40:30 +0000
@@ -6,7 +6,8 @@
6require 'timeout'6require 'timeout'
77
8def can_connect?(ip,port,wait_sec=2)8def can_connect?(ip,port,wait_sec=2)
9 Timeout::timeout(wait_sec) {open(ip, port)}9 url = "http://#{ip}:#{port}"
10 Timeout::timeout(wait_sec) {open(url)}
10 return true11 return true
11rescue12rescue
12 return false13 return false
1314
=== modified file 'lib/facter/util/collection.rb'
--- lib/facter/util/collection.rb 2008-09-03 09:06:56 +0000
+++ lib/facter/util/collection.rb 2011-10-25 17:40:30 +0000
@@ -66,9 +66,13 @@
66 def fact(name)66 def fact(name)
67 name = canonize(name)67 name = canonize(name)
6868
69 # Try to load the fact if necessary
69 loader.load(name) unless @facts[name]70 loader.load(name) unless @facts[name]
7071
71 return @facts[name]72 # Try HARDER
73 loader.load_all unless @facts[name]
74
75 @facts[name]
72 end76 end
7377
74 # Flush all cached values.78 # Flush all cached values.

Subscribers

People subscribed via source and target branches