Senzing v4 Beta SDK Breaking Changes

Senzing SDK Breaking Changes

In the following section, C/C++ language function names are listed. The function renames are very similar for Java and Python. For example:

  • C/C++: Sz_addRecord
  • Java: add_Record
  • Python: addRecord
  • sz_command: getRecord

Install Path Changed

  • /opt/senzing/er/ (was /opt/senzing/g2/)

Executables Removed

  • dbexport: A program used for retrieving data from the G2 database repository, originally built for working with different non-sql database types

Executables Changed

  • bin/sz_configupgrade (was bin/g2configupgrade)
  • bin/sz_dbupgrade (was bin/g2dbupgrade)

Python Scripts and Utilities Changed

  • bin/sz_audit (was python/G2Audit.py)

  • bin/sz_command (was python/G2Command.py)

  • bin/sz_configtool (was python/G2ConfigTool.py)

  • bin/sz_explorer (was python/G2Explorer.py)

  • bin/sz_explorer (was python/G2Explorer.py)

  • bin/sz_file_loader (was python/G2Loader.py)

  • bin/sz_setup_config (was python/G2SetupConfig.py)

  • bin/sz_snapshot (was python/G2Snapshot.py)

Python Scripts Removed

  • CompressedFile.py
  • DumpStack.py
  • G2S3.py

Function Prefix Changed

All C/C++ functions now start with the prefix Sz_. Any existing functions have been renamed from G2_ to Sz_.

New SzEngine SDK function

  • Sz_preprocessRecord

SzEngine (G2Engine) Functions Renamed

  • G2_findPathExcludingByEntityID is renamed Sz_findPathByEntityIDWithAvoids

  • G2_findPathExcludingByEntityID_V2 is renamed Sz_findPathByEntityIDWithAvoids_V2

  • G2_findPathExcludingByRecordID is renamed Sz_findPathByRecordIDWithAvoids

  • G2_findPathExcludingByRecordID_V2 is renamed Sz_findPathByRecordIDWithAvoids_V2

  • G2_findPathIncludingSourceByEntityID is renamed Sz_findPathByEntityIDIncludingSource

  • G2_findPathIncludingSourceByEntityID_V2 is renamed Sz_findPathByEntityIDIncludingSource_V2

  • G2_findPathIncludingSourceByRecordID_V2 is renamed Sz_findPathByRecordIDIncludingSource_V2

SzEngine (G2Engine) Functions Removed

Several SDK functions have been removed from the SDK. In most cases, another function exists with the same functionality as the previous function, but with an improved signature. If applicable, a remediation is suggested.

  • G2_addRecordWithReturnedRecordID: Use Sz_addRecord and always pass in a RECORD_ID

  • G2_addRecordWithInfoWithReturnedRecordID: Use Sz_addRecordWithInfo and always pass in a RECORD_ID

  • G2_whyEntityByEntityID: Sz_howEntity is the preferred method for explaining resolutions

  • G2_whyEntityByRecordID: Sz_howEntity is the preferred method for explaining resolutions

  • G2_process: This was internal, though we were using it in 3.x for the Sz_getRedoRecord/Sz_process pattern, which is now Sz_getRedoRecord/Sz_processRedoRecord

  • G2_processWithInfo: This was internal, though we were using it in 3.x for the Sz_getRedoRecord/Sz_process pattern, which is now Sz_getRedoRecord/Sz_processRedoRecord

  • G2_processWithResponse: This was internal, and is now fully removed

  • G2_processWithResponseResize: This was internal, and is now fully removed

  • G2_exportConfig: Equivalent functionality is now available in the SzConfigMgr SDK

  • G2_exportConfigAndConfigID: Equivalent functionality is now available in the SzConfigMgr SDK

  • G2_checkRecord: Internal function now fully removed

  • G2_purgeRepository: Moved to the internal SzDiagnostic SDK. Now an internal function

WithInfo Functions

The addRecordWithInfo and deleteRecordWithInfo functions have been removed from the Java SDK and Python SDK. The WithInfo functionality has now been included in the addRecord and deleteRecord functions when the SZ_WITH_INFO flag is used.

