LLBLGen Pro Changelog

What's new in LLBLGen Pro 4.0

Nov 6, 2013
  • New/changed in the LLBLGen Pro designer:
  • Migrating project files:
  • You can use the current version's designer side-by-side with a previous versions of the designer and previous LLBLGen Pro versions. You can load project files saved in previous versions without conversion to the current one. A warning will be shown when you save the project for the first time, as the project is initially in v3.x format. You can load project files saved in the current version in v3.x but you'll lose some information which is specific for v4.0. Saving the project again in v3.x will therefore make the project lose this information.
  • Migrating your v3.x project to the current version is the easiest if you first use a copy of your v3.x project with v4.0, so you can roll back to v3.x's version if you have to. As the project file is XML based, a good source control system will help you with that.
  • Migrating preferences:
  • When you first start v4.0 and you have used v3.x on the same system before, your v3.x preferences will be migrated to v4.0 as a copy, leaving your v3.x preferences as-is. For new settings, the defaults are chosen.
  • New designer preferences and project properties:
  • TableValuedFunctionNameStripPattern. This pattern is similar to the stored proc name strip pattern, except it's now used for constructing TvfCall names.
  • TypedViewMappedOnResultsetPattern. This pattern is used to create the typedview name when it's been reverse engineered and it's mapped onto a resultset of a stored proc or tvf. Marco elements: {$ResultsetName} and {$ProcFunctionName}. Default: {$ProcFunctioName}{$ResultsetName}TypedView. {$ResultsetName} is ignored if the procedure or function has just one resultset.
  • DefaultRelationshipDeleteRuleAction. This setting controls the default value for the Delete Rule Action for new relationships. Update Rule and Delete Rule are used for cascade settings on the backing foreign key constraint (if applicable). Default: Cascade. In project settings, this setting is available under Model First development.
  • DefaultRelationshipUpdateRuleAction. This setting controls the default value for the Update Rule Action for new relationships. Update Rule and Delete Rule are used for cascade settings on the backing foreign key constraint (if applicable). Default: NoAction. In project settings, this setting is available under Model First development.
  • Removed designer preferences / project properties:
  • The following preferences/ project settings have been removed.
  • ShowProjectPropertiesAfterProjectCreate. This setting has been removed, as it's no longer used because the Actions Suggested/Available Actions window has taken over the task to tell the user to review the project settings after a project has been created.
  • New / changed / fixed functionality:
  • The following functionality is new, has been changed / updated or was fixed/corrected in this release.
  • Additions:
  • Visual studio integration (2010/2012). The designer is now fully integrated in VS.NET 2010 and VS.NET 2012. The stand-alone designer is also available so you can choose in which environment you want to use the designer.
  • Table Valued Functions support. The designer now supports Table Valued Functions in the designer, which allows you to map an entity or typed view on the resultset of the Table Valued Functions.
  • Rule based .NET Additional Interfaces / Namespaces. It's now possible to specify a rule using fine-grained expressions with an additional interface or additional namespace to define which elements of a given type will receive the additional interface or additional namespace. Rules can be assigned to additional interfaces / namespaces on the project level, to make it even easier to define attribute definitions in bulk for many elements in the project.
  • Update / Delete rules for FK constraints. It's now possible to define update / delete rules (Cascade rules) for relationships and Foreign Key constraints in both database first and model first.
  • SQL Server 2012 Sequence support. The SQL Server driver now retrieves Sequence definitions from SQL Server 2012 databases, and allows you to use them in mappings. You can also create new sequences for SQL Server 2012 from within the designer, like you can for Oracle, DB2, Firebird and PostgreSql.
  • Action suggestions window. The designer now offers an action suggestions window, which shows what actions are recommended, given the last action of the user, the state of the project / designer. The action suggestions window help with navigating the designer in common tasks, in case a particular feature might be hard to find.
  • Custom type shortcuts now have default length/precision/scale. A type shortcut can now have a default length, precision and/or scale value which is automatically used when the type shortcut is used as a field type. This allows type aliasing and easier modeling: e.g. one could define a type shortcut called 'Email' which is a type shortcut to string with a length of 150.
  • Char String system type converter. The list of system type converters has been extended with a new char string system type converter which allows you to map a char typed model element onto a DB element with type string of length(1). This is useful if you have char(1) fields in the database, which are often converted as 'string' by ADO.NET providers.
  • Re-scan of enum .typeimport files. It's now possible to re-scan the folders which have .typeimport files for changes to import enum types while the designer is open. This makes importing enum types much easier as the designer doesn't have to be closed and re-opened again.
  • Changes:
  • The designer is now a .NET 4.0 application. No more .NET 4.0 runners needed.
  • .NET 2.0 and .NET 3.0 are no longer supported as target platform.
  • .typeimport files are now also searched in the folder where the llblgenproj file has been loaded from.
  • The initial destination folder for generating code is now set to '.\', which means the project file location.
  • If there's just one catalog in the project, the generated connection string will refer to that catalog as the catalog to connect to.
  • Backup filenames are now named with the yyyyMMddHHmmss suffix.
  • Code generators don't need destination folders to exist. The DirectoryCreator task is now redundant if you use the shipped code generators.
  • Enum type checks are now less strict: the .net type of the db field has to be one of the allowed underlying .NET types for enums for .NET: sbyte, byte, ushort, short, uint, int, ulong, long. It doesn't have to match the underlying .NET type of the used enum type.
  • Type shortcuts are automatically created for imported enum types if there's no type shortcut defined yet for the enum.
  • New/changed in LLBLGen Pro Runtime Framework:
  • New functionality / changes:
  • General:
  • 50% faster entity fetches:
  • An extensive refactoring of the internal storage of values inside an entity instance resulted in up to 50% faster entity fetches. As entity instances don't have Entity Field instances to store their values anymore (though from the outside it will appear they will, so no code will break), memory footprints are smaller too.
  • Extensible Query Result Caching:
  • It's now possible to specify (in Linq or QuerySpec, and with minor effort also with low-level API calls) a query result cache directive to tell the runtime to cache the results for that particular query for a given amount of time. The caching system is build around an easy interface, making it easy to extend it with own cache providers for cache systems like Redis.
  • Table Valued Function support:
  • It's now possible, using Linq and QuerySpec, to fetch entities and typed views which are mapped onto a table valued function resultset.
  • DataScopes:
  • The runtime framework now offers DataScopes which greatly help managing data in memory in desktop applications.
  • Runtime Libraries are now compiled against .NET 3.5:
  • The minimum .NET version supported by the runtime framework is now .NET 3.5.
  • LinqSupportClasses and QuerySpec assemblies are now merged into ORMSupportClasses:
  • The 3 assemblies are now merged into one, SD.LLBLGen.Pro.ORMSupportClasses.dll. This makes referencing assemblies simpler.
  • Inlining of Value Type Definitions in the designer:
  • It's now possible to in-line value type definitions in the designer, which makes modeling LLBLGen Pro projects simpler.
  • SQL Server 2012 sequences support:
  • The runtime framework now supports SQL Server 2012 sequences in insert queries.
  • TypedLists can now be fetched using QuerySpec:
  • Before, the low-level API had to be used to fetch typedlists. In v4.0 we made it possible to fetch TypedLists using the more powerful QuerySpec query API.
  • True skip/offset support:
  • It's now possible to skip n rows in a fetch without the requirement that the number of rows fetched is a multiply of n. This is in line with how Skip works in Linq. QuerySpec now has a new operator, Offset(n) which offers the same functionality.
  • Char String(1) built-in type converter:
  • The runtime framework now has a built-in type conversion for char string(1), to make it possible to have a DB field of type char(1) be used as a .NET char typed field.
  • Support for OData v3:
  • The ODataSupportClasses now support OData v3 and are now compiled against WCF Data Services v5.3.
  • QueryExecution Tracer:
  • A new tracer has been added, to trace the actual query being executed. This information was already available through other tracers, but as these also emitted other information it could lead to a lot of data just to see which query was actually executed. This tracer solves that.
  • All low-level query API elements, including UnitofWork2, are now XML Serializable:
  • All low-level query API classes, like predicates, relation collection, groupby collection but also the Unit of Work classes, are now serializable to XML, and as such passable to e.g. a WCF Service. This is for Adapter only.
  • Small changes / fixes:
  • Changed:
  • SourceFieldFinder:
  • The SourceFieldFinder is now a public class so it can be used to traverse entity graphs in user code.
  • Better name length clamping in DB2 and Oracle DQEs:
  • Names were already limited to 30 characters or less for DB2 and Oracle, but in some edge case queries with nested derived tables it could be the field inside a derived table was clamped to a shorter name, but a field referencing it wasn't. Name clamping now uses F__hashcodeOfStringToClamp which is not depending on field index anymore.
  • The runtime assemblies are now stored all in one folder:
  • In previous versions the runtime library assemblies were stored in different folders, based on the .net version they were for. This is not needed anymore, so all files are stored in one folder.
  • DbCommands are now, when possible, created from DbConnection:
  • This makes it easier to add functionality like the miniprofiler to the generated code.
  • DataProjectorToDataTable now creates columns from projectors:
  • This change has the advantage that if the resultset to project has 0 rows, the columns in the datatable are still created.
  • Fixed:
  • Add auto-type filter if projection contains fields of 1 type only
  • IRetrievalQuery requires a flag to signal no name overwriting required
  • ObjectGraphUtils uses GetMemberEntityCollections which triggers collection creation on adapter. It now uses less intrusive methods, so it doesn't trigger collection creation.