From 305e04b8304899417225a39abeb9a6bafaae5382 Mon Sep 17 00:00:00 2001 From: MichaelDaum Date: Wed, 17 Jul 2013 12:58:58 +0200 Subject: [PATCH] exclude internal functions from pod --- .gitignore | 2 + Changes | 47 ++++++++++ MANIFEST | 12 ++- MANIFEST.SKIP | 4 + README | 6 +- SIGNATURE | 149 ++++++++++++++++-------------- lib/WebService/Cmis.pm | 23 ++--- lib/WebService/Cmis/Client.pm | 40 ++++---- lib/WebService/Cmis/Document.pm | 2 +- lib/WebService/Cmis/Folder.pm | 2 +- lib/WebService/Cmis/Object.pm | 10 +- lib/WebService/Cmis/Repository.pm | 10 +- tools/git2changelog | 8 +- 13 files changed, 184 insertions(+), 131 deletions(-) diff --git a/.gitignore b/.gitignore index 3dc2edd..b0f55fd 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,5 @@ cmis.cfg WebService-Cmis-* *.bak .prove +inc/WebService/Cmis/Test/Specific.pm +t/99-specific.t diff --git a/Changes b/Changes index e00084e..d05554d 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,51 @@ Revision history for WebService-Cmis: +2013-07-17 MichaelDaum + + * working towards broader coverage + This one basically adds support for Alfresco's new cmis endpoint based + on Apache Chemistry Open Cmis bindings while still retaining + functionality for the old one. Some people might still like talking to + the now deprecated old cmis endpoint as it might still offer features + not yet covered by Open Cmis. + + Support for Nuxeo is there now. + + With it comes a rework of the authentication services part when + allocating a rest client. We have + + - basic auth (as before), + + - cookie based authentication + + - token based auth + + - header based auth (experimental) + + The test suite now tries to document features broken in some repositories + that can't be tested by us here successfully. As we still want our tests + to cope with it there's a list of brokenFeatures keeping track of vendors and + product versions. Each breakackage comes with a link pointing to the filed + bug report as possible, e.g. ALF-19186, ALF-19186. In some cases I am really + not sure how to deal with bugs which might simply be incompatibilities among + repositories or due to my misunderstanding the CMIS specs. + + We've got a new test dependency: XML::SemanticDiff. It helped to figure out + some problematic cases, but I might take that stuff out on a later point again. + + I've added a way to deal with getSummary() / updateSummary() in a reasonable way. + These two accessed the atom summary of an entry. I'd expect that vendors make use + of as much atom features as possible while mapping their document model onto CMIS. + Unfortunately they don't. For one the old web scripts based Alfresco bindings did + just fine, whereas the new Open CMis based ones put them somewhere else inside + alfresco-specific nodes, a regression. + + Nuxeo goes with Dublin Core which makes more sense in my book. As + gettign a document's tag line seems quite important I tried to smoothen that out + in the client bindings, which sucks of course. At least I was able to read/write + a document's description again on Nuxeo, while getting back read-only on Alfresco + again (Open CMIS bindings). + 2012-10-02 MichaelDaum * fixing Bug #79914 @@ -62,6 +108,7 @@ Revision history for WebService-Cmis: * updating signature * improved tests and pod docu also: + - added {cacheEnabled} option to test suite to speed up accessing remote hosts - properly implemented getRenditions, was called getRenditionInfo before diff --git a/MANIFEST b/MANIFEST index 5ef960e..9e15964 100644 --- a/MANIFEST +++ b/MANIFEST @@ -12,11 +12,12 @@ inc/Module/Install.pm inc/Module/Install/ReadmeFromPod.pm inc/Module/Install/Win32.pm inc/Module/Install/WriteAll.pm +inc/REST/Client.pm inc/WebService/Cmis/Test/ACE.pm inc/WebService/Cmis/Test/ACL.pm inc/WebService/Cmis/Test/AtomFeed.pm -inc/WebService/Cmis/Test/ChangeFeed.pm inc/WebService/Cmis/Test/Basics.pm +inc/WebService/Cmis/Test/ChangeFeed.pm inc/WebService/Cmis/Test/Client.pm inc/WebService/Cmis/Test/Document.pm inc/WebService/Cmis/Test/Folder.pm @@ -28,6 +29,11 @@ inc/WebService/Cmis/Test/Repository.pm inc/WebService/Cmis/Test/Xml.pm lib/WebService/Cmis/ACE.pm lib/WebService/Cmis/ACL.pm +lib/WebService/Cmis/Agent/BasicAuth.pm +lib/WebService/Cmis/Agent/CookieAuth.pm +lib/WebService/Cmis/Agent/HeaderAuth.pm +lib/WebService/Cmis/Agent.pm +lib/WebService/Cmis/Agent/TokenAuth.pm lib/WebService/Cmis/AtomEntry.pm lib/WebService/Cmis/AtomFeed/ChangeEntries.pm lib/WebService/Cmis/AtomFeed/Objects.pm @@ -55,10 +61,6 @@ lib/WebService/Cmis/Property/String.pm lib/WebService/Cmis/Relationship.pm lib/WebService/Cmis/Repository.pm lib/WebService/Cmis/ServerException.pm -lib/WebService/Cmis/Agent.pm -lib/WebService/Cmis/Agent/BasicAuth.pm -lib/WebService/Cmis/Agent/TokenAuth.pm -lib/WebService/Cmis/Agent/CookieAuth.pm Makefile.PL MANIFEST MANIFEST.SKIP diff --git a/MANIFEST.SKIP b/MANIFEST.SKIP index 94a3a41..29c6da3 100644 --- a/MANIFEST.SKIP +++ b/MANIFEST.SKIP @@ -10,6 +10,10 @@ ignore.txt$ \.swp$ \.old$ \.tar.gz$ +\.tar$ +\.zip$ \.bak$ ^WebService\-Cmis\-\d\.\d\d/ ^tools/git2changelog$ +^inc/WebService/Cmis/Test/Specific.pm +^t/99.*$ diff --git a/README b/README index 9a373ae..d5ae578 100644 --- a/README +++ b/README @@ -45,10 +45,6 @@ METHODS actually implements the client, defaulting to WebService::Cmis::Client::BasicAuthClient. - writeCmisDebug($msg) - static utility to write debug output to STDERR. Set the CMIS_DEBUG - environment variable to switch on some additional debug messages. - BUGS Please report any bugs or feature requests to "bug-webservice-cmis at rt.cpan.org", or through the web interface at @@ -87,7 +83,7 @@ AUTHOR Michael Daum "" COPYRIGHT AND LICENSE - Copyright 2012 Michael Daum + Copyright 2012-2013 Michael Daum This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See diff --git a/SIGNATURE b/SIGNATURE index 649746b..815823f 100644 --- a/SIGNATURE +++ b/SIGNATURE @@ -14,12 +14,12 @@ not run its Makefile.PL or Build.PL. -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 -SHA1 a6aa623e0511e52e5a00c79b4366b312d017ff43 Changes -SHA1 b7725aa322a04f09f20980fd151d78f9babdd965 MANIFEST -SHA1 c848e901d3c945d92a788e89ef840ea47fba105a MANIFEST.SKIP +SHA1 cc506cc8988501870d71c41b781a5c19f0113187 Changes +SHA1 5fd52ea046729b89cc9ebd8500ee3400c21d4379 MANIFEST +SHA1 efe4bd6ee36dfce278895afa9fbcedd68d5125e0 MANIFEST.SKIP SHA1 3f54401b2af066045c11b58a1be7350f89c5010f META.yml -SHA1 6bc0f8cf8ee27d6584b9fcf48aeead7272f7d011 Makefile.PL -SHA1 ef01906c6da51f3d5224c49885ee83664feb5f8a README +SHA1 fd901f6ec3788840edee9a953a5059bcf0a710fe Makefile.PL +SHA1 9e2f4d8a72f231794553c66db8d9cc59840d14a9 README SHA1 8842ca38ce27ccf75e1ce8f5dfb93fa62d933b2e inc/Module/AutoInstall.pm SHA1 171ca38c5eedbe92d2f5eb1e14e1725631960bab inc/Module/Install.pm SHA1 96a9bb70b2243c1f4c00a8fa383a0e37822acd64 inc/Module/Install/AutoInstall.pm @@ -32,74 +32,87 @@ SHA1 ea2c6af29c2339be6fb78edf0924e6951eb40280 inc/Module/Install/Metadata.pm SHA1 d2e387590fc4bce3abb1a7282467cb57f6133884 inc/Module/Install/ReadmeFromPod.pm SHA1 121a3c95ebbbaea7b75df3ce7e922da7e6a0060f inc/Module/Install/Win32.pm SHA1 d9f0ea716ff81c7ae3fcaaf15cc03fb9bf4f01b1 inc/Module/Install/WriteAll.pm -SHA1 190dad3d48a8e5f165fd6a2421fec36ef4ed9d10 inc/WebService/Cmis/Test.pm +SHA1 70c08fcf4d0066eb64a2970c1f86002e9c250a2a inc/REST/Client.pm +SHA1 562cac148243ac2573f5c82170ddaac488befbdf inc/WebService/Cmis/Test.pm SHA1 4ba5b44cc0313ec6a6f1326e2eead30966255c06 inc/WebService/Cmis/Test/ACE.pm -SHA1 ee2d1f47ae8f84a119989ed5ccd87f4b523d26bc inc/WebService/Cmis/Test/ACL.pm -SHA1 05db573a7c883958346d9af2e1dfa05287c2aa30 inc/WebService/Cmis/Test/AtomFeed.pm -SHA1 2445ecd22fff096b9152e3d1a73430d5c0ab4f62 inc/WebService/Cmis/Test/Basics.pm -SHA1 35f3aa0b80e7d540d9270264c87e37932850794a inc/WebService/Cmis/Test/Client.pm -SHA1 b1557999e27cdccaf23271bf8ed296dae8efd07f inc/WebService/Cmis/Test/Document.pm +SHA1 f6e044870d3c73a174438f2b683a89be1011bb06 inc/WebService/Cmis/Test/ACL.pm +SHA1 3a5d33ff7ef67182efc310f3ae08d07e1bb0b69d inc/WebService/Cmis/Test/AtomFeed.pm +SHA1 aeb068c79b11d5396d95ba848ae5bef0edc2e068 inc/WebService/Cmis/Test/Basics.pm +SHA1 c072a8c8cef8b846f71d0cc71b10597268101974 inc/WebService/Cmis/Test/ChangeFeed.pm +SHA1 60e69604ddfefd7ba34f96612faad5f23a9bdfa1 inc/WebService/Cmis/Test/Client.pm +SHA1 d0da30f4cbd95c73ee8eb6def11ec499adf22ac0 inc/WebService/Cmis/Test/Document.pm SHA1 17cbd765372d036a6392ba21223cab15e62ad16d inc/WebService/Cmis/Test/Folder.pm -SHA1 f40e6a371d8a4c8b35b25eac52c8f3e93c204a63 inc/WebService/Cmis/Test/Object.pm -SHA1 8271611f5c7f9b6e16ef5075353f3b22a72de906 inc/WebService/Cmis/Test/ObjectType.pm +SHA1 517dc4fc87448e3bf0b132ec4842fc897200d280 inc/WebService/Cmis/Test/Object.pm +SHA1 df68115f30088fe1cb955d2b5d20688c42075e64 inc/WebService/Cmis/Test/ObjectType.pm SHA1 1f144b5820b3b21745ad9696b4e5cfa3244efa09 inc/WebService/Cmis/Test/Property.pm -SHA1 76c1d2cb7a5d583a454bfd123f7daf704d0a665b inc/WebService/Cmis/Test/Repository.pm -SHA1 c23ff77c707a789bb8be2834655595fd33546493 inc/cmis.cfg.example -SHA1 686df077052e82252cfff60730ff7685efd835c8 lib/WebService/Cmis.pm -SHA1 4efd307e6faa70ef2e2f7bbe47e484d5840ca4ea lib/WebService/Cmis/ACE.pm -SHA1 fabbeba51b3f02ef652841cee9c65cf97e4154c0 lib/WebService/Cmis/ACL.pm -SHA1 55646c5b446c2b9271353502f8450a16b9478dd6 lib/WebService/Cmis/AtomEntry.pm -SHA1 b6de73c65b46beafe045ebbc83a3943d3ae13b24 lib/WebService/Cmis/AtomFeed.pm -SHA1 0e1206c4e645e77f679db7395b4c7e5fdf9d6c65 lib/WebService/Cmis/AtomFeed/ChangeEntries.pm -SHA1 c7f71e6ea12cc31d9766f43171fd065b0c56f008 lib/WebService/Cmis/AtomFeed/ObjectTypes.pm -SHA1 c7f63942cbc7ad1848c59912d7ba669390216d32 lib/WebService/Cmis/AtomFeed/Objects.pm -SHA1 f1fa0c37b98d5713882f4736007b550bc8ee426f lib/WebService/Cmis/ChangeEntry.pm -SHA1 e40e97f8300e731cf009e207b76eef75b31f9957 lib/WebService/Cmis/Client.pm -SHA1 b375c389ab0cc30a05f733eb4f99d709b5f034d2 lib/WebService/Cmis/ClientException.pm -SHA1 2ef5b91f89b155e500fa66d47cc8dec91714b2af lib/WebService/Cmis/Document.pm -SHA1 4f64a574fd13444c9ccfb6eb2e91e956e117235e lib/WebService/Cmis/Folder.pm -SHA1 43971364b5925648c9c737947bd8fac9270dfc93 lib/WebService/Cmis/NotImplementedException.pm -SHA1 a52c47f8ad74e1f68a4a35598d4c76faaa353d29 lib/WebService/Cmis/NotSupportedException.pm -SHA1 4184e5ec56003da7362d73c53bc6f96e8766749f lib/WebService/Cmis/Object.pm -SHA1 fc133f02b03b41fa352c6b4294f240c5da343c3e lib/WebService/Cmis/ObjectType.pm -SHA1 cfbaf2ab10507df45cec1a1ac54f55cc0b8ea954 lib/WebService/Cmis/Policy.pm -SHA1 ad9587a666bacff6a06827e12c430676568d4edb lib/WebService/Cmis/Property.pm -SHA1 8648c5969248ddfd64eb8fb188d563952c6eb65f lib/WebService/Cmis/Property/Boolean.pm -SHA1 98d66419bbe391d73114237a00e775fa3e6536c1 lib/WebService/Cmis/Property/DateTime.pm -SHA1 287bd149514d15ecf55967d5f5924a9d33df5b3f lib/WebService/Cmis/Property/Decimal.pm -SHA1 c63615370d79339c2ed6a79dd66c9e04860648f9 lib/WebService/Cmis/Property/Id.pm -SHA1 21204fff98f2de23dcf8beb103659526d31853fd lib/WebService/Cmis/Property/Integer.pm -SHA1 5be26b9b80f667e94d98181ad51e1b46bd265f98 lib/WebService/Cmis/Property/String.pm -SHA1 d46ffd703d68aadf949863d47db90dfa596e2b18 lib/WebService/Cmis/PropertyDefinition.pm -SHA1 679a05c140fd632bf845d1d6eef9ac045b6ef2d1 lib/WebService/Cmis/Relationship.pm -SHA1 c82c35d2efc3791b2dedc86438f676bd2dd78c14 lib/WebService/Cmis/Repository.pm -SHA1 cda23db4a3ec536829f4d3e31de96c526c1d3870 lib/WebService/Cmis/ServerException.pm -SHA1 66e81e5bde0e453eb52e9d6772558abfe7be24fb t/00-load.t -SHA1 3ec6171779122b0bdc69937c283be11b2a15dd89 t/00-signature.t -SHA1 984b5f33ffec07df919dcf1206c8b07bc8d011c9 t/01-basics.t -SHA1 366818de8e16f0b1bce345a7c40319aa97c5a887 t/02-client.t -SHA1 f3d60c55fec1713229ce51d1a82a63baacd44bdc t/03-object.t -SHA1 392b9803316a0697a2b85c847e007183374f2616 t/04-atom-feed.t -SHA1 1eb748a458cda15a8aaf8bf72749407e9c90aef2 t/05-object-type.t -SHA1 2e15c7f543734f14928049cde1910ae65e233f57 t/06-property.t -SHA1 30c21288a348762900589951147939aa6bd7e8a2 t/07-repository.t -SHA1 ad47f119960a588c55a6e6310cccb8ce799c3a5b t/08-acl.t -SHA1 ad678e354970a4d3165329c24f40fe9cc97f57b9 t/09-folder.t -SHA1 cc60a75013c07fb9d325c31d96224fced94e6df4 t/10-document.t -SHA1 291961c62a67e365d66bf639b63348845b6e5a77 t/11-ace.t -SHA1 6afebf9bf4633b597581df7eba84c3e6a784f8c7 t/boilerplate.t +SHA1 f827e5b43a4569955df0ca25df6b46197eebf910 inc/WebService/Cmis/Test/Repository.pm +SHA1 5496005204e9b443e0353a8ccd6f7dd44011021c inc/WebService/Cmis/Test/Xml.pm +SHA1 e156b02f6ca48c24b4c01d6c73dbaa74be3d17e2 inc/cmis.cfg.example +SHA1 6c83a6bab803d060690701c2f5668460067de56a lib/WebService/Cmis.pm +SHA1 be08d3bf54d2b6f7905d86d12e8da8092cbe8450 lib/WebService/Cmis/ACE.pm +SHA1 4d7363a3d12839fb8aed0e6e2a582824249804cf lib/WebService/Cmis/ACL.pm +SHA1 45806419985e02a1d7dca1635ca8200a0781efc6 lib/WebService/Cmis/Agent.pm +SHA1 babbf685c5a50a81f68bcfac67c494e769ad1f42 lib/WebService/Cmis/Agent/BasicAuth.pm +SHA1 f20958c7c5a93f547f6911573b4b4980beb68a26 lib/WebService/Cmis/Agent/CookieAuth.pm +SHA1 c70eee2c49d52e5202edaa4955ffbcfbeafae6f0 lib/WebService/Cmis/Agent/HeaderAuth.pm +SHA1 131f07657a3f38b6582c97196e8a56fc70e52d0c lib/WebService/Cmis/Agent/TokenAuth.pm +SHA1 201b9cff65f7756a3688f56f276746633d5b1fdf lib/WebService/Cmis/AtomEntry.pm +SHA1 28e292eea81dc2a10f80d0491db7674fcf80c9b9 lib/WebService/Cmis/AtomFeed.pm +SHA1 b1d881a967e91c80a9c9279a07ab2d9177a28204 lib/WebService/Cmis/AtomFeed/ChangeEntries.pm +SHA1 f8984e4a5c644b62c70ce41d425e272b1fa30ad4 lib/WebService/Cmis/AtomFeed/ObjectTypes.pm +SHA1 ae0269aefe9735bfaa01781b0df98e8f56c55862 lib/WebService/Cmis/AtomFeed/Objects.pm +SHA1 d62ea77f00e43d2ef7144f766befdcf82ab22a6b lib/WebService/Cmis/ChangeEntry.pm +SHA1 0cb7e7fe18996e2357b89406a7f6a8ce94be89ba lib/WebService/Cmis/Client.pm +SHA1 1a9aea1f04e01548b7b6b70c14b09f95cbb15fc2 lib/WebService/Cmis/ClientException.pm +SHA1 cbd044c7ae6e7b848a90b35cba620fd02356a0b8 lib/WebService/Cmis/Document.pm +SHA1 ca5756f88f5663b52ac0e5a5eaa42dbf3ba6f4cc lib/WebService/Cmis/Folder.pm +SHA1 46419b93098e2bf7f4a52f531f5becad2bf5f65f lib/WebService/Cmis/NotImplementedException.pm +SHA1 db580754a11d5b1e5bf64bac5787e54cbd74b5bb lib/WebService/Cmis/NotSupportedException.pm +SHA1 9d3fd4f42c158b1a5017c0ab70b72e41f027707f lib/WebService/Cmis/Object.pm +SHA1 ce011366e4aebb6c1329e75da8d1bce302fbf167 lib/WebService/Cmis/ObjectType.pm +SHA1 58917d7137fd67dc35f6729866303b1e7b2d6151 lib/WebService/Cmis/Policy.pm +SHA1 2a3ae2aa2e650cb1e6eb798216db899d0e8a39c1 lib/WebService/Cmis/Property.pm +SHA1 8abfc5fc87e00d96cfd5c412ff0e27396efa7941 lib/WebService/Cmis/Property/Boolean.pm +SHA1 e981a87d5f732d3c888df1423f5ab59fd5d12beb lib/WebService/Cmis/Property/DateTime.pm +SHA1 1cba37ef7fc79441306932265a9c378b43db1c73 lib/WebService/Cmis/Property/Decimal.pm +SHA1 10f4bbdc2ddf89a63c7cd6c8d62c225418e9d501 lib/WebService/Cmis/Property/Id.pm +SHA1 45c04fabb5fd2a926bde2d4dd3c8c6e90d0d8cf3 lib/WebService/Cmis/Property/Integer.pm +SHA1 6af9881ffd3883c717dced695f1faf06fea7f0d6 lib/WebService/Cmis/Property/String.pm +SHA1 ad78ee86c59becc4088c9093238d76b628a76146 lib/WebService/Cmis/PropertyDefinition.pm +SHA1 38d1e9b6a14cd450bc67abab508dc4f8c8d974cc lib/WebService/Cmis/Relationship.pm +SHA1 52c4507e30f7c28a3cf24c8510ad57305476c899 lib/WebService/Cmis/Repository.pm +SHA1 f492bdd7a74067e07086c42da2ecfd3b55477b19 lib/WebService/Cmis/ServerException.pm +SHA1 9c239175d9490d59bc144c13db54f3859bd8e394 t/00-load.t +SHA1 cc43b70ef3e58c16a923c939cf0e8ab28ca7e509 t/00-signature.t +SHA1 125080f35b120e6ce5817fef31be418077aba656 t/01-client.t +SHA1 1aeb120a3a32edc992c881a5561fe5ca5d2d2bf3 t/01-xml.t +SHA1 0a9d2a560ec68ed496b3a372fc21117ff23fef06 t/02-basics.t +SHA1 4c5c8e9ebc554dac64f21815f9e2097c3132544d t/03-object.t +SHA1 6677aceef7ecbc953d85be2234fcc521be553e74 t/04-atom-feed.t +SHA1 acd8192b53322a948373ba8a58fe0979a8bb0280 t/04-change-feed.t +SHA1 2cf45cabb01fc422b553cdbe17a0f1f0fe7b170f t/05-object-type.t +SHA1 7fdbfc7ddf91a48df7074f9c64d17007901ec4d3 t/06-property.t +SHA1 ec360f463df85da333b4e99748a2d2ae588d69e9 t/07-repository.t +SHA1 ae248d9d5400386ab75c266946fce28987ea173b t/08-acl.t +SHA1 2725a99dadf604a176fab38b6f1264cd0f6f09c3 t/09-folder.t +SHA1 cb53ab5f2fdf5895524b8d2cdbc85ef4026e1730 t/10-document.t +SHA1 d3b8c685eb5aff96b072c5f7e1ff5e69f5fd1353 t/11-ace.t +SHA1 4b0776b50fdca6784bfa62b4e0fc8cb8e63cae84 t/data/alfresco-folder-parent.xml +SHA1 35aa2ce4ffefcf3be43b522f140c7b493ed661fe t/data/alfresco-object.xml SHA1 91734810f49f6125878087d9da7bd746a8ab46d7 t/data/free.jpg -SHA1 3d7c834a6b1b1c2834c661e4cc032c0068970528 t/manifest.t -SHA1 0b1c5a2d59be6bfa7d60c64cd964fea6a0331705 t/pod-coverage.t -SHA1 a284683173bea40e9e4679c1a044700443f8a333 t/pod.t +SHA1 de6ecc37612060efe1385b8c0cee6b554f1a44ee t/data/nuxeo-folder-parent.xml +SHA1 36d584af3e8584b604298459e2a0e844863d306c t/data/nuxeo-object.xml +SHA1 bb1a599de2481bbeb4d66ad679b47fc34431e73c t/manifest.t +SHA1 61a8deb17e202b4ecd82e0c4123913806d79b76b t/pod-coverage.t +SHA1 126d6ed4aa139d6426dd0866abcf90bdb8c459b6 t/pod.t -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) -iQEcBAEBAgAGBQJQao9KAAoJEFbHzikUeAid3zcIAK0GqLua3HfYXE0AM3Z8W9u+ -fxNrbEK8nP+3F6nK34hm4eH/6HGgTpnf7IiB6gpMwim4doqDAJJofl7pNf6fLSNB -bquOQQJSkatP0wh6AiID/WOBinJri/wIaf7zv9Y6QxsJuit+3wXIpEwoq0Z4Wu2Q -rHSPQXXosl2up5KNFVQdBc8O2Ow/V+Ox+La+VgsvqbE8Iz02aylCh7A9OOmO3Mko -hFb9vvQOkScxDil2Dx2UNg1rLV7+oiigrhtaN7HbUmqQBXrRHyPkY3o5s0dRaUyZ -DpZeSmR1Qwl9RxcScp58m14P4bM2eO62MJze3aLK6GkPdy1etcws2NeA5WEcqP8= -=j8Wj +iQEcBAEBAgAGBQJR5njmAAoJEFbHzikUeAidlSwH/iF3tW1swXrn3pnSq88eXyG1 +4a0VyaAdd9rg6IVEhwovyyJeUw8w91xHIzo5AJ6fKXsmg6KyMXt12PZZgtQHBZf0 +5mujm5YSRaJ5tgIGmbNe1VSq65ZcfD2ZLdc8Sk5uc6UIG4cxdZvLwtRwj/d1Gq6S +I5b+C3xZkS1yFY3O22UPf9RIhYcHDF9az1PrkkorRpreCVghVCcHlFbV6sR0LzTM +ZzU0gh4oZh4PYJouIGEHJFa46wvFdFAcjfbkF0u1cyRT+4pP14oxXR7bwin0FNaM +eS4XfyVdG3VdYGdoU3m6Y83OI4O4lfC4VnbdDGXo6EX4MByZMS9ev9VtZ5myaP4= +=Puv6 -----END PGP SIGNATURE----- diff --git a/lib/WebService/Cmis.pm b/lib/WebService/Cmis.pm index 76717cd..be249be 100644 --- a/lib/WebService/Cmis.pm +++ b/lib/WebService/Cmis.pm @@ -51,7 +51,7 @@ use Exporter qw(import); use Carp; $Carp::Verbose = 1; -our $VERSION = '0.08'; +our $VERSION = '0.09'; our @ISA = qw(Exporter); @@ -69,7 +69,7 @@ our @_relations = qw(ACL_REL ALLOWABLEACTIONS_REL ALTERNATE_REL CHANGE_LOG_REL D our @_collections = qw(QUERY_COLL TYPES_COLL CHECKED_OUT_COLL UNFILED_COLL ROOT_COLL); -our @_utils = qw(writeCmisDebug urlEncode); +our @_utils = qw(_writeCmisDebug _urlEncode); our @EXPORT_OK = (@_namespaces, @_contenttypes, @_relations, @_collections, @_utils); our %EXPORT_TAGS = ( @@ -149,24 +149,13 @@ sub getClient { return new WebService::Cmis::Client(@_); } -=item writeCmisDebug($msg) - -static utility to write debug output to STDERR. Set the CMIS_DEBUG -environment variable to switch on some additional debug messages. - -=cut - -sub writeCmisDebug { +# static utility to write debug output to STDERR. Set the CMIS_DEBUG environment variable to switch on some additional debug messages. +sub _writeCmisDebug { print STDERR "WebService::Cmis - $_[0]\n" if $ENV{CMIS_DEBUG}; } -=item urlEncode($text) - -encodes a string to be used as a parameter in an url - -=cut - -sub urlEncode { +#encodes a string to be used as a parameter in an url +sub _urlEncode { my $text = shift; $text =~ s/([^0-9a-zA-Z-_.:~!*'\/])/'%'.sprintf('%02x',ord($1))/ge; diff --git a/lib/WebService/Cmis/Client.pm b/lib/WebService/Cmis/Client.pm index 6be7c5f..5c9d479 100644 --- a/lib/WebService/Cmis/Client.pm +++ b/lib/WebService/Cmis/Client.pm @@ -140,7 +140,7 @@ sub new { } $params{useragent} = $userAgent; - writeCmisDebug("userAgent=$userAgent"); + _writeCmisDebug("userAgent=$userAgent"); my $this = $class->SUPER::new(%params); @@ -161,7 +161,7 @@ sub DESTROY { my $ua = $this->getUseragent; $ua->{client} = undef if defined $ua; # break cyclic links - writeCmisDebug($this->{_cacheHits}." cache hits found") if $this->{cache}; + _writeCmisDebug($this->{_cacheHits}." cache hits found") if $this->{cache}; $this->_init; } @@ -204,11 +204,11 @@ sub toString { sub _parseResponse { my $this = shift; - #writeCmisDebug("called _parseResponse"); + #_writeCmisDebug("called _parseResponse"); #print STDERR "response=".Data::Dumper->Dump([$this->{_res}])."\n"; my $content = $this->responseContent; - #writeCmisDebug("content=$content"); + #_writeCmisDebug("content=$content"); unless ($this->{xmlParser}) { $this->{xmlParser} = XML::LibXML->new; @@ -230,7 +230,7 @@ sub clearCache { my $cache = $this->{cache}; return unless defined $cache; - writeCmisDebug("clearing cache"); + _writeCmisDebug("clearing cache"); return $cache->clear(@_); } @@ -261,7 +261,7 @@ sub removeFromCache { my $path = shift; my $uri = _getUri($path, @_); - writeCmisDebug("removing from cache $uri"); + _writeCmisDebug("removing from cache $uri"); return $this->_cacheRemove($uri); } @@ -336,12 +336,12 @@ sub get { } my $uri = _getUri($url, @_); - writeCmisDebug("called get($uri)"); + _writeCmisDebug("called get($uri)"); # do it $this->GET($uri); - #writeCmisDebug("content=".$this->responseContent); + #_writeCmisDebug("content=".$this->responseContent); my $code = $this->responseCode; @@ -371,11 +371,11 @@ sub request { my $url = shift; if($this->{_cacheEntry} = $this->_cacheGet($url)) { - writeCmisDebug("found in cache: $url"); + _writeCmisDebug("found in cache: $url"); $this->{_cacheHits}++; return $this; } - #writeCmisDebug("request url=$url"); + #_writeCmisDebug("request url=$url"); my $result = $this->SUPER::request($method, $url, @_); @@ -387,7 +387,7 @@ sub request { my $code = $this->responseCode; my $cacheControl = $this->{_res}->header("Cache-Control") || ''; - #writeCmisDebug("cacheControl = $cacheControl"); + #_writeCmisDebug("cacheControl = $cacheControl"); $cacheControl = '' if $this->{overrideCacheControl}; if ($cacheControl ne 'no-cache' && $code >= 200 && $code < 300 && $this->{cache}) { my $cacheEntry = { @@ -491,11 +491,11 @@ sub post { $url = $this->{repositoryUrl}; } - writeCmisDebug("called post($url)"); + _writeCmisDebug("called post($url)"); $params{"Content-Type"} = $contentType; # if ($ENV{CMIS_DEBUG}) { -# writeCmisDebug("post params:\n * ".join("\n * ", map {"$_=$params{$_}"} keys %params)); +# _writeCmisDebug("post params:\n * ".join("\n * ", map {"$_=$params{$_}"} keys %params)); # } # do it @@ -539,9 +539,9 @@ sub put { } my $uri = _getUri($url, @_); - writeCmisDebug("called put($uri)"); - writeCmisDebug("contentType: ".$contentType); - #writeCmisDebug("payload: ".$payload); + _writeCmisDebug("called put($uri)"); + _writeCmisDebug("contentType: ".$contentType); + #_writeCmisDebug("payload: ".$payload); # auto clear the cache $this->clearCache; @@ -566,7 +566,7 @@ sub delete { my $url = shift; my $uri = _getUri($url, @_); - writeCmisDebug("called delete($uri)"); + _writeCmisDebug("called delete($uri)"); $this->DELETE($uri); @@ -591,8 +591,8 @@ sub processErrors { my $code = $this->responseCode; if ($ENV{CMIS_DEBUG}) { - writeCmisDebug("processError($code)"); - writeCmisDebug($this->responseContent); + _writeCmisDebug("processError($code)"); + _writeCmisDebug($this->responseContent); } #print STDERR "header:".$this->{_res}->as_string()."\n"; @@ -622,7 +622,7 @@ service. sub getRepositories { my $this = shift; - writeCmisDebug("called getRepositories"); + _writeCmisDebug("called getRepositories"); unless (defined $this->{repositories}) { $this->{repositories} = (); diff --git a/lib/WebService/Cmis/Document.pm b/lib/WebService/Cmis/Document.pm index ea14e46..2dc3b2e 100644 --- a/lib/WebService/Cmis/Document.pm +++ b/lib/WebService/Cmis/Document.pm @@ -237,7 +237,7 @@ sub getContentLink { $url .= '?'; $gotUrlParams = 1; } - $url .= $key.'='.urlEncode($params{$key}); + $url .= $key.'='._urlEncode($params{$key}); } return $url; diff --git a/lib/WebService/Cmis/Folder.pm b/lib/WebService/Cmis/Folder.pm index b8d949b..7d55e43 100644 --- a/lib/WebService/Cmis/Folder.pm +++ b/lib/WebService/Cmis/Folder.pm @@ -93,7 +93,7 @@ sub getChildrenLink { unless ($url) { if ($ENV{CMIS_DEBUG}) { - writeCmisDebug("Coulnd not find the children url in\n".$this->{xmlDoc}->toString(1)."\n"); + _writeCmisDebug("Coulnd not find the children url in\n".$this->{xmlDoc}->toString(1)."\n"); } throw Error::Simple("Could not find the children url"); # SMELL: do a custom exception } diff --git a/lib/WebService/Cmis/Object.pm b/lib/WebService/Cmis/Object.pm index a9247cb..3ef4b24 100644 --- a/lib/WebService/Cmis/Object.pm +++ b/lib/WebService/Cmis/Object.pm @@ -151,13 +151,13 @@ sub reload { my $id = $params{id} || $this->{id} || $this->getId(); - $byObjectIdUrl =~ s/{id}/urlEncode($id)/ge; - $byObjectIdUrl =~ s/{filter}/urlEncode($params{filter}||'')/ge; + $byObjectIdUrl =~ s/{id}/_urlEncode($id)/ge; + $byObjectIdUrl =~ s/{filter}/_urlEncode($params{filter}||'')/ge; $byObjectIdUrl =~ s/{includeAllowableActions}/WebService::Cmis::Property::Boolean->unparse($params{includeAllowableActions}||'false')/ge; $byObjectIdUrl =~ s/{includePolicyIds}/WebService::Cmis::Property::Boolean->unparse($params{includePolicyIds}||'false')/ge; $byObjectIdUrl =~ s/{includeRelationships}/WebService::Cmis::Property::Boolean->unparse($params{includeRelationships}||'')/ge; $byObjectIdUrl =~ s/{includeACL}/WebService::Cmis::Property::Boolean->unparse($params{includeACL}||'false')/ge; - $byObjectIdUrl =~ s/{renditionFilter}/urlEncode($params{renditionFilter}||'')/ge; + $byObjectIdUrl =~ s/{renditionFilter}/_urlEncode($params{renditionFilter}||'')/ge; # SMELL: returnVersion not covered by uri template my %extraParams = %{$this->{extra_params}||{}}; @@ -287,7 +287,7 @@ sub getAllowableActions { my $node; if ($this->{xmlDoc}->exists($CMIS_XPATH_ALLOWABLEACTIONS)) { - writeCmisDebug("getting allowable actions from doc"); + _writeCmisDebug("getting allowable actions from doc"); ($node) = $this->{xmlDoc}->findnodes($CMIS_XPATH_ALLOWABLEACTIONS); @@ -337,7 +337,7 @@ sub getACL { my $node; if ($this->{xmlDoc}->exists($CMIS_XPATH_ACL)) { - writeCmisDebug("getting acl from doc"); + _writeCmisDebug("getting acl from doc"); ($node) = $this->{xmlDoc}->findnodes($CMIS_XPATH_ACL); } else { my $url = $this->getLink(ACL_REL); diff --git a/lib/WebService/Cmis/Repository.pm b/lib/WebService/Cmis/Repository.pm index 9c8f129..58b621a 100644 --- a/lib/WebService/Cmis/Repository.pm +++ b/lib/WebService/Cmis/Repository.pm @@ -413,7 +413,7 @@ sub getCollection { my $link = $this->getCollectionLink($collectionType); my $result = $this->{client}->get($link, @_); - #writeCmisDebug("result=".$result->toString); + #_writeCmisDebug("result=".$result->toString); # return the result set if ($collectionType eq TYPES_COLL) { @@ -463,7 +463,7 @@ sub getCollectionLink { $this->{collectionLink}{$subNode->string_value} = $href; } } - #writeCmisDebug("collection link for $collectionType: $this->{collectionLink}{$collectionType}"); + #_writeCmisDebug("collection link for $collectionType: $this->{collectionLink}{$collectionType}"); } return $this->{collectionLink}{$collectionType}; @@ -748,11 +748,11 @@ sub createEntryXmlDoc { my $propsElement = $objectElement->appendChild($xmlDoc->createElement('cmis:properties')); foreach my $property (@{$params{properties}}) { - #writeCmisDebug("property=".$property->toString); + #_writeCmisDebug("property=".$property->toString); # a name is required for most things, but not for a checkout if ($property->getId eq 'cmis:name') { - writeCmisDebug("got cmis:name property"); + _writeCmisDebug("got cmis:name property"); $entryElement->appendTextChild("title", $property->getValue); } @@ -988,7 +988,7 @@ sub _getQueryXmlDoc { $queryElement->appendChild($optionElement); } - #writeCmisDebug("query:\n".$xmlDoc->toString(1)); + #_writeCmisDebug("query:\n".$xmlDoc->toString(1)); return $xmlDoc; } diff --git a/tools/git2changelog b/tools/git2changelog index d2ebed7..c29c739 100755 --- a/tools/git2changelog +++ b/tools/git2changelog @@ -7,11 +7,11 @@ my %changes = (); my %dates = (); my %emails = (); -my $logs=`git --no-pager log --no-merges --date=short --format="date='%ad' name='%an' email='%ae' subject='%s' body='%b'"`; +my $logs=`git --no-pager log --no-merges --date=short --format="date='%ad' name='%an' email='%ae' subject='%s' body='%b'EOL"`; -#print "logs=\n$logs\n"; +#print $logs; -while ($logs =~ /date='(.*?)' name='(.*?)' email='(.*?)' subject='(.*?)' body='\s*(.*?)\s*'/gms) { +while ($logs =~ /date='(.*?)' name='(.*?)' email='(.*?)' subject='(.*?)' body='\s*(.*?)\s*'EOL/gs) { my $date = $1; my $name = $2; my $email = $3; @@ -19,7 +19,6 @@ while ($logs =~ /date='(.*?)' name='(.*?)' email='(.*?)' subject='(.*?)' body='\ my $body = $5; $body =~ s/^/\t /gm; - $body =~ s/\n\s*?\n/\n/gm; $body =~ s/^(\s*)\*/$1\-/gm; $emails{$name} = $email; @@ -28,6 +27,7 @@ while ($logs =~ /date='(.*?)' name='(.*?)' email='(.*?)' subject='(.*?)' body='\ my $msg = $subject; $msg .= "\n".$body if $body; $msg =~ s/\s*$//m; + push @{$changes{$date}{$name}}, $msg; }