I’m right now on in Arlanda airport, coming back from DevSum 2015. It was my first DevSum, and it was awesome.
Conference had two days and four tracks. Everything conveniently located in central Stockholm at hotel Clarion Sign. Very close to central station and places for evening activities. The atmosphere was very friendly. I met well known faces from speaker community and made some new friendships. It was most social conference I attended this year, very much similar to how DevDay feels. Most of the speakers didn’t sit in the close “speaker’s lounge”, but mingled with attendees, all led by Tibi, the King of DevSum :).
I didn’t attend many talks, but there were few very intersting. Among them Mark Rendle’s C# 6 talk, Troy Hunt’s and Niall Merrigan’s security talks and Hadi’s “silver bullet” talk. There was also Rob Ashton rant about how Erlang is awesome, but I’m not sure he convinced anybody showing mostly his console scrolling with loads of code and hard to understand error messages flying around. But it was hillarious so that’s ok.
My talk went fairly well. It was another installment of the talk I did at Swettugg and LambdaDays. I had around 30 people on public and I hope they got interested by type providers. Big thanks to Tibi and Cornerstone for this opportunity. Slides and code are on github.
Tag: functional programming
Month of spreading F# love in Poland
In last month or so I did three talks on F# in Poland. I can see gaining interests and there’re already other people speaking about F# in Polish community. This is awesome!
Kraków, 25th September
A Day before DevDay KGD.NET organized meetup with two talks. This was great opportunity for my employer tretton37 to get some more street cred in Poland, so we decided to sponsor some food and drinks. There were two speakers – me and Maciej Aniserowicz, who’s kind of a rock star of Polish .NET community (BTW, check out his new podcast (in Polish)). I did my already well known introduction talk to F#. I had quite a big audience (around 100 people) and they were very engaged. I enjoyed great question and feedback I got after the talk. Looks like it’s very active .NET group. I used the same slides and code as in Warsaw couple months before.
Next dey was a DevDay :). I’m big fan of this conference and it delivered again. There were a lot of semi-negative opinions on the Internet afterwards, which is very sad and unfair. Looks like DevDay became victim of its own success. Last year was fuckin awesome, and people had some overgrown expectations. The truth is, it was fuckin awesome again this time and I can’t wait for next year’s edition. Videos are already online and you can watch them on youtube. But the strongest point of DevDay for me is community impact. It made largely distributed Polish .NET scene more united. People are visiting each other’s group and exchange experiences and knowledge. Programmers from all around Poland know each other better and lot’s of credit for that goes to Michał and Rafał.
Interwebz, 18th October
On Saturday evening I did a talk on Polish virtual conference dotnetconf.pl. From statistics I could see there were about 70 people watching it live. It’s a little bit weird to talk to computer without seeing your audience. I’m not happy how this talk went, but you can judge by yourself, because it’s been recorded (Polish). Feedback I got afterwards kind of matched my expectations – 24 positive, 16 neutral and 2 negative opinions. Again – same slides and code as in Warsaw.
This was the second edition of dotnetconfpl, great initiative by Michał, Paweł and Jakub. It’s Saturday afternoon full of code. Made by Polish developers for Polish developers. And because it was virtual, I could do talk from my desk in Sweden. I also very enjoyed discussions that went on whole day on dedicated jabbr channel.
Poznan, 30th October, PolyConf
Few days ago I did completely new talk. This time about cross-platform mobile development with F# and Xamarin. So this was new talk, and also my first talk in English, and biggest audience so far. Lot’s of new experiences. I was quite nervous before, but seems like everything went well. I’ll see video in a couple of days to make sure, but right now I feel it was my best talk so far.
The conference itself is evolution of well known RuPY. This time they widen topics to other programmic languages, so you could witness talks on JavaScript, Haskell, Erlang or F#. Pretty cool experience, and lot’s of inspiration how to move concept from other technologies to my daily job. The conference, even though it was hosted in Poland, gathered mostly international crowd. I’m putting it on my calendar for next year, because really enjoyed it.
What’s really cool and makes me happy, there’re other people who start talking about F# in Polish community. Few weeks ago my friend Kuba Walinski asked me if he can reference my talk, as he’s gonna do his own about F#. Hell yeah, you can. It’s great that we’re spreading F# love :). He spoke at Developer Days in Wrocław and you can read his thoughts about it on his blog.
There’re some other F# events coming up in Poland, so I’m thinking about starting some kind of Polish Monthly F# news, similar to Sergey’s weekly news, but focusing on our local community. Stay tuned :).
Talking F# in Warsaw
Two weeks ago I had another opportunity to practice my public speaking skills. It took me some time to write this post, because in the meantime I spent few days in Krakow. And Krakow is a different state of mind.
This was another instance of my introductory talk to F#. It went a little better than one on get.net, but still I think there’re things to improve. I got really good feedback from Gutek, who came to see this talk. There were also some other friends from Warsaw – some of them I haven’t seen for years. It was a pleasent surprise.
Warsaw .NET usergroup seems to be similar size to one in Gdansk. There were about 40 people attending. Interesingly, some of them came there for the first time, just because of the topic. Good news that F# is getting some interest in Poland. I got best ever set of question after this session. You could clearly see people are interested and want to know more. Really liked that!
What I didn’t like is that there were no networking activities afterwards. Fortunatelly, there were some friends mentioned before, so we went for some food and drinks. Overally good time, and I’m happy I managed to get there on my way to Kraków.
On the bonus note, I had with me ticket for leetspeak to raffle. Leetspeak is tretton37‘s conference, that we organize every autumn. This year it’s happening on 4th October in Gothenburg. Tickets will be available soon.
As usually, slides and demos landed on Github.
There are also good news. I’m doing new F# talk, focused more on cross-platform capabilities. Looks like I will present it on PolyConf and WarmCroc in next few months. I’m excited and terrified at the same time, because they’re gonna be my biggest speaking gigs.
Speaking – “WTF# and why should you care” at get.net conference in Łódź
Nearly two weeks ago I had my first opportunity to speak at a conference. Get.net was organized by Łódź branch of Sii and featured all kinds of talk about .net technologies. Among the speakers you could find many familiar and well known faces from Polish dev scene like Maciej Aniserowicz, Jakub Gutkowski, Basia Fusińska, Michał Śliwoń or Rafał Legiędź. I was humbled and honored to speak in such company.
Speaking at conference isn’t much different than speaking at user group. There were just more people and I had to use microphone. Unfortunately it was the kind of mike you have to hold in your hands and this made live coding quite a challenge. Many other speakers had that issue and I hope organizers will know better next time. Apart from that, conference was quite well organized. Also venue was really nice.
My talk was slightly modified version of one I did for tricity .net group last month. But this didn’t make me feel more confident about it. After all it went quite well and there were even some positive tweets. This is good, right? I hope this sparked some interest for F# in Polish .net community. Overall this was nice experience, and I will actively look for other chances to speak at conferences.
Slides and code are on my github.
BTW, I’m writing this post during Craft Conference in Budapest. I’ll do some writeup next week.
Speaking – “WTF# and why should you care” at Tricity .NET Group meetup
Last week during local .net group meetup I did my first technical talk ever. Well, I did present some stuff on internal meetings in company before, but never for so many people, whom I don’t know.
I was quite nervous before – for many reasons. First of all, I’m not some F# guru. I don’t feel fully entitled to share knowledge about it. I also don’t feel very confident in public speaking situations. But it all come around nicely. I’m generally satisfied how it went.
I’m presenting it again in one month at get.net conference in Łódź, Poland. Based on this experience, I will change few things in this talk. But in general, this was good training.
If you have doubts “should I present something at usergroup”, JUST GO DO IT. But before read Zach Holman’s hints on speaking.io. I found them very useful.
Slides from this presentation are on my github. Code examples I used, were mostly from tryfsharp.org.
Using redis with F# on Windows
In one of my next projects I’ll probably use F# + redis mix. I wanted to try it out, to get some general idea how it will work. I had no previous experience with redis, and I’m still beginner in F#. I wanted to do some end-to-end example for saving and reading data. My idea was to get some Bitcoin price from external service, save it to local redis instance, read it back and chart.
In this blog post, I’ll show how I got there, and what I learned in the process.
Installing redis on Windows
Redis is in-memory key value store. It’s very fast and can store data in few data structures – strings, hashes, lists, sets and sorted sets. Official releases run on linux, but Microsoft Open Tech group developed and maintains experimental port to Windows. And this version I used for my tests.
I simply downloaded code from github, build solution in Visual Studio, and run redis-server.exe from project folder. If you want to test some commands with client, run redis-cli.exe. And if you have no idea, what are the commands try.redis.io has pretty cool interactive tutorial, that cover some basics. Running redis from code build on your dev machine probably is not the best idea for production – I would instead choose to deploy it on some linux server. But for testing purposes it’s perfect.
Getting data from external service
That part was pretty straightforward. I decided to get data from bitstamp.net, because they API for Bitcoin ticker is super easy to use. It has some limitations, but I’ll get to this later. So I made request to https://www.bitstamp.net/api/ticker/ and parsed it using Json type provider from FSharp.Data package (you can install it with Nuget). Json type provider is awesome. After you feed it with some sample data, you have all your fields just “dot” away.
https://gist.github.com/mlusiak/7901990
One thing I learned hard way in this part of code, is that in currentPrice you need those parentheses. Without them, F# will treat the whole block (lines 13 – 15) as calculating value and binding it to currentPrice – not as a function. And because values are immutable by default, it will always “return” the same price.
Saving results to redis
To access redis, I used ServiceStack’s redis client. ServiceStack is great framework to access all kinds of webservices. You can install ServiceStack.redis package using Nuget. It’s free to use up to 20 types.
https://gist.github.com/mlusiak/7902309
You can see three approaches I took (the only difference are first two lines). First one didn’t work – it saved “empty” data (empty strings, integers equal 0, etc.). As Demis Bellot explained to me on StackOverflow, StackService rely on writable properties, which immutable records in F# don’t have. He suggested to use [<CLIMutable>] attribute (which I did in third approach). In between I found this blog post, that used mutable keyword on type fields. This also works, but is not as elegant as the attribute, because it exposes those mutable fields also within your F# code.
Getting data from redis
This was very straightforward. No issues here. It just worked.
https://gist.github.com/mlusiak/7903099
Charting the data
To visualize this data, I used FSharp.Charting library. To make it work, you have to install it with Nuget and reference some libraries like System.Drawing and System.Windows.Forms. I also had to load FSharpCharting.fsx file.
https://gist.github.com/mlusiak/7903123
And it works!

