Thursday, December 22, 2011
JavaScript Globalization
I am leading a project that is now going to go from running in the US to running across the world over the next 6+ months.
It currently uses a lot of different tech: ASP.NET MVC3, HTML5, jQuery, jQuery UI, KnockoutJs (w/Mapping), jQuery Templates, jQuery DataTables, EF4 and a host of other home-grown and one-off type technologies.
So, I started browsing the usual suspects, especially a previously bookmarked Scott Hanselman blog post (suspiciously a 7-month-old "part 1" with no "part 2" yet *holds breath*).
Well, the most confusing part I have run across so far is how to handle JavaScript and jQuery globalization. There was one project by Microsoft that was donated/accepted/rejected by the jQuery folks (sounds familiar... jQuery Templates had the same problem) which, apparently went through a few renamings (one, two, three), the last of which was a renaming to "Globalize", total api change and removal of any dependency on jQuery (not sure if there was ever one, but didn't bother to get into it).
Confusingly, this library (not a plugin anymore) is maintained/developed by the jQuery UI team now, even though there's no dependency.
So, apparently, the supported(?), in-development code is now the "Globalize" library whose wiki is here (on the jQuery UI site, where else? ... O_o)
Hope that helps save someone else some time.
Saturday, November 19, 2011
Chain Of Responsibility Implementation
[UPDATE: I have since updated this post. Look for the block at the bottom]\
Monday, November 7, 2011
Hmm.. which one’s broken, Linq, Debugger, IDE?
So, I ran into an as of yet unsolved problem today. I don’t know if this is a Linq bug, a debugger bug, or a Visual Studio bug, but, for your viewing pleasure:
If I can figure out what’s going on, I’ll post an update
EDIT: Figured it out..
This is one of the big reasons I don’t like operator overloading…
The items inside the FilterList overrode the comparison operators, but did not handle “null” properly…
Grrr..
Thursday, November 3, 2011
CSS Transform help
I decided to try to do some fancy CSS stuff for my client website. It involves gradients, transforms and stuff like that. Anybody who's messed with that stuff knows that it's a huge pain in the butt to get it working in all the browsers, never mind one! So, here you go: http://css3generator.com/.
You're welcome :)
Wednesday, October 26, 2011
Windows Azure AppFabric Cache's Miniscule Features
Just wanted to warn/inform people who are considering using AppFabric Caching in Azure…
Here’s a list of things it won’t do:
- Regions
- Named Caches
- Allow you to get a list of cache keys currently in use
- High Availability Mode (redundant copies across machines for durability)
- No sliding window expiration
- No events for things like eviction, add/remove, etc.
- so you can’t update a local cache with events from the global cache
- You don’t get notified if something is removed, so you only know when you get “null” back from a Get()
- No Powershell integration (if you’re into that)
- No tag support (tagging is basically used for some extra metadata besides the key without pulling the whole object)
So, basically, ALL you get is a simple, Get/Set distributed cache that doesn’t even support the whole set of features you get from the basic ObjectCache in .NET 4.0
They really shouldn’t be calling it “AppFabric Cache” at all, since it doesn’t really support anything that comes with that API
I must say that I’m really disappointed
We waited a LONG time for this feature and got something that could have been coded in a month.
Bad form, Microsoft. Bad form!
Conflicts Between Versions Of Assemblies
I just upgraded a project from the Azure SDK 1.4 to SDK 1.5. I started getting the "Found conflicts between different versions of the same dependent assembly" warning on the Microsoft.ServiceBus.dll file.
I thought to myself, "Self, I've seen this before. You're just referencing the wrong copy of an assembly somewhere"
So, I checked every reference to Microsoft.ServiceBus.dll … Hmm… they're all correct. ??
I did a full rebuild… still there..
I did a super-duper clean (close the project, delete every "bin" and "obj" folder, open the project and rebuild)… nope…
Time to get medieval on this stuff… So, I opened the topmost assembly (in this case, my Web application assembly) in ILSpy. I stared looking through each and every referenced assembly until I found the culprit:
Microsoft's own Transient Fault Handling library (used for retrying database calls in Azure). Now, I've contacted the team who wrote that, hoping that they will update their NuGet package. Otherwise, I'll have to add that ugly Binding Redirect in my config file.
For now, I'll just stare at the warning for a while and hope the NuGet package gets a quick update
Thursday, October 13, 2011
Useless Properties
So, apparently the UserData property on the ASP.NET FormsAuthenticationTicket object is basically useless.
The UserData isn't persisted if you're not using cookies. So, you get no errors, no warnings, the code runs fine, it just doesn't actually persist that data.
Nice going, Microsoft!