Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 404053 - compressed repositories don't put "compressed" property in metadata files
Summary: compressed repositories don't put "compressed" property in metadata files
Status: RESOLVED WORKSFORME
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Tycho (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-03-21 12:34 EDT by David Williams CLA
Modified: 2021-04-28 16:52 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Williams CLA 2013-03-21 12:34:34 EDT
From what I've seen, Tycho will "compress" a content.xml or artifact.xml file to a jar file when creating it, but it does not set the "internal" property of compressed. For example, in compressed repositories, I normally see these attributes at the top of a content.jar file: 

  <properties size='2'>
    <property name='p2.timestamp' value='1360014236577'/>
    <property name='p2.compressed' value='true'/>
  </properties>

One advantage of having this as an attribute of the repository file, is that even if left as *.xml, say by hand editing, or other tools, that subsequent p2 operations will "know" to leave it in compressed (jar) form.
Comment 1 Jan Sievers CLA 2013-03-21 12:41:59 EDT
we set the compress flag using the p2 mirror app [1].

could also be a bug in the p2 mirror application

[1] http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-bundles/org.eclipse.tycho.p2.tools.impl/src/main/java/org/eclipse/tycho/p2/tools/mirroring/MirrorApplicationServiceImpl.java#n179
Comment 2 Jan Sievers CLA 2013-03-21 12:49:31 EDT
using tycho demo app

http://git.eclipse.org/c/tycho/org.eclipse.tycho-demo.git/tree/itp04-rcp

I see the compressed=true property in the repository built.
Comment 3 David Williams CLA 2013-03-21 14:39:26 EDT
Thanks for looking into it. I'm not saying you should do more work here (yet) but it might work in this case because its using a target repository? One that has the compressed property. I know in the past, the (way) we got this property set was to use a small repository to "copy properties from" ... I don't even know if p2 has a direct API to set it. Just FYI.