Red Gate forums :: View topic - Feature usage reporting with multiple assemblies
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SmartAssembly 6
SmartAssembly 6 forum

Feature usage reporting with multiple assemblies

Search in SmartAssembly 6 forum
Post new topic   Reply to topic
Jump to:  
Author Message
williamw



Joined: 02 Apr 2012
Posts: 8

PostPosted: Fri Jun 14, 2013 4:35 pm    Post subject: Feature usage reporting with multiple assemblies Reply with quote

I have an application that is built using several assemblies. Both the main executable and the assemblies contain features that I want to do usage reporting on. The assemblies are not being merged into the application but they are getting run through SmartAssembly for protection.

What do I need to do to get feature reporting for all the assemblies? Do I have to turn on the option in SmartAssembly for each assembly? Or is turning it on in the main (executable) assembly enough if I have put the attributes in the other assemblies?

If I need to configure it separately for each assembly, does the user get prompted separately when each assembly tries to report usage? If I use the same application name for all of them will that be enough?
Back to top
View user's profile Send private message
Chris.Allen



Joined: 12 Mar 2009
Posts: 585

PostPosted: Mon Jun 17, 2013 2:42 pm    Post subject: Reply with quote

You'll need to apply smartassembly to each assembly that you want this to work on. So that's one extra smartassembly project for each assembly that is not a direct dependency in the 'main' project
Back to top
View user's profile Send private message
DanielRose



Joined: 30 Oct 2009
Posts: 16
Location: Aachen, Germany

PostPosted: Tue Jun 18, 2013 10:01 am    Post subject: Reply with quote

I have the same issue in my application.

When applying feature usage reporting to the different assemblies, this results in each assembly being considered a different "version", even if the have the same application name. So even if they belong to the same application, you will see the feature reports being split up. Depending on how you handle asking the user for consent, this can also result in a prompt for each assembly.

The way I solved it was by having a method to report usage in an assembly known by all assemblies, which is wrapper over the actual call to usage reporting. That way, there is only one assembly which gets feature reporting compiled into it, and thus all feature reports for the application appear together.
Back to top
View user's profile Send private message
williamw



Joined: 02 Apr 2012
Posts: 8

PostPosted: Tue Jun 18, 2013 12:07 pm    Post subject: Reply with quote

Chris: The other assemblies are being run through SmartAssembly. Do they also have to have the usage reporting option configured in SmartAssembly? What do you mean by "direct dependency"? They are directly referenced by the main executable assembly.

Daniel: Thanks for the information. That sounds like the way to go. In your SmartAssembly projects I assume you only turned on usage reporting for that one assembly, and not for the ones that are calling it to do reporting?
Back to top
View user's profile Send private message
DanielRose



Joined: 30 Oct 2009
Posts: 16
Location: Aachen, Germany

PostPosted: Tue Jun 18, 2013 1:19 pm    Post subject: Re: Reply with quote

williamw wrote:
In your SmartAssembly projects I assume you only turned on usage reporting for that one assembly, and not for the ones that are calling it to do reporting?


Exactly. I have two different SA project files. One has usage and crash reporting on (which I use for only that "core" assembly) and the other one has only crash reporting on (which I use for everything else).
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group