Phone800.366.3472 SupportGet Support DocumentationDocumentation Resource CenterResource Center
search
close
Open Menu

Synergex Blog


CodeGen 5.7.3 Released

By Steve Ives, Posted on July 9, 2021 at 6:47 pm

Steve Ives

There’s a new version of CodeGen out there, so if you’re using it, here’s what’s changed in this version:

  • We added a new special structure expression token <STRUCTURE_HAS_FIELD_name> that allows you to detect the presence or absence of a named field within the structure.
  • We improved the logic used when processing unique key loops and unique alternate key loops and made a slight change to the way that the unique alternate key loops operate. Previously the loop would not compare alternate key segments with the primary key, but now it does. So the loop now processes any alternate keys that do not have identical key segments to the primary key or any previous alternate keys.
  • We fixed a problem with the implementation of the -pa command line option that would cause CodeGen to fail when used with an input file containing multiple structures.
  • We fixed a problem with the implementation of the -tweaks option which could result in a null reference exception in some rare circumstances.
  • We reviewed and updated all sample templates that ship with CodeGen to ensure they use the latest capabilities such as taking advantage of complex expressions to simplify template complexity resulting from nested expressions.
  • This version of CodeGen was built with Synergy/DE 11.1.1g and requires a minimum of version 10.1.1 to operate.

As always, this new release is backward compatible with earlier releases, so we recommend that everyone download the new version as soon as possible.


Another RESTful web service story

By Cindy Limburg, Posted on May 27, 2021 at 12:26 pm

Cindy Limburg

I hope you had a chance to attend some of the recent Synergy DevPartner Conference virtual sessions. There were many opportunities to learn about the latest Synergex technologies and how customers are taking advantage of them. One of the conference themes was the importance of creating RESTful web services with your legacy applications, and the sessions included some examples of customers doing this with our Harmony Core open-source product. We also just published a new customer success story, which describes how our customer RCC used Harmony Core to create a RESTful web service and provide its customer Legacy Vacation Resorts (LVR) with a new web portal.

Used by vacation property owners, the RCC Resort Management Solution offers features such as a central reservations system, contract management, and sales analysis. LVR offers travel experiences across Florida, Colorado, New Jersey, and Nevada. When COVID hit, LVR wanted to make their resorts safer and more comfortable for their guests. They decided to move their check-in process to the web so guests could minimize the time required to interact with LVR’s front desk agents.

RCC and LVR already had a web access solution, but it used Synergex’s proprietary xfServerPlus product, and they both wanted a more standards-based solution. This was a great opportunity for RCC to modernize their solution and provide a foundation for meeting future demands for access.

RCC started with the data/logic access routines they already had for xfServerPlus, expanded them to meet the needs of the new web service and web UI, and then added new OData controllers and a Harmony Core feature called “adapters” to expose the data and logic as OData resources. Code for the adapters and controllers was generated using Synergex’s CodeGen tool and RCC’s Synergy repository.

RCC and LVR were able to meet the project goals, and both are excited to move forward with their new web services solution. See the full success story for details (and some beautiful resort photos).

Mike Amundsen, the Synergy DevPartner Conference’s keynote speaker, said that when you’re getting started with web services and trying to figure out scope and boundaries, you should look for the smallest problem you have, fix that and learn from it, and then move on to the next smallest problem. In the “Leveraging Web Services for UI” conference session, customer Forward Computers had a similar message: start with a well-defined function. (They also advised making sure it’s not too simple, as you’ll want to evaluate performance.) The new customer success story describes how RCC and LVR got started with LVR’s self-check-in function. What function will you start with?

To learn more about web services and Harmony Core, refer to our web services training videos and our documentation.


CodeGen 5.6.9 Released

By Steve Ives, Posted on March 11, 2021 at 8:10 pm

Steve Ives

We are pleased to announce another release of CodeGen, once again including some significant advances in the technology. We recommend that all developers using CodeGen, and especially developers working with Harmony Core, should upgrade to this latest version as soon as possible. This new version includes these changes and enhancements:


CodeGen 5.6.6 Released