Internal SzDiagnostic Functions Added

  • SzDiagnostic_purgeRepostiory: Moved here from the main SDK

Internal SzDiagnostic Functions Removed

We removed the following functions, all of which were undocumented, and for internal-use only.

  • G2Diagnostic_getPhysicalCores: ({undocumented)

  • G2Diagnostic_getLogicalCores: ({undocumented)

  • G2Diagnostic_getTotalSystemMemory: ({undocumented)

  • G2Diagnostic_getAvailableMemory: ({undocumented)

  • G2Diagnostic_getDBInfo: ({undocumented)

  • G2Diagnostic_getDataSourceCounts: ({undocumented)

  • G2Diagnostic_getMappingStatistics: ({undocumented)

  • G2Diagnostic_getGenericFeatures: ({undocumented)

  • G2Diagnostic_getEntitySizeBreakdown: ({undocumented)

  • G2Diagnostic_getEntityDetails: ({undocumented)

  • G2Diagnostic_getResolutionStatistics: ({undocumented)

  • G2Diagnostic_getRelationshipDetails: ({undocumented)

  • G2Diagnostic_getEntityResume: ({undocumented)

  • G2Diagnostic_getEntityListBySize: ({undocumented)

  • G2Diagnostic_fetchNextEntityBySize: ({undocumented)

  • G2Diagnostic_closeEntityListBySize: ({undocumented)

  • G2Diagnostic_findEntitiesByFeatureIDs: ({undocumented)

  • G2Diagnostic_getFeature: ({undocumented)

Internal SzAudit (G2Audit) Functions Deprecated

This SDK is now considered to be fully deprecated, and should not be used anymore.

Internal SzConfig (G2Config) Functions Deprecated

This SDK is identical to that of version 3.12, which already had most of the config-altering functions removed.

Engine Flags

Flag Prefix Changed

All flags now start with the prefix SZ_. Any existing flags have been renamed from G2_ to SZ_.

New Flags

  • SZ_ENTITY_INCLUDE_RECORD_TYPES: Include record types in the entity documents

  • SZ_ENTITY_INCLUDE_RELATED_RECORD_TYPES: Include record types for related entities in the entity documents

  • SZ_ENTITY_INCLUDE_RECORD_UNMAPPED_DATA: Include unmapped data in the entity documents

  • SZ_ENTITY_INCLUDE_MATCH_KEY_DETAILS: Include a more detailed version of the match keys for entities and relationships

  • SZ_FIND_PATH_MATCHING_INFO: Include the relationship matching info for entity relationship paths

  • SZ_FIND_NETWORK_MATCHING_INFO: Include the relationship matching info for networks of related entities

  • SZ_SEARCH_INCLUDE_MATCH_KEY_DETAILS: Include the detailed match key information in search results

  • SZ_FIND_NETWORK_DEFAULT_FLAGS: Similar to G2_FIND_PATH_MATCHING_INFO, but more focused on graphs

  • SZ_WHY_ENTITIES_DEFAULT_FLAGS: Similar to the removed flag G2_WHY_ENTITY_DEFAULT_FLAGS, focused specifically on the whyEntities* SDK functions.

  • SZ_WHY_RECORDS_DEFAULT_FLAGS: Similar to the removed flag G2_WHY_ENTITY_DEFAULT_FLAGS, focused specifically on the whyRecords* SDK functions.

  • SZ_WHY_RECORD_IN_ENTITY_DEFAULT_FLAGS: Similar to the removed flag G2_WHY_ENTITY_DEFAULT_FLAGS, focused specifically on the whyRecordInEntity* SDK functions

  • SZ_HOW_ENTITY_DEFAULT_FLAGS: Provides recommended information for the SDK how-functions

  • SZ_VIRTUAL_ENTITY_DEFAULT_FLAGS: Provides recommended information for the SDK virtual-entity functions

  • SZ_WITH_INFO: Provides an AFFECTED_ENTITIES list of new, updated, or no-longer-valid entities when using addRecord or deleteRecord

Renamed Flags

  • G2_EXPORT_INCLUDE_RESOLVED: Renamed SZ_EXPORT_INCLUDE_MULTI_RECORD_ENTITIES

  • G2_EXPORT_INCLUDE_SINGLETONS: Renamed SZ_EXPORT_INCLUDE_SINGLE_RECORD_ENTITIES

  • G2_EXPORT_INCLUDE_ALL_RELATIONSHIPS: Renamed SZ_EXPORT_INCLUDE_ALL_HAVING_RELATIONSHIPS

Modified Flags

  • SZ_EXPORT_DEFAULT_FLAGS(G2_EXPORT_DEFAULT_FLAGS): Reduced the information returned for each entity, to match the normal entity defaults

  • SZ_FIND_PATH_DEFAULT_FLAGS(G2_FIND_PATH_DEFAULT_FLAGS): Returns more path-based information, and less entity information

Removed Flags

  • G2_ENTITY_INCLUDE_RECORD_FORMATTED_DATA: This provided the mapped input data in a specialized format. This has been removed, but unmapped data is now available with the SZ_ENTITY_INCLUDE_RECORD_UNMAPPED_DATA flag

  • G2_WHY_ENTITY_DEFAULT_FLAGS: This used to work with the various why* functions. It has been divided into new, more specific flags for the individual functions

SDK JSON Response Documents

The format and contents of the JSON response documents has changed significantly.

Sz_findNetwork Response Document

Sz_findNetwork response document includes all Sz_getEntity* response document changes.

  • Added ENTITY_PATH_LINKS section

  • Added ENTITY_NETWORK_LINKS section

Sz_getEntityByEntityID, Sz_getEntityByRecordID, Sz_getVirtualEntityByRecordID Response Documents

RESOLVED_ENTITY Section

  • Removed LAST_SEEN_DT

  • Added FIRST_SEEN_DT

  • Added RECORD_TYPES section

FEATURES Section

  • Added ELEMENT values

RECORD SUMMARY Section

  • Removed FIRST_SEEN_DT and LAST_SEEN_DT

RECORDS Section

  • Added FIRST_SEEN_DT

  • Added UNMAPPED_DATA section

  • Removed ENTITY_TYPE, ENTITY_KEY, ENTITY_DESC, and MATCH_LEVEL

  • Removed NAME_DATA, ATTRIBUTE_DATA, IDENTIFIER_DATA, ADDRESS_DATA, PHONE_DATA, RELATIONSHIP_DATA, ENTITY_DATA, and OTHER_DATA sections

  • Added MATCH_KEY_DETAILS

  • Added RECORD_TYPES section

  • Removed MATCH_LEVEL

  • Removed FIRST_SEEN_DT and LAST_SEEN_DT

  • Removed FIRST_SEEN_DT and LAST_SEEN_DT from RECORDS subsection

Sz_getRecord Response Document

RECORDS Section

  • Added FIRST_SEEN_DT

  • Added UNMAPPED_DATA section

  • Removed ENTITY_TYPE, ENTITY_KEY

  • Removed NAME_DATA, ATTRIBUTE_DATA, IDENTIFIER_DATA, ADDRESS_DATA, PHONE_DATA, RELATIONSHIP_DATA, ENTITY_DATA, and OTHER_DATA sections

Sz_howEntity Response Document

Sz_howEntity response document includes all Sz_getEntity* response document changes.

  • Added WHY_KEY_DETAILS section (equivalent to MATCH_KEY_DETAILS)

FEATURE_SCORES Section

  • Renamed INBOUND_FEAT to INBOUND_FEAT_DESC, CANDIDATE_FEAT to CANDIDATE_FEAT_DESC

  • Added ADDITIONAL_SCORES subsection that contains the different component scores

Sz_searchByAttributes Response Document

searchByAttributes response document includes all getEntity* response document changes.

RESOLVED_ENTITY Section

  • Added MATCH_KEY_DETAILS to MATCH_INFO subsection

  • Removed MATCH_LEVEL from MATCH_INFO subsection

FEATURE_SCORES Section

  • Renamed INBOUND_FEAT to INBOUND_FEAT_DESC, CANDIDATE_FEAT to CANDIDATE_FEAT_DESC

  • Added ADDITIONAL_SCORES subsection that contains the different component scores