When you upload data visualisation dll basically spits back a 12kb mostly empty dll, suggest until classes can be chosen separately (e.g. bing route, bing search, veimagery) maybe a message could be displayed and the dll excluded from optimization.
7 Answers, 1 is accepted
Thank you for your comments and feedback. I really like the phrase "dead code eliminator" - describes the tool idea the best.
Currently we don't support minifying the DataVisualization assembly, but you are right that we should prompt a message saying that.
I logged it and we will fix it soon.
the Telerik team
At first glace, its seemed that if we included Slider, RadioButtons, and ToggleButton (at least in addition to the controls we directly used) the Map control would load ok -- but it has a dependency on Telerik.WIndows.Media.Brushes.Transparent , defined in Telerik.WIndows.Controls.dll, in the code that we cannot get the minimizer to include.
Other than that simple brush definition, RadMap seemed to work well. But since we cannot get that Brush definition to become part of the minifier output -- we will have to ship the full 1075KB Telerik.Windows.Controls instead of the minified 581kb version that we would otherwise need.
With the minified assembly, RadMap works fine with the dynamic layer, zooming, searching, etc. It only has a problem when you hover over the zoomlevel or view buttons:
at Telerik.Windows.Controls.Map.HACKS.ForceTransparentPopupBackgroundOnDropDownButton(RadDropDownButton dropDownButton)
at Telerik.Windows.Controls.Map.MapZoomBar.MapCommandDropDownOpening(Object sender, RoutedEventArgs e)
We may investigate suppressing the commandbar from the radmap style for now, but it seems like minifier should just have a 'RadMap Dependencies' option for the Telerik.Windows.Controls assembly
Thank you for reporting this. We will consider an option for your case.
On a side note with up coming Q3 we will ship new service - Xap Minifier, that will automatically detect what controls and code you use in your xap and removes the rest.
the Telerik team
Currently we minify our telerik libraries and just copied the *.extmap.xml files from the full version into our 'minified' reference folder. THis allows us to continue to gain the benifit of not re-downloading the telerik assemblies as our application changes and reducing the intiial deployment time.
Secondarily, I hope that this new minifier is still a online service that will resign the minified assemblies with the same public key/version as the full version so that the assemblies can be swapped out without special builds.
If we had to do a onetime build wo/library caching just to get all of our telerik assemblies into the xap and then get the minified results, that would be acceptable if necessary, but it would be optimal to continue to be able to upload the DLLs directly or our XAP and the telerik ZIP files from the clientbin.
Anyway, would prefer not to have to rely on a manual, online process do do the job. Much rather have an .exe that runs locally and that can be easily run from the build process, the importantly thing being it is easy to automate into each build.
I think how you position and develop the minifier further will be quite important and there are strategy implications here. The minifiier is particularly useful for smaller projects or ones that don't require obfusication as the silverlight bloat problem can be quite bad.
not suggesting it's not useful also for big projects, but considering the marketplace strategically - I really want to see full dead code elimination, there are a number of tools available that do this like the "ComponentOne XAP Optimizer", (although personally I'd never buy there ridicously overpriced software given it doesn't do even half the job)
by half, I mean that decent obfusication (OBF) tools have dead code elimination (DCE) , and so from my perspective, ideally a product does OBF and DCE in one hit. if I was buying something then I would perceive limited value in something that does just one or the other. hence my earlier suggestion that if I require obfusication, I'm going to select a decent tool and thats hopefully going to have DCE built in.
also, you really want DCE and OBF automatically incorporated into the build and deploy process as a automatic postbuild activity, .. and obfusication tools are basically post-build anyway so thats good.
From my point of view, i assume that the minifier would have to remain a online tool if we want the assemblies resigned by telerik's private key. Perhaps some proxy app on the client could do it via a webservice or something. Regardless, it seems like something you only need to redo when you need to start using/stop using a telerik control or a new telerik build is out.
BIG thanks for your thoughts. They are really helpful for us in order to decide exactly what you need and what we should do.
Dan you are correct that it's needed to be web service in a way to get the minified assemblies signed. The first version of the xap minifier will be an add-on to the same minifer app, so you will get the resultant xap with signed telerik assemblies. But as discussed they should be in the Xap. We will have a discussion about cached assemblies and what we can do about it, so when we came up a solution - I will let you know.
According to our plans we will also ship client version integrated in the VS (possibly Q1.2011) - it will also deal with the signing, so the telerik assemblies will be sign correctly.
If you have any other ideas and/or comments, please let us know.
the Telerik team