Putting it all together
To summarize – getting data, saving to redis, reading back and charting – all in around 30 lines (excluding referencing libraries) of F#.
https://gist.github.com/mlusiak/7903762
Two more remarks about this code. I call Bitstamp API every 31 seconds, because it gives new data every 30 seconds anyway. If you call it earlier, you’ll get the same data as last time. Second thing is this whole #if INTERACTIVE block. I don’t know why, but when I run code in F# interactive without it, it screamed about no references to libraries. I thought referencing them in project would be enough, but no. And if I wanted to compile and run .fs file, than it failed to compile with #r clauses in it (because .fs file don’t support them, they work only in .fsx files). #if INTERACTIVE allowed me to test code in F# interactive mode, but still compile and run this code as program.
Any comments about code, and way I did things will be appreciated. I’m new to F# world, and I am happy to learn what I could do better.
Some useful references
http://try.redis.io/
http://fsharp.github.io/FSharp.Data/
http://fsharp.github.io/FSharp.Charting/
http://blogs.msdn.com/b/fsharpteam/archive/2012/07/19/more-about-fsharp-3.0-language-features.aspx
http://caxelrud.blogspot.com/2012/11/using-nosqlredis-in-windows-with-f.html
Lots of love for F# during Øredev
Last week I had tons of fun (and learning!) at Øredev conference in Malmö, Sweden. My full writeup is still yet to come, but as videos are popping up, I’d like to show you how well F# and functional programming in general were represented during conference. On second day, you could do a streak of 3 F# talks one after another!
This are links to talk pages, where you can find video (or in some cases not – hope it will pop up soon), grouped by presenters, sorted randomly. Let’s start with F# focused links:
- Concurrent applications with F# agents – by Rachel Reese
- Discovering type providers in F# 3.0 – by Rachel Reese
- F# for C# developers – by Phil Trelford
- F# for trading – by Phil Trelford
And off to less F#, but still interesting functional talks:
- Functional principles for object-oriented developers – by Jessica Kerr – this was awesome, one of best talk I attended at Øredev. Also had plenty of F# examples.
- Hands on with Clojure – by Bodil Stokke (warning: most likely contains ponies)
- Programming, only better – by Bodil Stokke
Bodil also gave talk on implementing your own lisp (in Clojure, of course) at nearby Foo Cafe. This was pretty hardcore, and I didn’t get much from it. But it was recorded, so smarter people will probably make use of that.
As you can see, lots of functional love. As always you could always hang out with speakers between/after sessions and ask them (in my case) some lame questions or see them hacking around. Great fun, and good opportunity to learn new stuff.
Progressive F# Tutorials in London
Yesterday I went for a crazy trip to London. At least most people would call that, because for me it was perfect. It had all I like – flying planes, meeting great people and learning new stuff. I woke up at 3 to catch 6 AM flight to London. Then take a train to center, took part in Prog F# Tutorials and then went back to airport to get on 8 PM flight. I was back home around midnight.
Prog F# Tutorials are two day F# conference organized by Skills Matter. In agenda you could find almost all the rock-stars of F# world – Don Syme, Phillip Trelford, Richard Minerich, Rachel Reese, Robert Pickering, Jon Harrop and Simon Cousins. Unfortunately, I could only attend first day due to medical procedure planned for today, but one day is always better then none.
First talk by Jon Harrop was about adopting F# by large insurance company. He talked about what are best ways to convince people to start using F#, what worked, and what didn’t. I would like this session to be more technical, but there were still few interesting points he mentioned. After that, public split into two rooms. In main one, Rich was live coding (with help of audience) to solve Bank OCR Kata. It was entertaining, and quite interesting to see how someone puts his F# knowledge to solve problems. The other group were solving F# Koans with Rachel Reese. After lunch went to Rachel’s workshop “From Zero to Data Science”. Based on tutorials, you can find on tryfsharp.org, we were “learning by solving” some extra tasks Rachel prepared for us. For beginner like me, some of them were really challenging. Another difficulty proved to be tryfsharp.org’s capacity. Around 100 people trying stuff out there killed the server and it started throwing 503s. Anyway, this was my favorite session of the whole day. In second room Robert Pickering was doing his Undertone session. And to wrap up, Phillip did quick talk about using F# in finance. Unfortunately I didn’t get to see Don Syme’s talk planned for the morning. He got stuck in Germany and didn’t get on time. Bummer, cause I anticipated this one the most.
The whole thing took place in the crypt below old church (this was Halloween! :)). This is so great place to host conference, so different than standard grey rooms. The only problem was, that it was not really wheelchair accessible. But Theo and his Skills Matter crew helped me get there. From logistics point of view everything went pretty great. There were constantly resupplied snacks and coffee, tasty lunch and beer for the end. Wifi worked with some issues, but it hold pretty well, considering over 100 people doing queries against tryfsharp.org.
To sum up – this was a good day. I am okay to travel halfway through Europe to get to events like that. I only wish I could also be there on second day, but maybe next year. I am really happy, that I met in person and talked to some F# pros, whom before that day I only followed on twitter. And Skills matter crew are awesome, and I definitely will look to attend their events in future.
BTW, if you are based in London are into F#, check out this meetup group.