By Steve Ives, Posted on February 5, 2021 at 3:05 pm

Steve Ives

A quick post to announce the availability of CodeGen 5.6.6.  This is a quality release that addresses an issue that could occur when generating code from templates containing certain complex expressions. In particular, several Harmony Core templates contain such complex expressions, so we recommend that all Harmony Core developers upgrade to this new version of CodeGen at their earliest convenience. As always, documentation for this new release can be found at https://codegen.synergex.com.


CodeGen 5.6.5 Released

By Steve Ives, Posted on January 24, 2021 at 11:13 pm

Steve Ives

I am pleased to announce the release of a new version of CodeGen, and this release is quite a big one. The changes include the following:

This version of CodeGen was built with Synergy/DE 11.1.1f and requires a minimum of version 10.1.1 to operate.

We recommend that all CodeGen users upgrade to this version, particularly if you are doing Harmony Core development. You can download the new version from GitHub.


SQL Replication Enhancements

By Steve Ives, Posted on December 4, 2020 at 3:21 pm

Steve Ives

For several years now, Synergex has maintained an open-source example that provides an example of how to implement the replication of a Synergy applications data to a Microsoft SQL Server database, in near-to-real-time. The example environment makes considerable use of CodeGen to generate the bulk of the code needed to implement the interaction with the SQL Server database, and much of the remaining required code can be used out-of-the-box, requiring very little, if any change to the original Synergy application to enable the data replication to take place. The example environment has been used as a template by many customers, and our Professional Services team has assisted many others by delivering either proof of concept examples, or full-scale implementations.

As technologies and product capabilities evolve, we periodically revisit the code to ensure that it is taking advantage of the latest features and adhering to best practices. Good performance is also of critical importance in products like this, so we frequently revisit the code looking for opportunities to make improvements in throughput.

We have just completed the latest review of the code, and on this occasion, we did make some changes, which are briefly described below.

  • We now generate an additional function that returns the key number of the first unique key for each ISAM structure. This allows us to avoid the need for code that previously detected the first unique key number at runtime; that code required that the replicator had an open channel to each data file being replicated.
  • We also generate an additional function that, when passed a record containing data, returns the key value of the first unique key. Previously, the code used the Synergy routine %KEYVAL for this purpose, but it also requires that the replicator has an open channel to every data file replicated.
  • Because of the previous two changes, we were able to remove the replicator’s requirement to open the underlying data files that are being replicated. The only files that the replicator now opens are the instruction queue file and log file.
  • We added code to make the replicator more resilient to interruptions to network connections when using xfServer to access the instruction queue file on a remote system. If a network problem is detected, the replicator now closes the instruction queue file and then attempts to re-open it on a new channel. If this operation fails, it will retry several times with a delay between attempts. The number of retries and the delay between retries are both configurable via command-line options or environment variables.

If you already have a SQL Replication environment based on our sample environment, then you might consider checking out the latest version and applying the changes to your own codebase, and if you’d like some help with that, then our Professional Services team will be happy to assist. And if you haven’t yet implemented a SQL Replication environment but are interested in doing so, get in touch with your Synergex account rep and ask them to set up a demo.


CodeGen 5.5.5 Is Released

By Steve Ives, Posted on June 5, 2020 at 6:07 pm

Steve Ives

We are pleased to announce the release of a new version of CodeGen.

The primary reason for this release is that we realized that the installations for the last several releases were incorrectly signed, resulting in Windows SmartScreen reporting the installation as risky, and doing its level best to discourage you from proceeding.

The affected versions of the installer were versions V5.5.1 to V5.5.4. But apparently people don’t pay too much attention to Windows SmartScreen warnings, because I know there have been lots of CodeGen installations of the affected versions, and not a single person reported the issue! That’s pretty scary, and as software developers, we really should know better! With one exception (Jeff Greene), I don’t know who you are, but YOU know who you are!

The issue turned out to be related to the fact that we have been working from home for the last three months, thanks to COVID-19, and the code-signing process on my home development system was silently selecting the wrong signing certificate! Sorry about that! But rest assured, we restored normality with the 5.5.5 installer, which is, once again, signed with the correct code-signing certificate.

