History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: IDEADEV-13903
Type: New Feature New Feature
Status: Reopened Reopened
Priority: Normal Normal
Assignee: Anna Kozlova
Reporter: Keith Lea
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
IDEA: Development

"Prepare plugin module for deployment" should ignore "duplicate zip entry" errors

Created: 13 Oct 06 04:02   Updated: 05 Aug 08 20:52
Component/s: Plugin Support. Architecture
Fix Version/s: Selena 6733

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
File Attachments: 1. Text File lazy-exception.diff (2 kb)


Build: 6,043
Fixed in build: 6,730
Severity: Medium


 Description  « Hide
We have several jars which are separately added to modules that make up a plugin. Using "Prepare plugin module for deployment" produces an error and an incomplete jar, saying "error : duplicate entries in zip file"

I've attached a patch to DevKit sources that delays the exception throwing to after the zip file is built.



 All   Comments   Work Log   Change History      Sort Order:
Keith Lea - 31 Oct 06 01:01
This is a very simple patch, it's a pain keeping custom builds of builtin plugins up to date, I hope you could apply and commit the patch soon.

Dmitry Jemerov - 02 Nov 06 18:43
We could apply and commit a patch that fixes this problem properly, rather than works around it by delaying exception throwing.

Keith Lea - 02 Nov 06 20:59
When can I expect this to be fixed? As I said I don't understand the purpose of keeping "Prepare plugin" action unusable for me, until you guys have the time to come up with better solution, when this patch could be committed now without any reduction in usability, code quality, or functionality.

Keith Lea - 21 Dec 06 06:51
It's been a month and a half and this has not been fixed. If, on the other hand, my patch were applied, it would be fixed immediately. Again, this patch does not change any behavior to 99% of users - an error message is still shown when an error occurs.

Vladislav Kaznacheev - 27 Feb 07 16:46
A proper fix is implemented:
  1. If a plugin (or its dependent modules) use the same library jar or class directory, it will be jarred and zipped only once
  2. Different files/directories with the same name (e.g. copies of the same library) are jarred into files with sequential numbers appended to the file name (e.g. 3 copies of 'lib.jar' will be zipped as 'lib.jar', 'lib1.jar' and 'lib2.jar'). No attempt is made to figure out if they are actually copies of the same jar.

Keith Lea - 05 Apr 07 03:26
This fix is not useful because now there are multiple copies of dozens of jars, making the plugin archive several times larger than it needs to be.

Keith Lea - 05 Apr 07 03:26
I forgot to mention, please reopen this issue.

Vladislav Kaznacheev - 05 Apr 07 12:23
I do not think it is a good idea to treat all libraries with the same name as copies of the same library.

And if your modules refer to the same actual jar (same location in the file system), no extra copies will be created.


Keith Lea - 05 Apr 07 18:44
I don't think treating all libraries with the same name as copies is a good idea either. You need to md5sum them to determine that. My modules do not refer to the same jar location in the filesystem.

Keith Lea - 19 Apr 07 00:59
Please reopen this issue.