corda-finance cordapp from O/S v3.1 not compatible with enterprise due to use of internals

Description

Steps to reproduce:

Following error is generated:

Looks like it was probably caused by this commit:

Activity

Show:
Jose Coll
June 12, 2018, 1:02 PM
Edited

So further investigation confirms that some internal code was refactored between Corda 3.1 and Corda Enterprise 3.0 RCs, and hence we see the above errors. Specifically there is a new `PathUtils.kt` class in the core internal package which includes functions previously located in `InternalUtils.kt`.
The bottom line is that our finance CorDapp should not be using internal methods as we make no guarantee these will not change between releases (as has happened here).

Discussion with on Slack:

Tommy Lillehagen
June 29, 2018, 6:59 AM

I'm raising a PR to fix this on ENT this morning (for GA); this will allow OS 3.0 and 3.1 to use the ENT 3.0 GA version of the app. After GA we should make further endeavours to decouple Finance from Core and other modules, especially the internal APIs.

Chris Rankin
June 29, 2018, 8:37 AM

Interestingly, this particular class contains this comment:

It then proceeds to pillage the location of node.conf out of the ServiceHub using Java reflection so that it can read its custom.issuableCurrencies field.

If we had a better solution to this then the only internal APIs left in finance would be:

  • @net.corda.core.internal.VisibleForTesting

  • net.corda.core.internal.uncheckedCast

  • net.corda.core.internal.Emoji

Tommy Lillehagen
June 29, 2018, 8:46 AM

Yep, I saw that one

Tommy Lillehagen
July 2, 2018, 4:24 PM

Further PRs against OS v3.2 and v3.3 release branches, plus OS master

Assignee

Tommy Lillehagen

Reporter

Anthony Keenan

Labels

None

Sprint

None

Epic Link

None

Priority

Medium

Severity

Medium

CVSS Score

None

CVSS Vector

None

Due Date

None

Engineering Teams

None

Fix versions

Affects versions

None

Ported to...

None

Story Points / Dev Days

None
Configure