tag:blogger.com,1999:blog-3157881265969801285.comments2019-06-21T17:31:27.462-04:00b.ling on software developmentAnonymoushttp://www.blogger.com/profile/12728014380144489730noreply@blogger.comBlogger42125tag:blogger.com,1999:blog-3157881265969801285.post-78672095782359736282019-06-21T17:31:27.462-04:002019-06-21T17:31:27.462-04:00I have been looking for weeks for a large memory l...I have been looking for weeks for a large memory leak using the Xceed WPF Toolkit RichTextBox.<br />My RichTextBox is large, and everytime I update it using Interaction Triggers (EventName is TextChanged), I would lose 20 - 30K memory which was never recovered.<br /><br />I added those 2 properties and I can see the the memory jump a small amount, then it is released. Thank you so much for sharing this! I can't even guess how much time you saved me.Anonymoushttps://www.blogger.com/profile/13282152593274809093noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-38031487256408731872015-04-09T14:36:58.835-04:002015-04-09T14:36:58.835-04:00I needed this for integration testing my Web API a...I needed this for integration testing my Web API application. I found that I had to reject loading concrete classes, or NSubstitute would choke on the controller classes. So my implementation ended up looking like this:<br /><br /> if (!(service.IsInterface || service.IsAbstract))<br /> {<br /> // Do not register instances for concrete types<br /> return null;<br /> }<br /><br /> var mock = Substitute.For(new[] {service}, null);<br /> return Component.For(service).Instance(mock);Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-72091256549524345692014-10-16T12:05:42.427-04:002014-10-16T12:05:42.427-04:00One last thing....
All I do is VIM, VIM, VIM, no ...One last thing....<br /><br />All I do is VIM, VIM, VIM, no matter what! <br />My Inputrc key-bindings set!<br />... touching on the keys I get the feeling that my screen sessions are still up.... <br /><br />and they'll stay there..<br />and they'll stay there..<br />and they'll stay there..<br /><br />Up. Down. Up. Down. Up. Down.<br />'CAUSE All I do is VIM, VIM, VIM! <br />Even Emacs Vims. Win - Vim. <br />Recycle Emacs in the bin. Vim, Vim, Vim!<br />Put Emacs in the bin cause trash does stay there. Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-46621311497162364302014-10-16T11:37:21.855-04:002014-10-16T11:37:21.855-04:00Yep! I am indeed checking out your dotvim project...Yep! I am indeed checking out your dotvim project. Thanks for all the hardwork on that. It was up and running easy and if I do'nt have any issues then I think I will build something based off of your work.<br /><br />I too have had a past where VS was my IDE, but before too long I became absolutely intollerate of anything less then a terminal, VIM keybindings everywhere, and VIM with just a handful of plugins.<br /><br />Screen and iPython have been pretty integral in my workflow too. On Windows you ask? Yes. I've tried everything from changing the Windows subsystem (a disappointment, no reason that should not have been perfect), Cygwin, GNU Utilities for windows, custom terminals, embedding gVim into VS... for years I tweaked my Windows environment to be more like the other environments I would jump into/out of throughout the workday. I do like the GNU Core Utilities for Windows, but other than that none of those configurations were satisfying.<br /><br />Then, when I left my big corporate job; stopped using Perforce and started using Git- I found it. The Git installer for windows contains the perfect replication of a bash shell on *nix environments. It respects .inputrc and it can be configured to navigate similarly or be jailed off away from the windows-environment.<br /><br />I grab the GNU tools for windows too and then I have all the awk, sed, grep, head, tail, bash, and most importantly to me the <b>readline</b> goodness that I need in my shell of a life.<br /><br />If you've never done it before, VS project can be built from the command line. There is always a *.cmd file in the ProgramFiles menu that will get you started if you've never done it before. The name of the script changes with VS versions. The SDKs and Debugging toolkits have similar *.cmd scripts.<br /><br />CDB / KDB command line debuggers. iPython and all its awesomeness. SysInternals Suite Toolkit and then the standard windows command-line tools (like reg) and there is no reason to use your mouse anymore; which is my goal. Hands on keyboard - always.<br /><br />What about email? Tabing through windows brings up backgrond applications and then.... BOOM Gmail has been supporting VIM - like keybindings for several years. Outlook? Actually, I think they added them recently too, but I would rather let Google read my email than have M$ bloated, monolithic, self-important, productivity-killing applications consuming sickeningly large fractions of my system's resources while I'm trying to do actual work.<br /><br /><br />Anyway... checkout the version of BASH that comes along with Git for Windows.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-66553333123962377062014-05-06T23:38:49.585-04:002014-05-06T23:38:49.585-04:00RichTextBox Control for C#.NET<a href="http://www.kettic.com/winforms_ui/richtextbox.shtml" rel="nofollow">RichTextBox Control for C#.NET</a>Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-70995813624213172712014-02-21T08:19:49.040-05:002014-02-21T08:19:49.040-05:00This is a good article & good site.Thank you f...This is a good article & good site.Thank you for sharing this article. It is help us following categorize: <br />healthcare, e commerce, programming, it consulting, retail, manufacturing, CRM, digital supply chain management, Delivering high-quality service for your business applications,<br />Solutions for all Industries,<br />Getting your applications talking is the key to better business processes,<br />Rapid web services solutions for real business problems,<br />Web-based Corporate Document Management System,<br />Outsourcing Solution,<br />Financial and Operations Business Intelligence SolutionDigitalbithttps://www.blogger.com/profile/17489181876361540793noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-4582559981600559462014-01-29T05:32:37.691-05:002014-01-29T05:32:37.691-05:00Just wanted to say that this approach didn't w...Just wanted to say that this approach didn't work for me - I'm guessing it might have something to do with a newer version of Castle Windsor? I fixed it by registering the component like this instead (where square brackets are in fact angle brackets - the comment system didn't like angle brackets):<br /><br />_container.Register(Component.For[ILazyComponentLoader]().ImplementedBy[LazyComponentAutoMocker]());Anonymoushttps://www.blogger.com/profile/15216377735233222008noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-10128657233242319512014-01-29T05:31:06.238-05:002014-01-29T05:31:06.238-05:00This comment has been removed by the author.Anonymoushttps://www.blogger.com/profile/15216377735233222008noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-85785787227185350972014-01-29T05:30:07.080-05:002014-01-29T05:30:07.080-05:00This comment has been removed by the author.Anonymoushttps://www.blogger.com/profile/15216377735233222008noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-53317618505428623452013-07-07T14:17:31.307-04:002013-07-07T14:17:31.307-04:00Hi,
Recently converted to vim. I am an admin guy,...Hi,<br /><br />Recently converted to vim. I am an admin guy, who has to filter through a lot of log files/command line outputs, write an occasional perl script etc etc.<br /><br />Till a few days ago, I would use notepad++ for text mangling,another editor for perl scripts and another editor for another scripting language. I staunchly believed that notepad++ was the best text editor. <br /><br />Till I got around vim. Whoa, I am blown. Notepad++ is still a great text editor, no doubts about it, but somehow I am getting hooked more and more to vim. <br /><br />Had to change the color and the font (gvim on windows 7). But after that, and learning a couple of vim jiffy stuff, nothing like vim.<br /><br />Was browsing to check on a few vim articles and stumbled across yours. Nice piece on vim. :) perlpetualhttps://www.blogger.com/profile/16421486328246318137noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-7155163980043906792013-06-10T08:05:20.191-04:002013-06-10T08:05:20.191-04:00mercurial bookmarks only move forward with commits...mercurial bookmarks only move forward with commits, <b>not</b> with pulls.<br /><br />you are of course welcome to create a master bookmark, but you'd have to manually update the bookmark to the tip after every pull for it to be truly equivalent to git.<br /><br />the workflow you mentioned is very tedious to do in mercurial, and than rather tracking master yourself it is often easier just to do 'hg book -r 123' if you truly need that branch to be directly off of "master".Anonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-88985606922380693652013-06-10T05:06:51.309-04:002013-06-10T05:06:51.309-04:00I disagree with "no need for a git master equ...I disagree with "no need for a git master equivalent". A typical workflow would be: <br /><br />1) book and work on "feature-1" <br />2) go back to "master" (whoops, no reference?!) <br />3) book and work on "feature-2"schlamarhttps://www.blogger.com/profile/13806747860793542103noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-13790410708051680072012-05-01T08:41:21.850-04:002012-05-01T08:41:21.850-04:00It wouldn't be any different from processing a...It wouldn't be any different from processing a new command. You will need to load all snapshots/events to get the aggregate root to the latest version. Events should typically be "fire and forget". If you require them to be guaranteed delivery it's better to restructure them as commands.Anonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-37964604413838871642012-05-01T05:26:16.698-04:002012-05-01T05:26:16.698-04:00Nice, thanks for answering :)
I should definitely ...Nice, thanks for answering :)<br />I should definitely take a closer look at the MongoDB! Sounds very interesting :)<br /><br />On the other hand I'm still wondering if there is a general approach for this situation - you have done a state transition into the KV/doc DB and you have some events there. Then your system goes down just before it publishes these events on to the wire (some external messaging system). Then when you start again is there an efficient way/query to be done against the KV/doc DB so that you get all the events that haven't been dispatched yet?bodrinhttps://www.blogger.com/profile/03712236331151945089noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-49591922308183783622012-05-01T00:24:36.414-04:002012-05-01T00:24:36.414-04:00Well, the easiest way is to cheat and use Mongo as...Well, the easiest way is to cheat and use Mongo as your messaging bus ;-) There's a bunch of examples on the web. Basically, you create a direct connection against the database and read the oplog. This is the mechanism that Mongo uses to do replication, so you get near real-time performance. Since it's only one system to manage, rather than two in concert, it's a bit easier to maintain. You'll get the same guarantees as any other write to a Mongo node.<br /><br />If you must go to another messaging system it'll depend on the guarantees of that implementation. It's not the end of the world to tell the user to "try again later", assuming that's acceptable for the 0.01% of the time.<br /><br />Also, if the messaging system is down, you can still read from the event store to get the latest information (and is required for stale nodes joining the system).Anonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-47392556505668329682012-04-30T16:53:00.700-04:002012-04-30T16:53:00.700-04:00Hi, I want to ask how do you dispatch the events. ...Hi, I want to ask how do you dispatch the events. I guess the flow is somthing like this:<br /><br />1. receive a command<br />2. load the related AR and process the command which produces some events - a batch<br />3. store the event batch in MongoDB, e.g. at <br />{ "_id": { "aggregate": 1234, "version": 65 } }<br />4. dispatch the events to some messaging system<br />5. mark the { "_id": { "aggregate": 1234, "version": 65 } } as dispatched<br /><br />So if this is similar to what you are doing I'm wondering what if the system goes down just after step 3. ?<br />The events are not dispatched, but how do you find that after restart? Is there an efficient way with MongoDb and/or with other documen / KV stores?bodrinhttps://www.blogger.com/profile/03712236331151945089noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-33853876587002784292012-01-19T09:20:31.569-05:002012-01-19T09:20:31.569-05:00Welcome to the world of C# :) In C#, they are cal...Welcome to the world of C# :) In C#, they are called attributes rather than annotations. The MSBuild task has a property named AttributePatternMatch, which is a regular expression to match on the name of the attribute you want to use to determine whether to weave a property or not.<br /><br />Keep in mind that the code is highly experimental. Hope that helps!Anonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-79422623945984071442012-01-19T02:22:21.345-05:002012-01-19T02:22:21.345-05:00Awesome, I've just started working on my first...Awesome, I've just started working on my first c# job after 10 years of Java, so learning all this byte code manipulation again! Would it be possible to use annotations to determine if a class and its properties should or shouldn't be processed to create the dependancy properties?campershttps://www.blogger.com/profile/02344458335325192476noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-42752870820818198762011-10-31T21:09:49.730-04:002011-10-31T21:09:49.730-04:00Thanks for the reply Nick!
I have yet to check ou...Thanks for the reply Nick!<br /><br />I have yet to check out all the new MEF features of 4.5, but it definitely looks very interesting with what's happening in the previews.<br /><br />The new RegistrationBuilder looks pretty good, especially since attributes are optional now, but that only solves wiring up the application.<br /><br />IMO, the most useful (and powerful) thing you can add is the equivalent of Autofac's IComponentContext -- something that will let you easily hook into any part of the resolution chain from creation to disposal.<br /><br />Once that's in it'll be much easier to extend the container and use it for more "advanced" scenarios --and with less code.<br /><br />Cheers,<br />BaileyAnonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-31061347907944307822011-10-31T19:15:20.853-04:002011-10-31T19:15:20.853-04:00Hi Bailey! Nice thoughtful article - I have a foot...Hi Bailey! Nice thoughtful article - I have a foot in both camps, so I'm glad that the Autofac extension points work for you, but I'm also keen to close some of the gaps on the MEF side :)<br /><br />I am curious, have you had a chance to look at RegistrationBuilder, being delivered in the .NET 4.5 version of MEF? It opens up the possibility for us to support activation events like the ones you mention, although it doesn't as of writing.<br /><br />In case you didn't catch it, the release announcement is at: http://blogs.msdn.com/b/bclteam/archive/2011/10/27/what-s-new-in-mef-version-2-preview-4.aspx<br /><br />Thanks for writing this up anyway, it will give us something to think about.<br /><br />Regards,<br />NickNickhttps://www.blogger.com/profile/02020072230899910249noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-12977626911203188242011-09-23T10:20:44.833-04:002011-09-23T10:20:44.833-04:00You are a genius :) :) I had this problem for a wh...You are a genius :) :) I had this problem for a whole day and this fixed my problems. Thanks a lot :) :)jrhttps://www.blogger.com/profile/12429578477068822273noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-55868821171961673462011-09-06T21:19:01.774-04:002011-09-06T21:19:01.774-04:00Looks like the same StartWith() trick is needed fo...Looks like the same StartWith() trick is needed for Observable.Generate.<br /><br />I played around with Observable.Generate and all the expressions I came up looked pretty complicated in comparison with what I originally had. This is mainly because I need to call OnNext() inside the AsyncCallback, so all solutions either had external Subjects or obscure ways of passing an IObserver around...<br /><br />Maybe I'm overcomplicating things so if you can come up with an example it'd be greatly appreciated. I'm still a Rx newbie...<br /><br />Thanks!Anonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-19553797152056048852011-09-06T11:32:45.352-04:002011-09-06T11:32:45.352-04:00Thanks! I didn't know about that overload.
I...Thanks! I didn't know about that overload.<br /><br />Is there a way to make it start immediately, like the StartWith(-1) in the original expression?<br /><br />Observable.Generate(<br /> 0, <br /> _ => true,<br /> _ => _,<br /> _ =><br /> {<br /> // this doesn't get called until 60 seconds passes first...<br /> return 0;<br /> }, <br /> _ => TimeSpan.FromSeconds(60));Anonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-91577243671834472422011-09-06T11:19:23.203-04:002011-09-06T11:19:23.203-04:00Rather than the custom Observable generator with I...Rather than the custom Observable generator with Iterval, why not use Observable.Generate passing in a timespan of 60 seconds?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-3157881265969801285.post-26837147876869332602011-06-24T11:08:46.400-04:002011-06-24T11:08:46.400-04:00Actually, Cygwin/MSYS used to be in my tool chain,...Actually, Cygwin/MSYS used to be in my tool chain, but I've made an effort to learn PowerShell by making it my shell.<br /><br />I'm still thrown off sometimes because PowerShell operates on objects, rather than text. Sometimes this makes it easier, sometimes harder. Grep comes to mind.<br /><br />Check out BareTail if you want to watch log files in real time.Anonymoushttps://www.blogger.com/profile/12728014380144489730noreply@blogger.com