Issue Details (XML | Word | Printable)

Key: JRA-13144
Type: Improvement Improvement
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Jonathan Nolen [Atlassian]
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
JIRA

Extend JIRA's system-webresources-plugin to offer all framework components

Created: 20/Jul/07 03:11 PM   Updated: 15/Feb/08 11:47 AM
Component/s: Plugins
Affects Version/s: 3.10
Fix Version/s: 3.13.x

Time Tracking:
Not Specified

Issue Links:
Reference
 

Participants: Anton Mazkovoi [Atlassian], Jed Wesley-Smith [Atlassian], Jonathan Nolen [Atlassian] and Scott Farquhar [Atlassian]
Since last comment: 39 weeks, 3 days ago
Labels:


 Description  « Hide
We should extend the system-webresources-plugin.xml so that it contains all of the various files that make up our component frameworks: Prototype, Scriptaculous, DWR and YUI. They should be individually addressable so that a plugin author can request just the ones he needs.

Secondly, we should really be using the *-min and combined versions of these files, as you can save 50% or more download time.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Anton Mazkovoi [Atlassian] added a comment - 22/Jul/07 07:32 PM - edited
Mate,

Prototype, Scriptaculous, DWR and YUI are all listed in the system-webresources-plugin.xml. I believe this should make them all avaliable via the "resources". Do you mean that a plugin author would like to only include e.g. effects.js without e.g. dragdrop.js?

If so, isn't there some dependency between these files? I am afraid that if we split them up we will then have to remember to include the dependencies each time. Also, what are we winning by splitting them up? Once they are cached on the browser side, they should never be redownloaded?

At the moment we are too chicken to ship with *-min, as all of development and testing gets done with the regular files. What is your experience with switching over to min files?

Cheers,
Anton


Jonathan Nolen [Atlassian] added a comment - 10/Sep/07 12:18 PM - edited
Sorry, Anton, I didn't see this comment a long time ago:

1. There is usually no dependency between including the various files of the javascript libraries – you are encouraged to just include the specific files you need. Based on what you try to do with the library, a particular effect may require multiple sub-files (say effects.js & dragdrop.js, but that's something to work out in development).

2. As for remembering, there is no reason why we shouldn't have several web-resource entries: one that includes everything from the library, one for each bundle of files we need for a particular effect, and then one for each individual file, so that plugin developers can request just the additional ones they need. For example, in the labels plugin I needed YUI, and someone was already including it on the page. However, they weren't using the connection.js, which I needed, and it wasn't even in the webresources xml. So that meant I had to bundle my own copy of YUI and reference that.

3. I've used *-min versions of scriptaculous and YUI in my personal projects and it has worked flawlessly, with a huge savings in download time,


Anton Mazkovoi [Atlassian] added a comment - 10/Sep/07 07:49 PM
Thanks for the update.

In JIRA 3.11 we will ship the min versions of the files.

I will see if we can split up the dependencies for JIRA 3.12. I think Scott was looking into this.

Cheers,
Anton


Scott Farquhar [Atlassian] added a comment - 14/Sep/07 03:22 AM
We should split up the dependencies into individual files, and maintain the old ones just for backwards compatibility. Once they have been split up, we should change all places in JIRA to use the new split ones. Then we should change the plugins (labels is the only one I think) that use them, and move them to the new format.

Anton Mazkovoi [Atlassian] added a comment - 16/Sep/07 08:53 PM
Also should check the Calendar and Charting plugins.

Jed Wesley-Smith [Atlassian] added a comment - 06/Dec/07 08:00 PM
The fix for this issue has not been able to make it into JIRA v3.12. We are hoping to incorporate it into v3.12.1. As of writing however, there are 163 items scheduled as Fix For v3.12.1. We will not be able to include all of them.