Oh, and if you are looking for new features, we also made all method loop expansion tokens available in parameter loops.

This version of CodeGen is built with Synergy/DE 11.1.1c, needs a minimum of version 10.1.1 to operate, and can be downloaded here.


CodeGen 5.5.2 Released

By Steve Ives, Posted on March 19, 2020 at 12:47 am

Steve Ives

Apologies for being only a few days after the last CodeGen release, but we’ve been hard at work and have added some really cool new features, and we wanted to share them with you as soon as possible. We have added support for complex expressions, which allow you to use AND, OR and NOT within expression tokens, and also allows you to use parentheses to explicitly define precedence. Here are some examples:

<IF expression_1 AND expression_2>
[code]
</IF>

<IF expression_1 OR expression_2>
[code]
</IF>

<IF NOT expression_1>
[code]
</IF>

<IF NOT expression_1 AND expression_2>
[code]
</IF>

<IF expression_1 AND(expression_2 OR expression_3)>
[code]
</IF>

<IF expression_1 OR expression_2>
[code]
<ELSE expression_3 AND expression_4>
[code]
<ELSE>
[code]
</IF>

We hope you’re as excited as we are about these significant new capabilities.


CodeGen 5.5.1 Released

By Steve Ives, Posted on March 16, 2020 at 10:04 pm

Steve Ives

We are pleased to announce a new CodeGen release that includes a significant new feature named Complex ELSE Clauses. We have some big plans to further enhance IF/ELSE expressions, but for now this initial new feature can be used to simplify complex template file expressions. Here are the full release notes for the new version, which can be downloaded from https://github.com/Synergex/CodeGen/releases.

  • We added support for Complex ELSE Clauses within expressions, which allow multiple expressions of the same type to be evaluated within a single template file construct. We have future plans to extend the capabilities of expressions even further, but for now this new capability can be used to simplify template file code.
  • We improved the error checking that occurs when a processing a Harmony Core Customization File.
  • When using the CodeGen API we have added the ability to specify lists of file overrides at the TaskSet level.
  • We corrected an error that was causing the <HARMONYCORE_BRIDGE_PARAMETER_TYPE> custom expansion token to return incorrect values for structure parameters.
  • This version of CodeGen was built with Synergy/DE 11.1.1c and requires a minimum of version 10.1.1 to operate.

SQL Replication – Significant New Features

By Steve Ives, Posted on January 16, 2020 at 8:10 pm

Steve Ives

