Sharepoint – Clean a huge Document Library

I recently had to clean a huge (113 000 rows) document library. The first question that must come in mind is : Why was it so big ? Well, someone thought it was beter to store data in lots of XML files instead of in a classic list. The second question is: How ? First, you have to understand that you can’t use a DeleteAll() method, it doesn’t exist. You must fetch data by little packet of rows. If you try to get everything, you will have a OutOfMemoryException. ...

February 20, 2009 · Florent Clairambault

SharePoint: What Should I Dispose?

When starting with SharePoint development, a common question is “Which objects should I dispose?”. This is crucial because SharePoint leaks approximately 1 MB of memory per undisposed IDisposable object. For components like menus, this can quickly add up to 10 MB per page load. While the MSDN documentation provides comprehensive guidance, here’s the quick answer: In your WebPart, dispose of all SPWeb and SPSite objects except: SPContext.Current.Site SPContext.Current.Web SPContext.Current.Site.RootWeb For Features, dispose of all SPWeb and SPSite objects except those provided in your “properties” variable. ...

February 17, 2009 · Florent Clairambault

Automatic error reporting in PHP

I edited this page on the 21 March 2010 because a lot of people seem interested and the code as since improved ! PHP has a pretty interesting feature, you can define a callback method to “catch” any error “thrown” in your code. And I’m sure most of you don’t use it. It’s really usefull when you want to make sure to detect error before any user reports it (which can takes time). This is all about avoiding to demolish with some lame errors your “user experience”. ...

February 15, 2009 · Florent Clairambault

Insert SVN version and Build number in your C# AssemblyInfo file

Software version number is quite important. It helps you track what versions have your users when they report something. And when it’s linked to an SVN version number, it’s even better. Well, with MSBuild Community Task, you can easily automatically generate smart version numbers, you have to: Download MSBuildCommunityTasks Make sure your “svn.exe” binary is in C:\program files\subversion\bin Add this at the end of your .csproject file : 2011-07-02 update: As given in Markus comment, this code is a much better option: ...

February 3, 2009 · Florent Clairambault

TC65 FAQ

MOVED HERE: javacint / FAQ I decided to open source the content I wrote in my blog pages to the javacint wiki. Please use it and participate from now on.

December 31, 2008 · Florent Clairambault

Writing in English

I’ve decided to start writing about my technical work and projects in English. While I’m comfortable reading English, I want to improve my writing skills. Feel free to provide feedback in the comments. Traduction : Je compte me remettre à écrire mais en anglais pour changer. blr_date: 2010-02-09 bw_readability_score_flesch: 76.5 bw_readability_score_coleman: 8.6 bw_readability_score_gunning: 8.3 bw_readability_score_smog: 6 bw_readability_score_ari: 4.6 bw_word_count: 93

December 27, 2008 · Florent Clairambault

PL-2303 on Vista

To get the PL-2303 USB/Serial converter working on Vista, use the BAFO Technologies drivers available on their support site. Current version: Vista 32/64 v1.6

December 17, 2008 · Florent Clairambault

Improving .NET Network Performance with Kernel Events

I recently rebuilt our TCP/UDP network server library to handle high-load scenarios. The initial thread-per-client approach worked but hit memory limits at around 3,000 simultaneous connections. The solution? Kernel events. Using IOCP (Windows), epoll (Linux), and kqueue (FreeBSD), we let the kernel notify our program when new data arrives instead of polling. With a 128-byte pre-allocated buffer and some BeginReceive calls, the changes were minimal. The results exceeded expectations: from a 10,000 connection target, we achieved 60,000 simultaneous connections with near-zero CPU usage and instant response times. This proves Mono/.NET’s capability for high-performance network servers.

November 2, 2008 · Florent Clairambault

The B.A.T.M.A.N. Project

I recently discovered an interesting mesh networking project called [B.A.T.M.A.N.][1] (Better Approach To Mobile Ad-hoc Networking). It builds upon and improves the [OLSR][2] protocol specifications for routing in mobile ad-hoc networks. You can learn more about this project on the [B.A.T.M.A.N. website][3].

October 11, 2008 · Florent Clairambault

MapPoint WebService authentication with Mono

When migrating a MapPoint WebService application from Windows to Mono/Linux, I encountered “401 Unauthorized” errors. Network analysis revealed slight differences in HTTP headers. Here’s the solution using specific credential handling: var cred = new System.Net.NetworkCredential("---user---", "---password---"); _credCache = new CredentialCache(); _credCache.Add( new Uri( "http://findv3.staging.mappoint.net" ), "Digest", cred ); _finder = new FindServiceSoap(); _finder.Credentials = _credCache; _finder.PreAuthenticate = true;

May 19, 2008 · Florent Clairambault