Physicians Realty Trust (PRT) is a real estate portfolio management company that focuses on the healthcare industry. They purchase and operate the real estate assets for many of the largest hospitals in the country. In order to do so effectively, they must maintain oversight on a range of building projects, covering both maintenance and renovations, across all of the sites in their portfolio. For an organization of their size this becomes a challenging problem, with the relevant information siloed into isolated systems.
In PRT's case, their operations team used a SaaS product called Clarizen for their internal project management, tracking the current status and progress made on various projects across all of their sites. The finance team however used an enterprise real estate management platform called Yardi to track all project expenses and generate the necessary accounting reports. As a result, they struggled to maintain consistent visibility into both the operational and financial status of a project and were required to manual synchronize data across these two systems in an attempt to keep them aligned and up to date.
To alleviate this burden, PRT engaged with another software consulting team to develop a bi-directional integration between Clarizen and Yardi. This integration would allow projects, created within Clarizen, to automatically generate an associated account within Yardi. Subsequently, when an expenses is recorded against the Yardi account, the system would automatically synchronize this against the associated project within Clarizen. This system was developed as a stand alone Ruby on Rails service that managed a set of nightly jobs extracting data from each system and relaying it into the other. The project was nearing completion when the consulting team decided to disband and head in separate directions. I was asked to step in and take responsibility for the system, driving it through to completion and continuing to maintain and extend the system as needed.
Clarizen exposes an HTTP interface that was relatively modern and well suited to our use case. This API allowed us to extract the set of newly approved projects and to record expenses against existing projects with ease. Yardi on the other hand is a bit more antiquated, proving more challenging to integrate with. In order to deliver the list of newly approved projects into Yardi, they had to be packaged as a CSV file and uploaded to an SFTP server. A scheduled job within Yardi was then configured to retrieve and process this file, creating the an account for each project specified. The job would then extract the updated expenses for all associated accounts and generate a CSV file with this content, depositing it back into the same SFTP server.
Overall this was a fairly straight forward integration. After quickly getting my bearings within the system, I was able to work with members of both the finance and operations team to complete and validate this integration. We ran into a few snags related to the configuration of the necessary tasks within Yardi, but by proactively engaging with the appropriate team members to debug these issues in realtime we were able to identify and correct the root cause of the issue and get the system up and running.
After the system's initial launch, I remained engaged with the team, providing maintenance support and developing additional features as requested. The following are a few of the additional items I worked on in this capacity:
Code Quality: When I inherited the codebase there was no test coverage, minimal documentation, poor code organization, and a handful of readily apparent performance bottlenecks. As part of my work to get ramped up on the system, I immediately added test coverage for core portions of the synchronization workflow. I then refactored this workflow into a set of four service classes, one for extracting data from Clarizen, one for uploading data into Yardi, one for extracting data from Yardi, and the final one for uploading data into Clarizen. In the process I also pulled out two integration clients, one for Clarizen and one for Yardi, to isolate the common aspects of communicating with these services. This provided a logical decomposition of the functionality and made it significantly easier to implement new features going forward. I recorded a list of the remaining items to be addressed and gradually tackled them down the road as I made changes in the related areas of the system.
Observability: In addition to the code quality concerns identified, the system initially had no logging, monitoring, or alerting configured. This, coupled with the fact that the associated servers were only turned on for the one hour time frame during which the associated jobs were scheduled, meant that I was essentially flying blind in terms of how the system was behaving in production. To address this, I integrated the application with LogDNA to begin collecting logs. I also set up alerts to receive an immediate notification whenever an error occurred. This allowed me to stay one step ahead of the rest of the team and proactively notifying them when the daily job failed to complete as expected, including the steps I was taking to address the immediate issue as well as the underlying root cause.
Automated Error Handling: As a middleware platform, the application was subject to the quality of the data provided by each downstream system. As a result, it was all to common for invalid data within either of these systems to prevent the middleware from successfully synchronizing various records. To address this, I updated the middleware to identify and gracefully handle cases in which a project or its expenses failed to be relayed into either system. In such cases, the application gracefully re-extracted and reprocessed the record on the following days until it could be successfully imported into the target system. This allowed for data corrections in either system to be automatically picked up and for intermittent failures to gracefully correct themselves.
Detailed Project Accounting: The initial integration of these two systems was designed to extract only the current total expenses for each account from Yardi and to record this single value against the associated project in Clarizen. This provided valuable but limited insight into the expenses incurred on each project over time. As a result we refined the integration to extract the individual expenses for each project and to record them individually against their associated project. This provided much greater insight into each project's expenses and enabled additional analysis to be performed by the operations team entirely within Clarizen.
Overall the integration alleviated a significant pain point for the PRT operations team, removing the need for them to work within the Yardi system, and consolidated the information needed to run their business into Clarizen. This resulted in a noticeable improvement in the efficiency and effectiveness of the team, allowing them to more easily manage the numerous projects in progress across the PRT portfolio at any given time.