In recent weeks we have been working on making improvements to our SQL Replication environment, which demonstrates how to easily replicate your Synergy data to a SQL Server database. Some of these changes were undertaken in collaboration with a customer that uses the environment extensively, and we thank them for their input and support. Other changes have been on our road-map for some time and we think you’ll be excited about what has been achieved. Here’s a summary of the changes:

  • Synergy 11 introduced a new SQL Connection API capability which calls the ODBC API function SQLDescribeParam behind the scenes to improve performance and avoid excessive cache memory thrashing for SQL statements that have I/O parameters when accessing SQL Server (VTX12_SQLNATIVE). Synergex recommend setting SSQL_PERFORMANCE_SQL to yes (or setting the SQLPERFORMANCESQL environment variable. We have updated the environment to do this, which should result in improved performance when running in Synergy 11 or higher environments.
  • We have added the ability to run multiple instances of the replicator process side-by-side, within a single data set, and to divide up the replication of different files between these multiple replicator instances. Each instance is assigned a unique instance name and has its own associated instruction queue file, the name of which includes the instance name, as does the log file produced by each instance. In a multi-instance environment developers can chose on a file-by-file bases which data files are replicated via which queue file, and therefor via which replicator instance. It is important to understand that in this scenario there is no synchronization of the sequence in which changes are applied to the underlying SQL database between the multiple instances of the replicator.
  • We have added the ability to exclude certain fields in a record from being appearing in and being replicated to the associated SQL Server database table. It is important that fields associated with keys not be excluded, unless those keys are also excluded (see the next item). Generally the fewer fields/columns that are replicated the faster the replication will be.
  • We have added the ability to exclude certain keys from processing, so that matching database indexes will not be created in the associated database tables. Generally the fewer indexes that exist on a table the faster the replication will be.
  • We have added the ability for the replicator to detect some kinds of database failure, caused by network errors, or the database being shut down or otherwise unavailable, and allow it to gracefully disconnect, and then attempt to reconnect, with a configurable number of retries and retry interval. This should make the replicator processes more robust.
  • We have added the ability to change the database datatypes of fields. The main use case envisaged is transforming decimal fields into implied decimal fields (adding decimal places in the database data), but there may be other use cases, such as transforming Y/N fields into Boolean true/false fields, etc.
  • We have also corrected an issue that could occur if replicator encountered an unexpected error and was configured to use BATCH COMMIT mode. Is some circumstances, if there were uncommitted changes at the time on an error any uncommitted changes could be lost because the change records were deleted from the instruction queue one by one before the batch was committed. Now any instructions related to uncommitted changes remain in the queue file until the batch is committed, and are then all deleted. When the replicator is restarted it will then attempt to reply the changes to the database again. This should help prevent the database getting out of sync if there is a replicator failure.

We’re excited about these new features in our SQL Replication offering and looking forward to hearing your feedback. By the way, many of these new features rely on using the latest and greatest version of CodeGen (5.4.8) which was also released today. If you’re already using an earlier version of the SQL Replication environment, or if you are interested in getting started and would like some assistance, don’t hesitate to contact us through your Synergex Account Representative.


CodeGen 5.4.3 Released

By Steve Ives, Posted on September 22, 2019 at 1:01 pm

Steve Ives

I am pleased to announce that another new version of CodeGen has been released, is available for immediate use, and contains several powerful new features:

  • We added a new structure expression token <IF STRUCTURE_PII_FIELDS> that indicates whether any field in a structure has been tagged as containing PII (Personally Identifiable Information). We also added a new field loop expression token <IF PII_SCRUB> that indicates whether a field has been tagged as containing PII data, and a new field loop expansion token <FIELD_PII_TYPE> which inserts the type of PII data a field contains.
  • We added a new field loop expression token <IF USED_IN_RELATION> that can be used to determine whether the field currently being processed is involved in any relations to other structures.
  • We added a new custom field loop expression token <IF HARMONYCORE_CUSTOM_FIELD> and a new custom field loop expansion token <HARMONYCORE_CUSTOM_FIELD_TYPE> to the Harmony Core extensions assembly. In a future release Harmony Core will use these new features to allow developers to easily implement support for custom field types that may be implemented within their applications data set.
  • We added a new tag loop expansion token <TAGLOOP_FIELD_SNTYPE> and relation key segment loop expansion token <LITERAL_SEGMENT_SNTYPE>.

Additionally, because the Symphony Framework is no longer maintained by Synergex, and is no longer an open source development effort, we have decided to discontinue the distribution of the “Symphony Framework CodeGen Extensions” assembly that was formerly distributed along with CodeGen. We continue to support the addition of custom extensions and the Symphony Framework extensions can be added back at any time by any Synergy developer with the necessary Synergy .NET development tools.

This version of CodeGen was built with Synergy/DE 11.1.1 and requires a minimum of version 10.1.1 to operate.


Enhanced CodeGen CreateFile utility

By Steve Ives, Posted on August 26, 2019 at 9:58 pm

Steve Ives

For some time CodeGen has shipped with a utility called CreateFile that (given an appropriately configured repository) could be used to create an ISAM file based on a repository FILE or STRUCTURE definition.

A customer recently asked me to create a mechanism that they could use to create multiple files, load data into those files, and also support creating both RELATIVE and ISAM files. Rather than writing something completely new I decided to extend the CreateFile utility, and that new feature has now been released along with the latest version of CodeGen (5.4.2).

Briefly, there is a new command line option -in that allows you to specify an input file containing the details of one or more files to be created and and populated. The file uses a JSON format. If you’re interested in finding out more you can find additional information in the CodeGen documentation.


CodeGen 5.4.0 Released

By Steve Ives, Posted on July 3, 2019 at 9:59 am

Steve Ives

It’s been a while since a GodeGen release was announced on this BLOG, but rest assured they have been coming thick and fast; in fact there have been 9 interim releases since we last announced here.

So why all the frenetic activity in CodeGen land? Well the primary driving force for so many releases and so many new features is to provide support for the ever evolving Harmony Core RESTful Web Services framework. If you’re not familiar with Harmony Core then you should check it out. More and more Synergy developers are starting to take advantage of it as a way to expose their applications data and business logic in whole new ways and to support a myriad of use cases.

So what’s new in CodeGen 5.4.0? Well the answer to that question is … a LOT! I won’t list all the new features here but if you want to check out the specifics then you can head over to the CodeGen Releases page where you’ll find a detailed change log for this and previous versions. And if you need more information than that then check out the CodeGen Documentation.

We recommend that all developers who are using CodeGen upgrade to this latest version, but particularly if you’re developing with Harmony Core.

Happy 4th Everyone!


CodeGen 5.3.6 Released

By Steve Ives, Posted on September 23, 2018 at 4:43 pm

Steve Ives

Just a quick note to announce that CodeGen 5.3.6 has been released and is available for immediate use. This latest version represents the culmination of a series of recent releases which together have added significant new features across the entire product, including the ability to generate code based on metadata found in the xfServerPlus Synergy Method Catalog.

Many of the new features were added specifically to support code generation for the new Harmony Core RESTful web services framework that we are excited to be introducing at the upcoming DevPartner Conference in New Orleans next month.

If you are joining us for the post-conference Harmony Core workshop then you will need to have this new version of CodeGen installed on your development system; you can download it here. And even if you’re not intending to use the new Harmony Core framework, there are many new features that may be useful to all CodeGen users; we recommend this release for general use.

We’re looking forward to seeing you all in New Orleans between October 8th and 12th. If you haven’t signed up yet, it’s not too late! You can still sign up here.


CodeGen 5.2.3 Released

By Steve Ives, Posted on December 1, 2017 at 11:18 pm

Steve Ives

We are pleased to announce the release of CodeGen version 5.2.3. The new release includes new features, addresses some issues found with previous releases, and also paves the way for once again being able to use CodeGen on non-Windows platforms through experimental support for the .NET Core environment.

As always, you can download the latest version of CodeGen from here.

CodeGen Version 5.2.3 Release Notes

  • Added a new experimental utility to the distribution. The Code Converter utility can be used to automate bulk searches within and bulk edits to an applications code. This utility is in a usable form. However, it is still a work in progress and is likely to undergo substantial changes as it evolves.
  • Added two new utility routines (IsDate.dbl and IsTime.dbl) that are referenced by some of the supplied sample template files.
  • Corrected a regression that was introduced in the previous release which caused the field loop expansion token <FIELD_SQL_ALTNAME> not to default to using the actual field name if no alternate name was present.
  • Performed an extensive code review and cleanup, updating the code in several areas to take advantage of new features available in the Synergy compiler, and also improving efficiency.
  • Fixed an issue that was causing the CreateFile utility -r (replace file) option to fail, an existing file would not be replaced even if the -r option was specified.
  • Fixed an issue in the CreateFile utility that would result in an unhanded exception in the event that invalid key information was passed to XCALL ISAMC.
  • Made some minor code changes to allow CodeGen to be built in a .NET Core environment and we hope to be able to leverage .NET Core to once again support the use of CodeGen on non-Windows systems (starting with Linux) in the near future.
  • This version of CodeGen was built with Synergy/DE 10.3.3d and requires a minimum Synergy version of 10.1.1 to operate.

Symphony Framework Components

  • We no longer ship the Symphony Framework sample templates with CodeGen. You can obtain the latest Symphony Framework templates from the Symphony Framework web site (http://www.symphonyframework.net).
  • There were no Symphony Orchestrator changes in this release.
  • There were no Symphony Framework CodeGen Extensions changes in this release.

Don't miss a post!

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Recent Posts Categories Tag Cloud Archives