Hooking the windows COM runtime [closed] - windows

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
Is there an available tool which hooks the windows COM runtime?
I want to be able to see all the instances which get created, view queries to their interfaces, method calls, etc.
Thanks!

You could try Jonas Blunck's COMTrace -- I'm not sure if it works on Windows 7, but it's worth a try.

Check out http://www.nektra.com/products/com-spy-console, it's free.

to monitor the things you want you'll need to hook into system dlls and inject your blind delegators on interfaces queried. Needless to say how complex and error prone this task is, especially if consider that many implementors do not follow COM principles accurately. Though, some applications do that for their own purposes, without exposing this functionality.
If you really want to go this way - take a look at these:
MS Detours will help you with DLL hooking (http://research.microsoft.com/en-us/projects/detours/)
"House of COM" article on blind delegation (http://www.microsoft.com/msj/0399/com/com0399.aspx). Written by Don Box (or should I say "the world's greatest COM expert Don Box"? :-)

With in-proc COM servers there's almost nothing to hook - the consumer calls CoCreateInstance() or CoGetClassObject() and that's all it does. All the rest is done inside the COM object implementation. You might want to look at ATL sources to see how it usually works inside - for example when the consumer calls QueryInterface() the call directly goes to the corresponding object and the object itself is the only entity to observe the call.
This is not very fortunate but is a direct consequence of how in-proc COM servers are implemented. The developer can use Process Monitor to notice the registry accesses corresponding to ClassId->Dll mapping discovery and extensive tracing inside the COM object to see what's going on. ATL has a bunch of useful stuff (like COM_INTERFACE_ENTRY_FUNC_BLIND macro) to incorporate tracing.

Related

D or Go for clustered game server [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I'm designing a game, but this question is applicable to any situation that requires bidirectional communication between nodes in a cluster and a main server. I am pretty new to clusters, but I actively program in Go and occasionally in D.
I really want to use a modern language (not C/C++), so I've chosen these two languages because:
Array slices
Good concurrency support
Cross platform & compiles natively (with multiple compiler implementations)
GC (both working on a precise GC)
I've read https://stackoverflow.com/questions/3554956/d-versus-go-comparison and The D Programming Language for Game Development.
At a high level, my game will do most of the processing server side, with the client just rendering the game state from their perspective. The game is designed to scale, so it will need to act in a cluster. Components are mostly CPU bound, and update to a main server asynchronously, which shares game state with clients. Most computation depends on user input, so these events need to be sent down to individual components (hence bi-directional RPC).
Reasons I like D:
Manual memory management
Templates/CTFE
Code safety (#safe, contracts, in/out)
Reasons I like Go:
Standard library (pprof, RPC)
Go routines
go tool (esp. go get -u to install/update remote dependencies)
The client will likely be written in D, but that shouldn't have an impact on the server.
I am leaning towards D because manual memory management is baked into the language. While it doesn't have the nice libraries for RPC, I could theoretically implement that, but I cannot as elegantly implement manual memory management in Go.
Which would you use for this problem given the choice between the two languages?
I expect that either will work and that a lot of it depends on which you prefer, though if you're doing the client in D, I'd advise doing the server in D simply because then there are fewer languages involved. If you use two languages, then anyone working on your project generally has to know them both, and both Go and D are small enough in terms of their user base at this point that few people will know both - though if it's just you working on it, you obviously know both of them already.
However, I would point out that if the problem with using D is the lack of an RPC library, then that isn't a problem, because D is supported by Apache Thrift. So, D does have a solid RPC library, even if it's not in its standard library (in fact, it was one of the fruits of D's first round of participation in Google's Summer of Code).
I do not know anything about your game, If good concurrency for your server is important then I vote for Go.
I developed communication server in Go that implements communication with PUSH technology. Go is great in for such tasks. Compact clean code that is easy to understand.
Automated memory is important in concurrent apps.
Client apps are not so concurrent like server apps.
Client apps should keep constantly high frame rate.
So manual memory management without global GC locks are better for client apps.

Looking for a free scriptable load-testing tool [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I'm looking for a tool that will allow me to test a Rails-based JSON web service. LoadRunner would fit my needs, but I need a free solution.
JMeter is free and scriptable, you should have a look.
What is your virtual user need? Some of the commercial tools offer no cost versions at a limited load level, so before addressing your need I am looking for more specifics on the virtual user number requirements.
For clarification, are you looking for a tool which can produce a ACM/IEEE definition stress test from a scheduler perspective? This would be a test which increases in load by a defined interval every ~n~ seconds|minutes|hours until the system collapses or a particular metric is achieved, such as response time exceeds SLA value by 250% for five minutes or CPU is greater than 90% for 45 seconds, etc.... Schedulers are all over the map in the tools space, some are better than others when it comes to Stress, most work equally well for a defined load level.
How does monitoring fit into your tool model? Are there specific architectural components which you would like to monitor which would drive a tool? This will help you identify system bottlenecks in the use of resources on architectural components.
What about your team skills? You mention scripting, but how much are you expecting the tool to handle for you. Some of the open source tools are great, but they mandate that a person be a highly skilled developer to get the most out of the tool. The commercial side rounds some of the edges off of the tools, but in general you are still going to need to be proficient in the language of the tool. If you need Python, that takes you one path, Java another, VB a third, Pascal a fourth, C a fifth, etc.... Sometimes its easier to document what languages you know and know well and concentrate on tools that fit that model as trying to learn a new tool and a new language at the same time rarely yields benefits.
Have a look to AgileLoad it is free for small test and provide both recording and advanced scipting features. It is compatible with JSon service. It is quite easy to use, there is also tutorials and video on how to use the tool on the website. Support is free and the support team can helps you with scripting process.
I'd also take a look at The Grinder. It has a nice feature where you can create your load script by recording your browser activity.
There is a version of Load Tester that is free and has no limits on the number of virtual users you can run: Load Tester LITE.

what is a better tool for collaborating with others than email? [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I'm a developer and need to collaborate with an UI designer and a project manager. so there are a lot of documents we need to share and the project manager will assign me tasks about the project. Instead of email and dropbox, what's the best way to do it?
You could look at varying other online collaboration tools out there. I use Clinked (http://clinked.com/) at work, and although we use a the paid version there is a free one for 5 users or less so maybe you could check that out?
My team and I have been using Wrike for almost a year now, and I have to say it’s pretty neat in terms of collaboration. We have to deal with lots of documentation and edit-approve iterations, and Wrike made it all really simple. Basically, each member of the team just opens a needed doc, edits it, saves, and it’s automatically uploaded as a new version, so no download and no multiple versions of the same doc. And every time there’s been a change it sends a notification to my e-mail, so it’s really easy to keep track on what’s going on with a task. It’s also integrated with Google docs, so you can choose whatever suits your needs better. I, personally, love its e-mail integration (it converts my e-mails into tasks, I just need to add Wrike into the e-mail’s CC and it will be transferred into the app) and Outlook add-in, as it helps to keep all our data in one place. It works perfectly for our task management needs, too. Especially with its Activity Stream that makes it really easy to stay updated with the tasks’ changes and discuss any coming issue.
Hope you’ll find it useful too! Let me know how it went afterwards.
You might find this list of 43 project management software alternatives useful:
http://blog.timedoctor.com/2011/02/02/43-project-management-software-alternatives
My personal favorites are Basecamp, Time Doctor and Dropbox. These programs have helped my team in a lot of ways especially productivity. I'm sure you'll find yours there too. It's the most helpful and comprehensive list I was able to get.

How to best implement user-specific logic in a Spring web application? [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
I'm facing the following problem: the Spring web application I'm building is pretty user-specific. Each user might have some pieces of the logic tailored to their needs.
I'm wondering how to best implement such a 'framework' that would allow for easy injecting of new users along with their specific logic.
I'm thinking of one the following solutions:
Providing a common interface for all users and invoking the actual user-specific implementations via reflection. Then, when adding a new user, I just need to write the logic, compile it and put the *.class file onto the server
Using some sort of an XML-configurable rule/workflow engine. I can build the individual blocks of logic upfront and then when a new user shows up I just specify an XML (Spring config) describing the logic flow
The first solution seems initially easier but requires more work when adding a new user. The second takes more time to develop the rule/workflow mechanism, but then adding a new user should be simpler.
What do you think? Any other ideas? Do you know any frameworks/patterns that would help me in this task?
Thanks,
Peter
I would prefer the first solution (Interface and programming) but it has some draw backs:
it is not very secure (the user specific code can do anything)
you need to add some compiled files to the class path
I would try use some scripting language (Java Script for example). So a privileged user can upload the scripts via the fronted. The scripts can be stored in the database, so you can update the application without fear to delete the files.
And the second good thing is, that it is may possible to restrict the functions that the script can invoke.

Review Orchards Project [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I'm looking for a base project which I could extensible and quickly deploy for small project such as company website, small shop, blog.... I've used Orchards http://orchardproject.net, but it's too sophiscated to understand internal process and customize.
Could you please review pros and cons of Orchard, or recommend me others that simplier.
Thanks
Orchard CMS is like a small laboratory for future ideas but it's quite hard to work with for real projects despite having some very good core ideas.
Pro:
ASP MVC with Razor view engine
Modules
Good documentation for a open-source project
Con:
Lack of automated generated admin UI (you write the back and front-end UI)
Lack or improper hierarchical data structures and 1:N/N:N relations
Too big and complex for small projects it trying to address
You may try Umbraco or just write a new ASP MVC application with a library of custom controls.
I have looked at both Orchard and N2 CMS and I would say that if you're developer and want a CMS that provides simplicity whilst allowing you to create quite complex sites then N2 is the CMS for you.
I'm using Orchard for developing some sites.
I love it.
It is not so easy to understand at first because there are so many little pieces to understand.
But after some time when the big (and the small) picture is more clear, you will appreciate the fact that you have to code (or just get from gallery and install) the little functionality you need.
If you need send an email, you use the corresponding module, and you never need to code yours or you can replace sending feature with a new one and it is available to all other modules.
Base framework includes some useful functions like db-layer, authentication e, indeeded, every other module you may install...
Have fun!

Resources