Showing posts with label deployment. Show all posts
Showing posts with label deployment. Show all posts

Friday, March 18, 2016

The fish is out

nemonewThis is a project I’ve worked for several months now. It was internally called “project Nemo” (I like having internal project names) and it was about speeding up the process of generation.
In one of our regulars Development Team Meetings (DTM) somebody mentioned about an issue where generating Genexus’ Structured Data Types (SDTs) was taking too long, and how she was fighting that issue. That got me thinking that SDTs are “simple” classes definitions, I mean there’s no complex logic on finding related tables, closure, and stuff for what prolog is very good. So we started talking with Gastón about it and we thought it would be a good sample of simple template-based code generation. What does that mean? if you take a look at the generated code of an SDT it starts with a class definition, some initialization methods, property definitions, serialization methods (ToJson) and finally the rest interface with its properties. Every single SDT is generated with the same components.
 
 

So what is Nemo?

Nemo is a new generator for SDTs (for now) that uses StringTemplate technology for code generation. The generation has two parts, a “specificator” and the code generator itself.
The specificator “listens” to internal Genexus events like saving or deleting an object. If this object is an SDT, it specifies it. That specification is a serialization of every property of the SDT needed for later generation. That specification is saved as a json file which is then read by the generator, to generate (of course) the source for that SDT, it could be one or many source code files depending on the levels of an SDT.

WIIFY

So, “what’s in it for me?” you might say. Well, it depends on the size of your KnowledgeBase (KB) and the amount of SDTs in that KB, but we’ve seen generation times cut off by 30%, which we believe is pretty good for a start.

Roadmap

Right now, Nemo is turned on by default in Genexus Salto Beta 2, released last week (March 10th). Right now it’s only generating C#, Java is expected for the Beta 3 release. Also, there are other objects that can be generated by Nemo, like Domains, BusinessObjects (BCs) and that is also under the radar.
So give it a try, download the beta 2 of Genexus Salto and start taking advantage of the improvements.

Read Full Post

Saturday, November 29, 2014

Deploy to Azure button, WOW!

Deploy to Azure Button

Every now and then some technology, technique, product or whatever comes along that makes you open your eyes wide open and drop your jaw.

A few days ago Microsoft released the Deploy to Azure button, you can read the original post here, but TL;DR it’s a button you put in the README.md file of your GitHub repository and it would “automagically” deploy your repository to an Azure Web Site.

At first I thought, cool, but I’m sure there’s something they’re not telling you, like what’s the structure I need to have in my repository? do I also need to add my binaries, will they build my solution and deploy the assemblies?

So today I gave it a try. I do have a repository on GitHub which output also run on an Azure WebSite so I thought this would be the perfect test. The project is Azure Storage Explorer, and if you take a look the structure of the repository looks it is just a solution file (.sln) with two folders that are a web site project and a helper library.

github

So I added the button to my README.md file which in my case that meant adding this line to the file:

[![Deploy to Azure](http://azuredeploy.net/deploybutton.png)](https://azuredeploy.net/?repository=https://github.com/sebagomez/azurestorageexplorer)

And that’s it. After I pushed it to GitHub I clicked on the button and this site called azuredeploy.net showed up telling me that my repository was going to published to an Azure Web Site. It let me pick a few config settings like the name of the web site AND THAT WAS IT!

What happened in between? I don’t know, I guess something cloned my repo, found and .sln file and built the solution and then moved everything (?) to a web site? I don’t know what they did, I’m just glad it worked the way it did. I’m not saying it is rocket science, it’s just that it’s nice when you find such a simple solution for a much complicated task to do manually.

Kudos to whoever thought having that button was a good idea!

p.s: I wish we had something like that in Genexus Server. I guess we could…

Read Full Post