author | Shawn Walker <shawn.walker@oracle.com> |
Mon, 30 Aug 2010 16:11:30 -0500 | |
changeset 2055 | 552262a56a9a |
parent 2028 | b2c674e6ee28 |
child 2073 | 9fcacc9e5eaa |
permissions | -rw-r--r-- |
2055
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
1 |
Version 43: |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
2 |
Incompatible with clients using versions 0-42. |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
3 |
|
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
4 |
pkg.client.api.ImageInterface has changed as follows: |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
5 |
|
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
6 |
* A new boot environment will now only be created if required |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
7 |
for image-modifying operations (except for plan_update_all |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
8 |
which continues to always create one by default). |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
9 |
|
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
10 |
* The verbose parameter has been removed from the plan_* |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
11 |
functions. |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
12 |
|
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
13 |
* All plan_* functions now accept an additional boolean named |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
14 |
'new_be' that indicates whether a new boot environment should |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
15 |
be created for the operation. This overrides the deafult |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
16 |
behaviour that only creates one if needed. |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
17 |
|
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
18 |
pkg.client.api.PlanDescription has changed as follows: |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
19 |
|
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
20 |
* get_services(), get_varcets(), and get_actions() were added |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
21 |
to allow clients more access to plan information. |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
22 |
|
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
23 |
* A boolean property named new_be was added that indicates |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
24 |
whether the planned operation will requires a new boot |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
25 |
environment. |
552262a56a9a
16950 imageconfig set property silently converts single values to lists breaking consumers
Shawn Walker <shawn.walker@oracle.com>
parents:
2028
diff
changeset
|
26 |
|
2028
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
27 |
Version 42: |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
28 |
Incompatible with clients using versions 0-41. |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
29 |
|
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
30 |
pkg.client.api_errors has changed as follows: |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
31 |
|
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
32 |
* The MainDictParsingException class was removed |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
33 |
|
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
34 |
* The BadPublisherAlias and IndexLockedException |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
35 |
exceptions were added. |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
36 |
|
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
37 |
pkg.client.publisher has changed as follows: |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
38 |
|
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
39 |
* The inter_certs property was renamed to intermediate_certs. |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
40 |
|
2026
d1b30615bc99
9196 pkg(5) should have support for cryptographic manifest signatures
Brock Pytlik <bpytlik@sun.com>
parents:
1970
diff
changeset
|
41 |
Version 41: |
d1b30615bc99
9196 pkg(5) should have support for cryptographic manifest signatures
Brock Pytlik <bpytlik@sun.com>
parents:
1970
diff
changeset
|
42 |
Compatible with clients using versions 40-41. |
d1b30615bc99
9196 pkg(5) should have support for cryptographic manifest signatures
Brock Pytlik <bpytlik@sun.com>
parents:
1970
diff
changeset
|
43 |
|
2028
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
44 |
Allows the client to handle signed packages. This includes the |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
45 |
addition of a large number of optional parameters to the |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
46 |
client/publisher class. It also makes changes to image creation to |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
47 |
allow image properties to be set during the process. New subclasses |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
48 |
of ApiException were created to indicate different error conditions |
b2c674e6ee28
16744 repository multi-publisher on-disk format should be formalized and implemented
Shawn Walker <shawn.walker@oracle.com>
parents:
2026
diff
changeset
|
49 |
associated with signing failures. |
2026
d1b30615bc99
9196 pkg(5) should have support for cryptographic manifest signatures
Brock Pytlik <bpytlik@sun.com>
parents:
1970
diff
changeset
|
50 |
|
1970
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
51 |
Version 40: |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
52 |
Incompatible with clients using versions 0-39. |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
53 |
|
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
54 |
The pkg.client.api ImageInterface has changed as follows: |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
55 |
|
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
56 |
* The info() method no longer detects and returns multiple |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
57 |
matches for patterns and instead will return all matches |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
58 |
for a given pattern. |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
59 |
|
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
60 |
* The ImageInterface.INFO_MULTI_MATCH property has been |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
61 |
removed. |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
62 |
|
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
63 |
* The PackageInfo.PREF_PUBLISHER attribute and data has been |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
64 |
removed. |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
65 |
|
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
66 |
* Illegal patterns will cause info() to raise an exception |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
67 |
immediately. |
60471574c487
16238 client api should ignore invalid and not yet supported packages
Shawn Walker <shawn.walker@oracle.com>
parents:
1937
diff
changeset
|
68 |
|
1937
be8995c7bb8f
10924 Want ability to communicate over unix sockets
johansen <johansen@opensolaris.org>
parents:
1895
diff
changeset
|
69 |
Version 39: |
be8995c7bb8f
10924 Want ability to communicate over unix sockets
johansen <johansen@opensolaris.org>
parents:
1895
diff
changeset
|
70 |
Compatible with clients using versions 36-38. |
be8995c7bb8f
10924 Want ability to communicate over unix sockets
johansen <johansen@opensolaris.org>
parents:
1895
diff
changeset
|
71 |
|
be8995c7bb8f
10924 Want ability to communicate over unix sockets
johansen <johansen@opensolaris.org>
parents:
1895
diff
changeset
|
72 |
Introduces the notion of a system repository to the publisher |
be8995c7bb8f
10924 Want ability to communicate over unix sockets
johansen <johansen@opensolaris.org>
parents:
1895
diff
changeset
|
73 |
heirarchy. This specific type of repository is a subclass of |
be8995c7bb8f
10924 Want ability to communicate over unix sockets
johansen <johansen@opensolaris.org>
parents:
1895
diff
changeset
|
74 |
RepositoryURI. A few new api exceptions are added, too. |
be8995c7bb8f
10924 Want ability to communicate over unix sockets
johansen <johansen@opensolaris.org>
parents:
1895
diff
changeset
|
75 |
|
1895
0a260cc2a689
15762 client support for filesystem-based repository access
Shawn Walker <shawn.walker@oracle.com>
parents:
1859
diff
changeset
|
76 |
Version 38: |
0a260cc2a689
15762 client support for filesystem-based repository access
Shawn Walker <shawn.walker@oracle.com>
parents:
1859
diff
changeset
|
77 |
Compatible with clients using versions 36-37. |
0a260cc2a689
15762 client support for filesystem-based repository access
Shawn Walker <shawn.walker@oracle.com>
parents:
1859
diff
changeset
|
78 |
|
0a260cc2a689
15762 client support for filesystem-based repository access
Shawn Walker <shawn.walker@oracle.com>
parents:
1859
diff
changeset
|
79 |
The pkg.client.api now supports file-based repository access for all |
0a260cc2a689
15762 client support for filesystem-based repository access
Shawn Walker <shawn.walker@oracle.com>
parents:
1859
diff
changeset
|
80 |
operations. All related classes have been updated to support URIs |
0a260cc2a689
15762 client support for filesystem-based repository access
Shawn Walker <shawn.walker@oracle.com>
parents:
1859
diff
changeset
|
81 |
that use the 'file' scheme. |
0a260cc2a689
15762 client support for filesystem-based repository access
Shawn Walker <shawn.walker@oracle.com>
parents:
1859
diff
changeset
|
82 |
|
1859
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
83 |
Version 37: |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
84 |
Compatible with clients using version 36. |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
85 |
|
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
86 |
The pkg.client.api ImageInterface has changed as follows: |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
87 |
* Whenever an unexpected change in the state or structure |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
88 |
of the image is encountered during install, remove, or |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
89 |
update operations (such as a missing file, directory, |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
90 |
or inability to remove an item) and it cannot be |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
91 |
recovered from without user intervention, an |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
92 |
ActionExecutionError exception is raised. |
6e6e866921e7
529 client can traceback with EBUSY during action removal
Shawn Walker <shawn.walker@oracle.com>
parents:
1843
diff
changeset
|
93 |
|
1843
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
94 |
Version 36: |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
95 |
Incompatible with clients using versions 0-35. |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
96 |
|
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
97 |
The interface for pkg.client.api.remote_search has changed as follows: |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
98 |
* A new parameter, prune_versions, has been added which, when true, |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
99 |
causes remote search to remove versions a user is unlikely to be |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
100 |
interested in. |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
101 |
|
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
102 |
* The return type of remote_search and local_search has changed. Where |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
103 |
the string representation used to be returned, a FMRI object is now |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
104 |
returned. |
b9333a197e40
6177 filtering search against a particular incorporation is needed
Brock Pytlik <bpytlik@sun.com>
parents:
1835
diff
changeset
|
105 |
|
1835
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
106 |
Version 35: |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
107 |
Compatible with clients using version 34. |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
108 |
|
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
109 |
The ImageInterface class has changed as follows: |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
110 |
* A new method named parse_fmri_patterns has been added to |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
111 |
help clients parse user input and transform any valid patterns |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
112 |
into FMRI objects that can be used for comparison. See pydoc |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
113 |
'pkg.client.api' for details. |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
114 |
|
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
115 |
* New constants for the parse_fmri_patterns method were added: |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
116 |
MATCH_EXACT, MATCH_FMRI, and MATCH_GLOB. |
13fdfa2f7993
15029 pkg list can traceback if character only allowed with wildcards used
Shawn Walker <shawn.walker@oracle.com>
parents:
1795
diff
changeset
|
117 |
|
1795
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
118 |
Version 34: |
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
119 |
Incompatible with clients using versions 0-33. |
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
120 |
|
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
121 |
The pkg.client.publisher.Publisher class has changed as follows: |
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
122 |
* The deprecated get_ssl_creds() and set_origin() methods |
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
123 |
were removed. These functions have been marked as |
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
124 |
deprecated since the client API was first versioned |
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
125 |
and should not have been used by any clients. |
1b3bed835773
14856 image-create / set-publisher shouldn't require repository configuration to have origins
Shawn Walker <srw@sun.com>
parents:
1755
diff
changeset
|
126 |
|
1755
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
127 |
Version 33: |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
128 |
Compatible with clients using version 32. |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
129 |
|
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
130 |
The ImageInterface class has changed as follows: |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
131 |
* file and directory actions will now have their mode validated |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
132 |
if failure occurs during plan execution to determine if bad |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
133 |
package metadata was the cause of execution failure. In |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
134 |
addition, the client API will catch failures due to corrupt |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
135 |
or invalid package metadata and re-raise them as an |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
136 |
InvalidPackageErrors exception. |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
137 |
|
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
138 |
The pkg.client.api_errors module has changed as follows: |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
139 |
* The InvalidPackageErrors exception was added. See 'pydoc |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
140 |
pkg.client.api_errors' for details. |
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
141 |
|
1736
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
142 |
Version 32: |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
143 |
Incompatible with clients using versions 0-31. |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
144 |
|
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
145 |
The ImageInterface class has changed as follows: |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
146 |
* The add_publisher and update_publisher methods now validate |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
147 |
the image's publisher configuration against the origins of |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
148 |
the publisher. If any of the origins are found to not match, |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
149 |
an UnknownRepositoryPublishers exception will be raised. |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
150 |
If one of the new repository origins does not provide |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
151 |
publisher configuration information or it is incomplete, |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
152 |
a RepoPubConfigUnavailable exception will be raised. |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
153 |
|
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
154 |
The pkg.client.api module has changed as follows: |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
155 |
* A new method named image_create has been added. See 'pydoc |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
156 |
pkg.client.api' for details. |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
157 |
|
1755
8e1ed1373f93
9123 client traceback during install for bad file mode
Shawn Walker <srw@sun.com>
parents:
1736
diff
changeset
|
158 |
The pkg.client.api_errors module has changed as follows: |
1736
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
159 |
* UnknownRepositoryPublishers, RepoPubConfigUnavailable, and |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
160 |
UnknownErrors expections have been added for use by the |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
161 |
pkg.client.api. API consumers are reminded that they should |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
162 |
catch all ApiException class exceptions, although catching |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
163 |
specific exception subclasses for case-by-case handling in |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
164 |
addition to that is acceptable. |
727dda1e7968
11522 pkg should require publisher prefix to match repository information
Shawn Walker <srw@sun.com>
parents:
1710
diff
changeset
|
165 |
|
1710
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
166 |
Version 31: |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
167 |
Compatible with clients using version 30. |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
168 |
All image-modifying operations now lock the image for exclusive use |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
169 |
by the current thread and process. If the lock cannot be obtained, |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
170 |
an ImageLockedError exception will be raised. |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
171 |
|
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
172 |
The ImageInterface class has changed as follows: |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
173 |
* A new property named 'blocking_locks' has been added to allow |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
174 |
clients to control image locking behaviour. See 'pydoc |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
175 |
pkg.client.api.ImageInterface' for details. |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
176 |
|
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
177 |
* The prepare() and execute_plan() methods will now raise an |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
178 |
InvalidPlanError if the image state has changed since the |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
179 |
plan was originally created. This is likely the result of |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
180 |
another client or process modifying the image. |
139720e2e756
1668 image locking needed to prevent race conditions
Shawn Walker <srw@sun.com>
parents:
1685
diff
changeset
|
181 |
|
1685
51f832187af7
3005 some pkg verify errors should be warnings or informational messages
Shawn Walker <srw@sun.com>
parents:
1618
diff
changeset
|
182 |
Version 30: |
51f832187af7
3005 some pkg verify errors should be warnings or informational messages
Shawn Walker <srw@sun.com>
parents:
1618
diff
changeset
|
183 |
Incompatible with clients using versions 0-29: |
51f832187af7
3005 some pkg verify errors should be warnings or informational messages
Shawn Walker <srw@sun.com>
parents:
1618
diff
changeset
|
184 |
The ProgressTracker class has changed as follows: |
51f832187af7
3005 some pkg verify errors should be warnings or informational messages
Shawn Walker <srw@sun.com>
parents:
1618
diff
changeset
|
185 |
* ver_output_warning() and ver_output_info() were added so that |
51f832187af7
3005 some pkg verify errors should be warnings or informational messages
Shawn Walker <srw@sun.com>
parents:
1618
diff
changeset
|
186 |
callers can choose to output warning and info verification |
51f832187af7
3005 some pkg verify errors should be warnings or informational messages
Shawn Walker <srw@sun.com>
parents:
1618
diff
changeset
|
187 |
messages separately from errors. |
51f832187af7
3005 some pkg verify errors should be warnings or informational messages
Shawn Walker <srw@sun.com>
parents:
1618
diff
changeset
|
188 |
|
1618
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
189 |
Version 29: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
190 |
Incompatible with clients using versions 0-28: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
191 |
The ImageInterface class has changed as follows: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
192 |
* set_plan_license_status() was added. This is used to indicate |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
193 |
whether licenses for the packages being operated on have been |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
194 |
accepted or displayed. Clients must do this if the related |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
195 |
license requires acceptance or display. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
196 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
197 |
The LicenseInfo class has changed as follows: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
198 |
* get_text() may now trigger a remote retrieval of the license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
199 |
payload if needed to return the text. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
200 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
201 |
* The related package FMRI and license attributes are now |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
202 |
properties: fmri, license, must_accept, and must_display. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
203 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
204 |
The PlanDescription class has changed as follows: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
205 |
* get_changes() is now a generator function. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
206 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
207 |
* get_licenses() was added to allow clients to retrieve the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
208 |
list of licenses related to the plan's operations as well |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
209 |
as the current accepted and displayed status of each. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
210 |
|
1603
84bd53597209
13019 DeprecationWarnings seen after python 2.6 migration
Dan Price <dp@eng.sun.com>
parents:
1581
diff
changeset
|
211 |
Version 28: |
84bd53597209
13019 DeprecationWarnings seen after python 2.6 migration
Dan Price <dp@eng.sun.com>
parents:
1581
diff
changeset
|
212 |
Incompatible with clients using versions 0-27: |
84bd53597209
13019 DeprecationWarnings seen after python 2.6 migration
Dan Price <dp@eng.sun.com>
parents:
1581
diff
changeset
|
213 |
CatalogRefreshException.message was changed to |
84bd53597209
13019 DeprecationWarnings seen after python 2.6 migration
Dan Price <dp@eng.sun.com>
parents:
1581
diff
changeset
|
214 |
CatalogRefreshException.errmessage to work around a change |
84bd53597209
13019 DeprecationWarnings seen after python 2.6 migration
Dan Price <dp@eng.sun.com>
parents:
1581
diff
changeset
|
215 |
introduced in python2.5 and removed in python2.6 (Exception.message, |
84bd53597209
13019 DeprecationWarnings seen after python 2.6 migration
Dan Price <dp@eng.sun.com>
parents:
1581
diff
changeset
|
216 |
if used, triggers a deprecation warning). |
84bd53597209
13019 DeprecationWarnings seen after python 2.6 migration
Dan Price <dp@eng.sun.com>
parents:
1581
diff
changeset
|
217 |
|
1581
37d9bf54ee23
13058 search makes resolve go slow
Brock Pytlik <bpytlik@sun.com>
parents:
1538
diff
changeset
|
218 |
Version 27: |
1618
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
219 |
Compatible with clients using versions 25-26: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
220 |
The get_manifest function has been added to the api to allow clients |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
1603
diff
changeset
|
221 |
to retrieve the manifest directly. |
1581
37d9bf54ee23
13058 search makes resolve go slow
Brock Pytlik <bpytlik@sun.com>
parents:
1538
diff
changeset
|
222 |
|
1538
78ac66abc186
12130 install/update operations should always refresh publisher metadata (when allowed)
Shawn Walker <srw@sun.com>
parents:
1537
diff
changeset
|
223 |
Version 26: |
78ac66abc186
12130 install/update operations should always refresh publisher metadata (when allowed)
Shawn Walker <srw@sun.com>
parents:
1537
diff
changeset
|
224 |
Compatible with clients using version 25. |
78ac66abc186
12130 install/update operations should always refresh publisher metadata (when allowed)
Shawn Walker <srw@sun.com>
parents:
1537
diff
changeset
|
225 |
The client API has changed such that an immediate refresh is always |
78ac66abc186
12130 install/update operations should always refresh publisher metadata (when allowed)
Shawn Walker <srw@sun.com>
parents:
1537
diff
changeset
|
226 |
performed when the 'refresh_catalogs' parameter is True for install, |
78ac66abc186
12130 install/update operations should always refresh publisher metadata (when allowed)
Shawn Walker <srw@sun.com>
parents:
1537
diff
changeset
|
227 |
update, and change variant operations. |
78ac66abc186
12130 install/update operations should always refresh publisher metadata (when allowed)
Shawn Walker <srw@sun.com>
parents:
1537
diff
changeset
|
228 |
|
1537 | 229 |
Version 25: |
230 |
Incompatible with clients using versions 0-24: |
|
231 |
Changes: |
|
232 |
The PackageInfo class has changed as follows: |
|
233 |
* The NOT_INSTALLED constant has been removed as checking |
|
234 |
for the presence of INSTALLED should be sufficient. |
|
235 |
||
236 |
* A new constant named 'KNOWN' has been added. It indicates |
|
237 |
that the package is currently available from a publisher's |
|
238 |
repository. |
|
239 |
||
240 |
* A new constant named 'UPGRADABLE' has been added. It |
|
241 |
indicates that a new version of the package is available. |
|
242 |
||
243 |
The following new api functions were added to ImageInterface (see |
|
244 |
'pydoc pkg.client.api.ImageInterface' for more information): |
|
245 |
* get_pkg_categories |
|
246 |
||
247 |
* get_pkg_list |
|
248 |
||
1505
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
249 |
Version 24: |
1537 | 250 |
Incompatible with clients using versions 0-23. |
1505
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
251 |
The pkg.client.api module has changed as follows: |
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
252 |
* plan_install no longer takes a filters argument |
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
253 |
* plan_change_variant changed to plan_change_varcets. |
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
254 |
w/ argument list changes. |
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
255 |
* Added get_pub_search_order |
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
256 |
* Added set_pub_search_after |
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
257 |
* Added set_pub_search_before |
cc598d70bbbe
4425 pkg install should deal w/ complex dependency changes in one install
Bart Smaalders <Bart.Smaalders@Sun.COM>
parents:
1461
diff
changeset
|
258 |
|
1461
fdf40c8c6765
820 Need a way to obsolete packages
Danek Duvall <danek.duvall@sun.com>
parents:
1389
diff
changeset
|
259 |
Version 23: |
1537 | 260 |
Incompatible with clients using versions 0-22. |
1461
fdf40c8c6765
820 Need a way to obsolete packages
Danek Duvall <danek.duvall@sun.com>
parents:
1389
diff
changeset
|
261 |
The pkg.client.api module has changed as follows: |
fdf40c8c6765
820 Need a way to obsolete packages
Danek Duvall <danek.duvall@sun.com>
parents:
1389
diff
changeset
|
262 |
* PackageInfo objects no longer take a "state" parameter, but a |
fdf40c8c6765
820 Need a way to obsolete packages
Danek Duvall <danek.duvall@sun.com>
parents:
1389
diff
changeset
|
263 |
"states" parameter, and the corresponding "state" member is now |
fdf40c8c6765
820 Need a way to obsolete packages
Danek Duvall <danek.duvall@sun.com>
parents:
1389
diff
changeset
|
264 |
"states", and is a list of states, rather than a single value. |
fdf40c8c6765
820 Need a way to obsolete packages
Danek Duvall <danek.duvall@sun.com>
parents:
1389
diff
changeset
|
265 |
|
1389
1827f487a235
8868 Changes needed to handle package descriptions in the pkg Python API.
Brock Pytlik <bpytlik@sun.com>
parents:
1352
diff
changeset
|
266 |
Version 22: |
1827f487a235
8868 Changes needed to handle package descriptions in the pkg Python API.
Brock Pytlik <bpytlik@sun.com>
parents:
1352
diff
changeset
|
267 |
Compatible with clients using version 21. |
1827f487a235
8868 Changes needed to handle package descriptions in the pkg Python API.
Brock Pytlik <bpytlik@sun.com>
parents:
1352
diff
changeset
|
268 |
Changes: |
1827f487a235
8868 Changes needed to handle package descriptions in the pkg Python API.
Brock Pytlik <bpytlik@sun.com>
parents:
1352
diff
changeset
|
269 |
Adds the description field to the PackageInfo class. |
1827f487a235
8868 Changes needed to handle package descriptions in the pkg Python API.
Brock Pytlik <bpytlik@sun.com>
parents:
1352
diff
changeset
|
270 |
|
1352
5c92c9d342ef
11065 client v1 catalog support for v0 catalogs
Shawn Walker <srw@sun.com>
parents:
1335
diff
changeset
|
271 |
Version 21: |
1537 | 272 |
Incompatible with clients using versions 0-20. |
1352
5c92c9d342ef
11065 client v1 catalog support for v0 catalogs
Shawn Walker <srw@sun.com>
parents:
1335
diff
changeset
|
273 |
Changes: |
5c92c9d342ef
11065 client v1 catalog support for v0 catalogs
Shawn Walker <srw@sun.com>
parents:
1335
diff
changeset
|
274 |
The pkg.client.api_errors module has changed as follows: |
5c92c9d342ef
11065 client v1 catalog support for v0 catalogs
Shawn Walker <srw@sun.com>
parents:
1335
diff
changeset
|
275 |
* All CatalogCacheError class exceptions were removed as the |
5c92c9d342ef
11065 client v1 catalog support for v0 catalogs
Shawn Walker <srw@sun.com>
parents:
1335
diff
changeset
|
276 |
catalog cache no longer exists. |
5c92c9d342ef
11065 client v1 catalog support for v0 catalogs
Shawn Walker <srw@sun.com>
parents:
1335
diff
changeset
|
277 |
|
1335
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
278 |
Version 20: |
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
279 |
Compatible with clients using version 19. |
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
280 |
Changes: |
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
281 |
The following exceptions were added to pkg.client.api_errors: |
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
282 |
|
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
283 |
class ReadOnlyFileSystemException(PermissionsException): |
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
284 |
"""Used to indicate that the operation was attempted on a |
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
285 |
read-only filesystem""" |
3dde2385d05c
516 Clean up traceback for installs to read-only filesystems
John Sonnenschein <John.Sonnenschein@Sun.COM>
parents:
1279
diff
changeset
|
286 |
|
1279
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
287 |
Version 19: |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
288 |
Incompatible with clients using versions 0-18. |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
289 |
Changes: |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
290 |
The ImageInterface class changed as follows: |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
291 |
* plan_update_all no longer returns a third value, the exception |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
292 |
caught. This value was never set. |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
293 |
|
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
294 |
* plan_install no longer returns a second value, the exception |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
295 |
caught. This value was never set. |
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
296 |
|
1256
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
297 |
Version 18: |
1279
12624144230f
10419 client api revisions doc update required
Shawn Walker <srw@sun.com>
parents:
1256
diff
changeset
|
298 |
Compatible with clients using versions 15-17. |
1256
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
299 |
Changes: |
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
300 |
The following exceptions were added to pkg.client.api_errors: |
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
301 |
|
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
302 |
class SetDisabledPublisherPreferred(PublisherError): |
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
303 |
"""Used to indicate an attempt to set a disabled publisher as |
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
304 |
the preferred publisher was made.""" |
921590dc232b
8863 error message unclear when trying to disable preferred publisher
Shawn Walker <srw@sun.com>
parents:
1255
diff
changeset
|
305 |
|
1255
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
306 |
Version 17: |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
307 |
Compatible with clients using versions 15-16. |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
308 |
Changes: |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
309 |
The following properties were added to pkg.client.api |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
310 |
ImageInterface class: |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
311 |
|
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
312 |
root |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
313 |
The absolute pathname of the filesystem root of the image. |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
314 |
This property is read-only. |
13914487fd06
8854 access to ImageInterface img root desired
Shawn Walker <srw@sun.com>
parents:
1254
diff
changeset
|
315 |
|
1254
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
316 |
Version 16: |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
317 |
Compatible with clients using version 15. |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
318 |
Changes: |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
319 |
The following exceptions were added to pkg.client.api_errors: |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
320 |
|
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
321 |
class NoSuchKey(CertificateError): |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
322 |
"""Used to indicate that a key could not be found.""" |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
323 |
|
1141
a74d6815a7fc
4178 unfound_fmris is a poor name
Rich Burridge <rich.burridge@sun.com>
parents:
1087
diff
changeset
|
324 |
Version 15: |
a74d6815a7fc
4178 unfound_fmris is a poor name
Rich Burridge <rich.burridge@sun.com>
parents:
1087
diff
changeset
|
325 |
Incompatible with clients using versions 1-14. |
a74d6815a7fc
4178 unfound_fmris is a poor name
Rich Burridge <rich.burridge@sun.com>
parents:
1087
diff
changeset
|
326 |
Changes: |
1254
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
327 |
The unfound_fmris variable in the |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
328 |
pkg.client.api_errors.PlanCreationException class is now called |
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
329 |
unmatched_fmris. |
1141
a74d6815a7fc
4178 unfound_fmris is a poor name
Rich Burridge <rich.burridge@sun.com>
parents:
1087
diff
changeset
|
330 |
|
1087
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
331 |
Version 14: |
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
332 |
Compatible with clients using versions 12-14. |
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
333 |
Changes: |
1254
28871b08d49c
8463 missing key file error message says certificate is missing
Shawn Walker <srw@sun.com>
parents:
1141
diff
changeset
|
334 |
The following methods were added to pkg.client.publisher.Publisher: |
1087
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
335 |
|
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
336 |
def create_meta_root(self): |
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
337 |
"""Create the publisher's meta_root.""" |
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
338 |
|
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
339 |
def remove_meta_root(self): |
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
340 |
"""Removes the publisher's meta_root.""" |
293c0aa5f32e
8214 load_catalogs should only load catalog data when needed
Shawn Walker <srw@sun.com>
parents:
996
diff
changeset
|
341 |
|
996
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
342 |
Version 13: |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
343 |
Compatible with clients using version 12. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
344 |
Changes: |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
345 |
By default, publisher repositories will be checked for new metadata no more |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
346 |
than once every four hours unless otherwise requested. Each time a |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
347 |
publisher's selected repository is checked for updates, the client will |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
348 |
store a timestamp (in UTC) marking when the refresh was performed. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
349 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
350 |
ImageInterface.refresh() has changed as follows: |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
351 |
* Changed 'full_refresh' to an optional keyword argument that defaults |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
352 |
to False. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
353 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
354 |
* Added optional boolean keyword 'immediate' that allows the client to |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
355 |
request that a publisher be checked for updates even if a check is |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
356 |
not yet needed. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
357 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
358 |
* Changed to properly use progress tracker for refreshing of publisher |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
359 |
metadata. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
360 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
361 |
* Now only refreshes publisher metadata based on the update interval |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
362 |
specified by the refresh_seconds property on the publisher's |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
363 |
selected_repository. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
364 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
365 |
ImageInterface.update_publisher() has changed as follows: |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
366 |
* When updating a publisher with 'refresh_allowed' set to False, its |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
367 |
catalog will no longer be removed. Instead, it is marked as needing |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
368 |
refresh, and the next time the client can do so, it will. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
369 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
370 |
pkg.client.publisher.Publisher has changed as follows: |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
371 |
* New property 'last_refreshed': |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
372 |
A datetime object representing the time (in UTC) the |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
373 |
publisher's selected repository was last refreshed for new |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
374 |
metadata (such as catalog updates). 'None' if the publisher |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
375 |
hasn't been refreshed yet or the time is not available. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
376 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
377 |
The above property will be automatically set by the api as needed |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
378 |
although api consumers are free to retrieve its value. Manually |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
379 |
setting this value is not recommended. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
380 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
381 |
* New property 'meta_root': |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
382 |
The absolute pathname of the directory where the publisher's |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
383 |
metadata should be written to and read from. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
384 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
385 |
The above property will be automatically set by the api as needed |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
386 |
although api consumers are free to retrieve its value. Manually |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
387 |
setting this value is not recommended. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
388 |
|
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
389 |
* New property 'needs_refresh': |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
390 |
A boolean value indicating whether the publisher's metadata for |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
391 |
the currently selected repository needs to be refreshed. |
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
392 |
|
941
e7bff46da54e
6175 search needs to be moved to version 1
Brock Pytlik <bpytlik@sun.com>
parents:
926
diff
changeset
|
393 |
Version 12: |
e7bff46da54e
6175 search needs to be moved to version 1
Brock Pytlik <bpytlik@sun.com>
parents:
926
diff
changeset
|
394 |
Incompatible with clients using versions 1-12 |
e7bff46da54e
6175 search needs to be moved to version 1
Brock Pytlik <bpytlik@sun.com>
parents:
926
diff
changeset
|
395 |
Changes: |
e7bff46da54e
6175 search needs to be moved to version 1
Brock Pytlik <bpytlik@sun.com>
parents:
926
diff
changeset
|
396 |
This versions adds local_search and remote_search to the api and removes |
e7bff46da54e
6175 search needs to be moved to version 1
Brock Pytlik <bpytlik@sun.com>
parents:
926
diff
changeset
|
397 |
those functions from pkg.client.image. |
e7bff46da54e
6175 search needs to be moved to version 1
Brock Pytlik <bpytlik@sun.com>
parents:
926
diff
changeset
|
398 |
|
926
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
399 |
Version 11: |
996
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
400 |
Incompatible with clients using versions 1-10 |
926
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
401 |
Changes: |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
402 |
This version changes all parameter names and property names from 'authority' |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
403 |
to 'publisher'. For example, parameters named 'auths' were changed to |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
404 |
'pubs'; parameters named 'authent' were changed to 'pubent' and so forth. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
405 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
406 |
In addition, the following new api functions were added to ImageInterface: |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
407 |
def add_publisher(self, pub, refresh_allowed=True): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
408 |
"""Add the provided publisher object to the image |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
409 |
configuration.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
410 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
411 |
def get_preferred_publisher(self): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
412 |
"""Returns the preferred publisher object for the image.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
413 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
414 |
def get_publisher(self, prefix=None, alias=None, duplicate=False): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
415 |
"""Retrieves a publisher object matching the provided prefix |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
416 |
(name) or alias. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
417 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
418 |
'duplicate' is an optional boolean value indicating whether |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
419 |
a copy of the publisher object should be returned instead |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
420 |
of the original. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
421 |
""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
422 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
423 |
def get_publishers(self, duplicate=False): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
424 |
"""Returns a list of the publisher objects for the current |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
425 |
image. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
426 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
427 |
'duplicate' is an optional boolean value indicating whether |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
428 |
copies of the publisher objects should be returned instead |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
429 |
of the originals. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
430 |
""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
431 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
432 |
def get_publisher_last_update_time(self, prefix=None, alias=None): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
433 |
"""Returns a datetime object representing the last time the |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
434 |
catalog for a publisher was modified or None.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
435 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
436 |
def has_publisher(self, prefix=None, alias=None): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
437 |
"""Retrieves a publisher object matching the provided prefix |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
438 |
(name) or alias.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
439 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
440 |
def remove_publisher(self, prefix=None, alias=None): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
441 |
"""Removes a publisher object matching the provided prefix |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
442 |
(name) or alias.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
443 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
444 |
def set_preferred_publisher(self, prefix=None, alias=None): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
445 |
"""Sets the preferred publisher for the image.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
446 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
447 |
def update_publisher(self, pub, refresh_allowed=True): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
448 |
"""Replaces an existing publisher object with the provided one |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
449 |
using the _source_object_id identifier set during copy.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
450 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
451 |
def update_publisher(self, pub, refresh_allowed=True): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
452 |
"""Replaces an existing publisher object with the provided one |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
453 |
using the _source_object_id identifier set during copy. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
454 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
455 |
'refresh_allowed' is an optional boolean value indicating |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
456 |
whether a refresh of publisher metadata (such as its catalog) |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
457 |
should be performed if transport information is changed for a |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
458 |
repository, mirror, or origin. If False, no attempt will be |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
459 |
made to retrieve publisher metadata.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
460 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
461 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
462 |
def log_operation_end(self, error=None, result=None): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
463 |
"""Marks the end of an operation to be recorded in image |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
464 |
history. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
465 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
466 |
'result' should be a pkg.client.history constant value |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
467 |
representing the outcome of an operation. If not provided, |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
468 |
and 'error' is provided, the final result of the operation will |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
469 |
be based on the class of 'error' and 'error' will be recorded |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
470 |
for the current operation. If 'result' and 'error' is not |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
471 |
provided, success is assumed.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
472 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
473 |
def log_operation_error(self, error): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
474 |
"""Adds an error to the list of errors to be recorded in image |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
475 |
history for the current opreation.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
476 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
477 |
def log_operation_start(self, name): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
478 |
"""Marks the start of an operation to be recorded in image |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
479 |
history.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
480 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
481 |
def parse_p5i(self, fileobj=None, location=None): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
482 |
"""Reads the pkg(5) publisher json formatted data at 'location' |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
483 |
or from the provided file-like object 'fileobj' and returns a |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
484 |
list of tuples of the format (publisher object, pkg_names). |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
485 |
pkg_names is a list of strings representing package names or |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
486 |
FMRIs. If any pkg_names not specific to a publisher were |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
487 |
provided, the last tuple returned will be of the format (None, |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
488 |
pkg_names). |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
489 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
490 |
'fileobj' is an optional file-like object that must support a |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
491 |
'read' method for retrieving data. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
492 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
493 |
'location' is an optional string value that should either start |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
494 |
with a leading slash and be pathname of a file or a URI string. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
495 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
496 |
'fileobj' or 'location' must be provided.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
497 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
498 |
def write_p5i(self, fileobj, pkg_names=None, pubs=None): |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
499 |
"""Writes the publisher, repository, and provided package names |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
500 |
to the provided file-like object 'fileobj' in json p5i format. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
501 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
502 |
'fileobj' is only required to have a 'write' method that accepts |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
503 |
data to be written as a parameter. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
504 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
505 |
'pkg_names' is a dict of lists, tuples, or sets indexed by |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
506 |
publisher prefix that contain package names, FMRI strings, or |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
507 |
package info objects. A prefix of "" can be used for packages |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
508 |
that are not specific to a publisher. |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
509 |
|
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
510 |
'pubs' is an optional list of publisher prefixes or Publisher |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
511 |
objects. If not provided, the information for all publishers |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
512 |
(excluding those disabled) will be output.""" |
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
513 |
|
917
eed22f430a9f
6902 api.info needs a "fast" flag or a way to pass a set of the information required
Brock Pytlik <bpytlik@sun.com>
parents:
884
diff
changeset
|
514 |
Version 10: |
996
31d152a5212b
7582 pkg set-publisher --no-refresh will delete catalogs
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
941
diff
changeset
|
515 |
Incompatible with clients using versions 1-9 |
917
eed22f430a9f
6902 api.info needs a "fast" flag or a way to pass a set of the information required
Brock Pytlik <bpytlik@sun.com>
parents:
884
diff
changeset
|
516 |
Changes: |
eed22f430a9f
6902 api.info needs a "fast" flag or a way to pass a set of the information required
Brock Pytlik <bpytlik@sun.com>
parents:
884
diff
changeset
|
517 |
This version changes the interface to info. It removes the action info |
920
5cb8100e9cea
6902 api.info needs a "fast" flag or a way to pass a set of the information required (followup)
Brock Pytlik <bpytlik@sun.com>
parents:
917
diff
changeset
|
518 |
and licenses flag and replaces them with a set of options to allow |
5cb8100e9cea
6902 api.info needs a "fast" flag or a way to pass a set of the information required (followup)
Brock Pytlik <bpytlik@sun.com>
parents:
917
diff
changeset
|
519 |
the caller control over which information is retrieved. |
917
eed22f430a9f
6902 api.info needs a "fast" flag or a way to pass a set of the information required
Brock Pytlik <bpytlik@sun.com>
parents:
884
diff
changeset
|
520 |
|
884
d780afc023ff
3718 plan_update_all needs to have an optional argument for the new BE name
Brock Pytlik <bpytlik@sun.com>
parents:
835
diff
changeset
|
521 |
Version 9: |
d780afc023ff
3718 plan_update_all needs to have an optional argument for the new BE name
Brock Pytlik <bpytlik@sun.com>
parents:
835
diff
changeset
|
522 |
Compatible with clients using versions 1-8 |
d780afc023ff
3718 plan_update_all needs to have an optional argument for the new BE name
Brock Pytlik <bpytlik@sun.com>
parents:
835
diff
changeset
|
523 |
Changes: |
917
eed22f430a9f
6902 api.info needs a "fast" flag or a way to pass a set of the information required
Brock Pytlik <bpytlik@sun.com>
parents:
884
diff
changeset
|
524 |
This version adds an optional argument to plan_update_all to allow the |
884
d780afc023ff
3718 plan_update_all needs to have an optional argument for the new BE name
Brock Pytlik <bpytlik@sun.com>
parents:
835
diff
changeset
|
525 |
specification of a name for the clone of the BE which is made. It also |
d780afc023ff
3718 plan_update_all needs to have an optional argument for the new BE name
Brock Pytlik <bpytlik@sun.com>
parents:
835
diff
changeset
|
526 |
exposes check_be_name as part of the api. |
d780afc023ff
3718 plan_update_all needs to have an optional argument for the new BE name
Brock Pytlik <bpytlik@sun.com>
parents:
835
diff
changeset
|
527 |
|
835
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
528 |
Version 8: |
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
529 |
Compatible with clients using versions 1-7 |
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
530 |
Changes: |
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
531 |
This version introduces InvalidDepotResponseException. The |
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
532 |
exception is thrown when operations that refresh the catalog |
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
533 |
discover that the server is not a pkg depot. Clients of the api |
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
534 |
should catch this exception and respond appropriately. |
34ec4401dc48
686 Client needs a way to tell that a response is actually from an IPS server
johansen <johansen@sun.com>
parents:
696
diff
changeset
|
535 |
|
696
6bbfd2dece6f
4371 user-agent string needs to be different for different client front-ends
Danek Duvall <danek.duvall@sun.com>
parents:
688
diff
changeset
|
536 |
Version 7: |
884
d780afc023ff
3718 plan_update_all needs to have an optional argument for the new BE name
Brock Pytlik <bpytlik@sun.com>
parents:
835
diff
changeset
|
537 |
Compatible with clients using versions 1-6 |
696
6bbfd2dece6f
4371 user-agent string needs to be different for different client front-ends
Danek Duvall <danek.duvall@sun.com>
parents:
688
diff
changeset
|
538 |
Changes: |
6bbfd2dece6f
4371 user-agent string needs to be different for different client front-ends
Danek Duvall <danek.duvall@sun.com>
parents:
688
diff
changeset
|
539 |
Ignore the pkg_client_name parameter passed to api.ImageInterface() if |
6bbfd2dece6f
4371 user-agent string needs to be different for different client front-ends
Danek Duvall <danek.duvall@sun.com>
parents:
688
diff
changeset
|
540 |
pkg.client.global_settings.client_name isn't None. This latter object |
6bbfd2dece6f
4371 user-agent string needs to be different for different client front-ends
Danek Duvall <danek.duvall@sun.com>
parents:
688
diff
changeset
|
541 |
is now the preferred way to set the client name, and the |
6bbfd2dece6f
4371 user-agent string needs to be different for different client front-ends
Danek Duvall <danek.duvall@sun.com>
parents:
688
diff
changeset
|
542 |
pkg_client_name parameter may be ignored or removed in the future. |
6bbfd2dece6f
4371 user-agent string needs to be different for different client front-ends
Danek Duvall <danek.duvall@sun.com>
parents:
688
diff
changeset
|
543 |
|
688
32a3ca40676e
4260 pkg info should print the classification
Brock Pytlik <bpytlik@sun.com>
parents:
685
diff
changeset
|
544 |
Version 6: |
32a3ca40676e
4260 pkg info should print the classification
Brock Pytlik <bpytlik@sun.com>
parents:
685
diff
changeset
|
545 |
Compatible with clients using versions 1-5 |
32a3ca40676e
4260 pkg info should print the classification
Brock Pytlik <bpytlik@sun.com>
parents:
685
diff
changeset
|
546 |
Changes: |
32a3ca40676e
4260 pkg info should print the classification
Brock Pytlik <bpytlik@sun.com>
parents:
685
diff
changeset
|
547 |
Adds a new field to PackageInfo, category_info_list, which is a list of |
32a3ca40676e
4260 pkg info should print the classification
Brock Pytlik <bpytlik@sun.com>
parents:
685
diff
changeset
|
548 |
PackageCategory objects. These objects contain the scheme and category |
32a3ca40676e
4260 pkg info should print the classification
Brock Pytlik <bpytlik@sun.com>
parents:
685
diff
changeset
|
549 |
information for packages. |
32a3ca40676e
4260 pkg info should print the classification
Brock Pytlik <bpytlik@sun.com>
parents:
685
diff
changeset
|
550 |
|
685
6f53483db920
1469 image-update by unprivileged user should give better error message
Brock Pytlik <bpytlik@sun.com>
parents:
625
diff
changeset
|
551 |
Version 5: |
6f53483db920
1469 image-update by unprivileged user should give better error message
Brock Pytlik <bpytlik@sun.com>
parents:
625
diff
changeset
|
552 |
Compatible with clients using versions 1-4 as long as they have a generic |
6f53483db920
1469 image-update by unprivileged user should give better error message
Brock Pytlik <bpytlik@sun.com>
parents:
625
diff
changeset
|
553 |
APIException. This is the case for PackageManager and UpdateManaget. |
6f53483db920
1469 image-update by unprivileged user should give better error message
Brock Pytlik <bpytlik@sun.com>
parents:
625
diff
changeset
|
554 |
Changes: |
6f53483db920
1469 image-update by unprivileged user should give better error message
Brock Pytlik <bpytlik@sun.com>
parents:
625
diff
changeset
|
555 |
plan_install and plan_update_all can now raise PermissionsException. |
6f53483db920
1469 image-update by unprivileged user should give better error message
Brock Pytlik <bpytlik@sun.com>
parents:
625
diff
changeset
|
556 |
|
625
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
557 |
Version 4: |
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
558 |
Compatible with clients using versions 1, 2, and 3 |
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
559 |
Changes: |
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
560 |
Modifies where certain progress tracking calls were made, calling |
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
561 |
evaluate_start much sooner. |
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
562 |
Adds refresh tracking to progress.py. This allows for active feedback when |
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
563 |
the catalogs of authorities are being refreshed. |
e46b345645d6
3799 need to start progress tracker going early on
Brock Pytlik <bpytlik@sun.com>
parents:
615
diff
changeset
|
564 |
|
615
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
565 |
Version 3: |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
566 |
Compatible with clients using Versions 1 and 2 |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
567 |
Changes: |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
568 |
Adds an optional argument to info which determines whether detailed information |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
569 |
about actions will be returned |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
570 |
Adds the following new fields to PackageInfo objects: links, hardlinks, |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
571 |
files, dirs, dependencies |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
572 |
|
598
c53f6107fdb6
2863 pkg install should have a way to disable indexing
Brock Pytlik <bpytlik@sun.com>
parents:
594
diff
changeset
|
573 |
Version 2: |
c53f6107fdb6
2863 pkg install should have a way to disable indexing
Brock Pytlik <bpytlik@sun.com>
parents:
594
diff
changeset
|
574 |
Compatible with clients using Version 1 |
c53f6107fdb6
2863 pkg install should have a way to disable indexing
Brock Pytlik <bpytlik@sun.com>
parents:
594
diff
changeset
|
575 |
Changes: |
c53f6107fdb6
2863 pkg install should have a way to disable indexing
Brock Pytlik <bpytlik@sun.com>
parents:
594
diff
changeset
|
576 |
Adds the optional argument update_index to plan_install, plan_uninstall, and |
615
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
577 |
plan_update_all. When the argument is false, no automatic update to the |
aeeeb9f31173
4114 Api.Info needs to provide more info
Brock Pytlik <bpytlik@sun.com>
parents:
598
diff
changeset
|
578 |
index occurs. By default, the argument is true. |
598
c53f6107fdb6
2863 pkg install should have a way to disable indexing
Brock Pytlik <bpytlik@sun.com>
parents:
594
diff
changeset
|
579 |
|
594
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
580 |
Version 1: |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
581 |
Incompatible with clients using Version 0 |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
582 |
Changes: |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
583 |
plan_install now returns a tuple of whether there is anything to do and |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
584 |
a catalog refresh exception, if one was caught. In this, it mirrors the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
585 |
first and third return values from plan_update_all. |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
586 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
587 |
Version 0: |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
588 |
def __init__(self, img_path, version_id, progesstracker, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
589 |
cancel_state_callable, pkg_client_name): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
590 |
"""Constructs an ImageInterface. img_path should point to an |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
591 |
existing image. version_id indicates the version of the api |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
592 |
the client is expecting to use. progesstracker is the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
593 |
progresstracker the client wants the api to use for UI |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
594 |
callbacks. cancel_state_callable is a function which the client |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
595 |
wishes to have called each time whether the operation can be |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
596 |
canceled changes. It can raise VersionException and |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
597 |
ImageNotFoundException.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
598 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
599 |
def plan_install(self, pkg_list, filters, refresh_catalogs=True, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
600 |
noexecute=False, verbose=False): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
601 |
"""Contructs a plan to install the packages provided in |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
602 |
pkg_list. pkg_list is a list of packages to install. filters |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
603 |
is a list of filters to apply to the actions of the installed |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
604 |
packages. refresh_catalogs controls whether the catalogs will |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
605 |
automatically be refreshed. noexecute determines whether the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
606 |
history will be recorded after planning is finished. verbose |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
607 |
controls whether verbose debugging output will be printed to the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
608 |
terminal. Its existence is temporary. If there are things to do |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
609 |
to complete the install, it returns True, otherwise it returns |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
610 |
False. It can raise InvalidCertException, PlanCreationException, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
611 |
NetworkUnavailableException, and InventoryException. The |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
612 |
noexecute argument is included for compatibility with |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
613 |
operational history. The hope is it can be removed in the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
614 |
future.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
615 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
616 |
def plan_uninstall(self, pkg_list, recursive_removal, noexecute=False, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
617 |
verbose=False): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
618 |
"""Contructs a plan to uninstall the packages provided in |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
619 |
pkg_list. pkg_list is a list of packages to install. |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
620 |
recursive_removal controls whether recursive removal is |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
621 |
allowed. noexecute determines whether the history will be |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
622 |
recorded after planning is finished. verbose controls whether |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
623 |
verbose debugging output will be printed to the terminal. Its |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
624 |
existence is temporary. If there are things to do to complete |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
625 |
the uninstall, it returns True, otherwise it returns False. It |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
626 |
can raise NonLeafPackageException and PlanCreationException.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
627 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
628 |
def plan_update_all(self, actual_cmd, refresh_catalogs=True, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
629 |
noexecute=False, force=False, pkgs_must_be_up_to_date=None, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
630 |
verbose=False): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
631 |
"""Creates a plan to update all packages on the system to the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
632 |
latest known versions. actual_cmd is the command used to start |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
633 |
the client. It is used to determine the image to check whether |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
634 |
SUNWipkg is up to date. refresh_catalogs controls whether the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
635 |
catalogs will automatically be refreshed. noexecute determines |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
636 |
whether the history will be recorded after planning is finished. |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
637 |
force controls whether update should proceed even if ipkg is not |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
638 |
up to date. verbose controls whether verbose debugging output |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
639 |
will be printed to the terminal. Its existence is temporary. It |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
640 |
returns a tuple of three things. The first is a boolean which |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
641 |
tells the client whether there is anything to do. The second |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
642 |
tells whether the image is an opensolaris image. The third is |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
643 |
either None, or an exception which indicates partial success. |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
644 |
This is currently used to indicate a failure in refreshing |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
645 |
catalogs. It can raise CatalogRefreshException, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
646 |
IpkgOutOfDateException, NetworkUnavailableException, and |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
647 |
PlanCreationException.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
648 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
649 |
def describe(self): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
650 |
"""Returns None if no plan is ready yet, otherwise returns |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
651 |
a PlanDescription""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
652 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
653 |
def prepare(self): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
654 |
"""Takes care of things which must be done before the plan |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
655 |
can be executed. This includes downloading the packages to |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
656 |
disk and preparing the indexes to be updated during |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
657 |
execution. It can raise ProblematicPermissionsIndexException, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
658 |
and PlanMissingException. Should only be called once a |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
659 |
plan_X method has been called.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
660 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
661 |
def execute_plan(self, be_name=None): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
662 |
"""Executes the plan. This is uncancelable one it begins. It |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
663 |
can raise CorruptedIndexException, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
664 |
ProblematicPermissionsIndexException, ImageplanStateException, |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
665 |
ImageUpdateOnLiveImageException, and PlanMissingException. |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
666 |
Should only be called after the prepare method has been |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
667 |
called.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
668 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
669 |
def refresh(self, full_refresh, auths=None): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
670 |
"""Refreshes the catalogs. full_refresh controls whether to do |
926
6ee411c9026a
5871 publisher apis desired
Shawn Walker <Shawn.Walker@Sun.COM>
parents:
920
diff
changeset
|
671 |
a full retrieval of the catalog from the publisher or only |
594
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
672 |
update the existing catalog. auths is a list of authorities to |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
673 |
refresh. Passing an empty list or using the default value means |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
674 |
all known authorities will be refreshed. While it currently |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
675 |
returns an image object, this is an expedient for allowing |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
676 |
existing code to work while the rest of the API is put into |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
677 |
place.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
678 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
679 |
def info(self, fmri_strings, local, get_licenses): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
680 |
"""Gathers information about fmris. fmri_strings is a list |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
681 |
of fmri_names for which information is desired. local |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
682 |
determines whether to retrieve the information locally. |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
683 |
get_licenses determines whether to retrieve the text of |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
684 |
the licenses. It returns a dictionary of lists. The keys |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
685 |
for the dictionary are the constants specified in the class |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
686 |
definition. The values are lists of PackageInfo objects or |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
687 |
strings.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
688 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
689 |
def can_be_canceled(self): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
690 |
"""Returns true if the API is in a cancelable state.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
691 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
692 |
def reset(self): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
693 |
"""Resets the API back the the initial state. Note: |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
694 |
this does not necessarily return the disk to its initial state |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
695 |
since the indexes or download cache may have been changed by |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
696 |
the prepare method.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
697 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
698 |
def cancel(self): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
699 |
"""Used for asynchronous cancelation. It returns the API |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
700 |
to the state it was in prior to the current method being |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
701 |
invoked. Canceling during a plan phase returns the API to |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
702 |
its initial state. Canceling during prepare puts the API |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
703 |
into the state it was in just after planning had completed. |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
704 |
Plan execution cannot be canceled. A call to this method blocks |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
705 |
until the canelation has happened. Note: this does not |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
706 |
necessarily return the disk to its initial state since the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
707 |
indexes or download cache may have been changed by the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
708 |
prepare method.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
709 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
710 |
class PlanDescription(object): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
711 |
"""A class which describes the changes the plan will make. It |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
712 |
provides a list of tuples of PackageInfo's. The first item in the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
713 |
tuple is the package that is being changed. The second item in the |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
714 |
tuple is the package that will be in the image after the change.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
715 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
716 |
def get_changes(self): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
717 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
718 |
class LicenseInfo(object): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
719 |
"""A class representing the license information a package |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
720 |
provides.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
721 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
722 |
def get_text(self): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
723 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
724 |
class PackageInfo(object): |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
725 |
"""A class capturing the information about packages that a client |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
726 |
could need. The fmri is guaranteed to be set. All other values may |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
727 |
be None, depending on how the PackageInfo instance was created.""" |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
728 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
729 |
# Possible package installation states |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
730 |
INSTALLED = 1 |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
731 |
NOT_INSTALLED = 2 |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
732 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
733 |
self.pkg_stem |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
734 |
self.summary |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
735 |
self.state |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
736 |
self.authority |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
737 |
self.preferred_authority |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
738 |
self.version |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
739 |
self.build_release |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
740 |
self.branch |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
741 |
self.packaging_date |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
742 |
self.size |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
743 |
self.fmri |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
744 |
self.licenses |
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
745 |
|
b072bc027c54
3770 pkg install when authority unavailable traces back
Brock Pytlik <bpytlik@sun.com>
parents:
diff
changeset
|
746 |
def __str__(self): |