Getting started Community Training Tutorials Documentation APIs, AI & Tools
v02.00
Support Category: Premium
The RosettaNet connector provides B2B functionality using the RosettaNet Information Framework (RNIF) for the information exchange of Rosetta Partner Interface Process (PIP) messages.
The RosettaNet Connector supports RNIF 2.00.01.
The following PIPs are supported:
| PIP | Version | Purpose |
|---|---|---|
0A1 |
v02.00 |
Notification of Failure |
3A4 |
3A4MG1 v02.02, 3A4MG2 v02.02, V11.10 |
Request Purchase Order |
3A6 |
3A6MG1 v02.00, v02.02, v02.03, v11.00 |
Distribute Order Status |
3B2 |
3B2MG1 v01.00, v11.00 |
Notify of Advance Shipment |
3C3 |
3C3MG1 v01.00, v01.11, V11.00 |
Notify of Invoice |
The RosettaNet Connector always uses PIP 0A1 v02.00 for all Failure Notification messages.
| Example files are available for download as described in See Also. |
This document assumes that you’re familiar with RosettaNet, Mule, Anypoint Connectors, Anypoint Studio, Mule flows, and Mule Global Elements.
See the RosettaNet Release Notes for compatibility information.
To use the RosettaNet connector in a production environment, you need a MuleSoft license for Anypoint B2B.
RosettaNet connector 3.x for Mule 4 makes several changes to the configuration and handling over what was implemented by RosettaNet connector 2.x:
Configure external libraries for security modes (non-FIPS, FIPS 140-2, and FIPS 140-3).
Support PIPs that have only XSD definitions (without DTDs).
Compress the Service-Content part of S/MIME messages.
Configure content transfer encoding for S/MIME messages.
Support shared listener mode for receiving messages from multiple partners on a single listener endpoint.
In Studio, create a Mule Project.
Click the Exchange (X) icon in the Studio task bar.
In Exchange, click Login and supply your Anypoint Platform username and password.
In Exchange, select All assets and search for "RosettaNet".
Select RosettaNet, click Add to project.
Follow the prompts to install the connector.
After you install the connector, create HTTP Listener and Request definitions for the Mule and partner endpoints used for your message exchanges.
Click the Global Elements tab at the base of the canvas, and click Create.
Under Connector Configuration, find and select HTTP Listener config, and click OK.
In the configuration definition, enter the Host and Port to be used for receiving action and/or signal messages from the trading partner, then click OK.
From the Global Elements tab, again click Create.
Under Connector Configuration, find and select HTTP Request configuration, and click OK.
In the configuration definition, enter the Host and Port to be used for sending action and/or signal messages to the trading partner, then click OK.
Click the Global Elements tab at the base of the canvas, and click Create.
Under Connector Configuration, find and select RosettaNet Config, and click OK.
Enter the Global HTTP Listener and Global HTTP Request definitions you created. Also enter the endpoint paths, self and partner identification information, PIP role, and PIP definition path.
For the standard PIP definitions, use paths of the form /{pipId}/{version}.xml, such as /PIP3A4/V02_02.xml.
If your PIP definition uses signed messages, configure the Keystore path and Keystore
access password values. If you send signed messages, also provide the Signing key password.
Click OK to save the global connector configurations.
Return to the Message Flow tab in Studio.
Drag RosettaNet components into your flows, selecting the configuration to be used for each component.
The RosettaNet connector provides three components for use in your app flows:
Action Source - Source for processing action messages received from your partner.
Action Sender - Sender for action messages to be transmitted to your partner.
Acknowledge Source - Source for processing the completions (whether successful deliveries, exceptions, or failures) of action messages you’ve sent to your partner.
All configuration properties used by the RosettaNet connector are in the Studio General tab:
| Configuration Property | Description |
|---|---|
Global HTTP Listener |
Name of the HTTP Listener configuration to be used for receiving messages from the partner. |
Service Endpoint Path |
Path relative to the HTTP Listener configuration (allowing the same HTTP Listener to be used with different paths for different partners, if desired). |
Global HTTP Request |
Name of the HTTP Request configuration to be used for sending messages to the partner. |
Request Endpoint Path |
Path relative to the HTTP Request configuration (allowing the same HTTP Request to be used with different paths, if desired). |
Require secure transport |
When HTTPS is active, the system verifies its usage and records the isSecureTransportRequired field in the |
Keystore path |
Absolute file path or classpath relative to the project |
Keystore access password |
Password used to protect the keystore (required when sending or receiving signed messages). |
Signing key password |
Password used to access the private signing key within the keystore (required when sending signed messages). |
Force message signing |
Optional override to force the use of signed messages even when not required by the PIP definition. Leave this value empty to use the PIP definition setting for signing messages, set to |
Signing algorithm |
Algorithm to sign S/MIME messages. Select one:
|
Content transfer encoding |
Encoding format to use when parts are transmitted, one of:
|
Service-Content Compression |
Algorithm to compress the service-content part of an S/MIME message. Select one:
|
Global usage code |
Mode to run the connector, one of:
|
Object store reference |
Optional reference to an object store definition to be used for storing messages awaiting acknowledgment. If not set, the connector always uses the default persistent object store to retain sent messages waiting for acknowledgments or retries. If set, the connector uses the referenced object store configuration instead. |
Mule DUNS identifier |
Dun & Bradstreet Universal Numbering System (DUNS) ID for this organization. |
Mule location identifier |
Location ID of this organization. If specified, this is included in all messages sent and must be present in all messages received. If not specified, any value present in received messages is accepted and ignored. Using the location ID also changes the alias used for your key pair in the keystore. |
Partner DUNS identifier |
Dun & Bradstreet Universal Numbering System (DUNS) ID for your trading partner organization. |
Partner location identifier |
Expected location ID for partner organization. If specified, this is included in all messages sent and must be present in all messages received. If not specified, any value present in received messages is accepted and ignored. Using the location ID also changes the alias used for the partner certificate in the keystore. |
Role in PIP |
Role in Partner Interface Process (PIP) usage, one of:
Both roles are supported with |
PIP definition path |
Absolute file path or classpath relative to the project |
Listener mode |
Configuration mode to use for incoming messages:
In |
Shared mode - Partners |
Configuration for partners when using shared listener mode. |
All values listed in the Studio configuration can be set directly in XML:
| XML value | Studio option |
|---|---|
globalUsageCode |
Global usage code |
keystorePass |
Keystore access password |
keystorePath |
Keystore path |
listenerConfigName |
Global HTTP Listener |
objectStore |
Object store reference |
partnerBusinessIdentifier |
Partner DUNS identifier |
partnerLocationId |
Partner location identifier |
pipFile |
PIP definition path |
pipRole |
Role in PIP |
privatePass |
Signing key password |
requestPath |
Request Endpoint Path |
requesterConfigName |
Global HTTP Request |
selfBusinessIdentifier |
Mule DUNS identifier |
selfLocationId |
Mule location identifier |
servicePath |
Service Endpoint Path |
signingOverride |
Force message signing |
signingAlgorithm |
Signing algorithm |
isSecureTransportRequired |
Require secure transport (HTTPS) |
contentTransferEncoding |
Content transfer encoding |
serviceContentCompression |
Service-Content compression |
listenerMode |
Listener mode |
When using shared listener mode, these additional configuration options are available.
Example XML configuration for shared mode:
<rosetta:config name="Buyer_Hub_Shared_Responder_Config" doc:name="Rosetta config" doc:id="ea591335-89aa-477f-81f8-11afbce399e5" listenerConfigName="Buyer_Listener" servicePath="/rosettanet/hub-receive" signingOverride="NEVER" selfBusinessIdentifier="999999999" selfLocationId="hub" pipRole="RESPONDER" pipFile="/PIP3A4/V02_02.xml" listenerMode="SHARED" keystorePath="crypto/hub.jks" keystorePass="nosecret" privatePass="nosecret">
<rosetta:partners>
<rosetta:partner partnerName="Partner-A" businessIdentifier="111111111" locationId="partnera" requesterConfigName="Buyer_To_PartnerA_Request" requestPath="/rosettanet/partnera" certificateAlias="111111111:partnera"/>
<rosetta:partner partnerName="Partner-B" businessIdentifier="222222222" locationId="partnerb" requesterConfigName="Buyer_To_PartnerB_Request" requestPath="/rosettanet/partnerb" certificateAlias="222222222:partnerb"/>
<rosetta:partner partnerName="Partner-C" businessIdentifier="333333333" locationId="partnerc" requesterConfigName="Buyer_To_PartnerC_Request" requestPath="/rosettanet/partnerc" certificateAlias="333333333:partnerc"/>
</rosetta:partners>
</rosetta:config>
| XML value | Studio option |
|---|---|
partnerName |
Partner name (used for logging and tracing) |
businessIdentifier |
Partner DUNS identifier |
locationId |
Partner location identifier |
certificateAlias |
Alias of the partner certificate in the keystore (if not specified, the alias is constructed from the partner DUNS and location identifiers) |
requesterConfigName |
Global HTTP Request for this partner |
requestPath |
Request Endpoint Path for this partner |
The default object store uses the Mule default persistent object store, which means that unacknowledged sent messages can accumulate and cause retransmissions when you try running again.
Use this configuration to define a transient object store for testing and debugging, and reference the object store by name from your RosettaNet configuration.
<mule xmlns:os="http://www.mulesoft.org/schema/mule/os" ...
http://www.mulesoft.org/schema/mule/os http://www.mulesoft.org/schema/mule/os/current/mule-os.xsd" ...>
...
<os:object-store name="transientStore" persistent="false"/>
...
<rosetta:config name="PO_InitiatorConfig_Buyer" ...
objectStore="transientStore"/>
When using a persistent object store unacknowledged messages are retained across restarts of the Mule app and are automatically retransmitted when the app restarts (assuming the timeout has expired). All messages are deleted from the object store if the number of retransmissions specified in the PIP definition occurs without an acknowledgment, or after three days. You can also force unacknowledged messages to be discarded when the Mule app is started by setting the system property:
com.mulesoft.connectors.rosettanet.extension.internal.delivery.DeliveryManager.deleteStore=true
Customizing a PIP allows two types of changes to the PIP configuration:
Parameters: Change settings within a PIP version’s XML file.
Advanced: Create a custom DTD from which you create an XSD file.
For both paths, put the new or changed files in a directory in your Studio project’s src/main/resources folder.
You can use the supplied PIP configurations as a starting point. These are distributed inside the mule-rosettanet-extension-2.0.0-mule-plugin.jar, which Studio downloads. These configurations are added to your project under the /target/repository/com/mulesoft/connectors/mule-rosettanet-extension directory and can also be found in the standard MuleSoft enterprise Maven repositories (under group ID com.mulesoft.connectors). Each PIP configuration is in a separate directory (such as PIP3A4) inside the jar. You can copy a PIP directory out of this jar and edit the contents to match your specific needs.
Inside the PIP configuration directory you’ll find an XML file giving the parameters for a particular version of the PIP (such as V02_02.xml). This XML file gives all the details of retry counts, times to acknowledge, and signing requirements for the action(s) defined by the PIP. This file also references DTD and/or XSD definitions for the actual action messages (for PIPs that only have DTD, an XSD file is also needed; the XSD is used to provide DataSense information inside Mule).
Copy the base PIP definition directory out of the jar and into your Studio project’s src/main/resources folder, changing the name of the copied directory to indicate your customization (such as PIP3A4-custom). Then make your desired changes and use the modified PIP directory name in your RosettaNet Connector configuration (as the pipFile value).
RosettaNet uses X.509 certificates to authenticate messages. RosettaNet connector currently only supports storing certificates (and the private keys used for signing) in JKS-format keystores. You can use various tools such as Portecle for working with keystores and creating keys and certificates.
Keystore aliases have the form:
{Partner/Self Business Identifier}[:{Partner/Self Location ID}]
The curly braces surround values and the square brackets show the optional part that is used only when the Location ID is defined.
The errors fall into three categories: startup validation failures raised during initialise, operation validation errors raised when an operation is invoked, and partner resolution failures raised when helper methods are called with an unsupported mode or unknown alias.
Thrown when selfBusinessIdentifier is null or blank. This common validation applies to both DEDICATED and SHARED modes.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: 'Mule DUNS identifier' (selfBusinessIdentifier) is required
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateCommonConfig(RosettaNetConfig.java:429)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(RosettaNetConfig.java:411)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown only in DEDICATED mode. The connector needs requesterConfigName to send outbound action and signal messages to the configured partner.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: DEDICATED mode requires 'Global HTTP Request' (requesterConfigName) to be configured
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateDedicatedModeConfig(RosettaNetConfig.java:447)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(RosettaNetConfig.java:414)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown only in DEDICATED mode. The connector requires requestPath to send messages directly to the configured partner endpoint.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: DEDICATED mode requires 'Request Endpoint Path' (requestPath) to be configured
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateDedicatedModeConfig(RosettaNetConfig.java:450)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(RosettaNetConfig.java:414)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown only in DEDICATED mode. The single-partner configuration requires this value to resolve or validate the inbound and outbound partner identity.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: DEDICATED mode requires 'Partner DUNS identifier' (partnerBusinessIdentifier) to be configured
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateDedicatedModeConfig(RosettaNetConfig.java:453)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(RosettaNetConfig.java:414)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown when listenerMode=SHARED but sharedModeConfig.partners is empty. A shared listener needs at least one partner alias to register.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: SHARED mode requires at least one partner to be configured in the partners list
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateSharedModeConfig(RosettaNetConfig.java:485)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(RosettaNetConfig.java:418)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown when two shared partners reuse the same partnerName, case-insensitively. Partner names must be unique for flow routing through attributes.partnerName.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: Duplicate partner name 'Partner-A' in SHARED mode partners list
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateSharedModeConfig(RosettaNetConfig.java:493)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(RosettaNetConfig.java:418)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown when two shared partners resolve to the same routing or certificate alias. This prevents ambiguous inbound partner matching.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: Duplicate partner alias '111111111:a' in SHARED mode partners list. Multiple partners cannot have the same business identifier and location ID combination.
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateSharedModeConfig(RosettaNetConfig.java:503)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(RosettaNetConfig.java:418)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown when the configured keystore can’t be loaded for certificate validation. For self-certificate validation, this fails startup.
java.lang.RuntimeException: Keystore crypto/does-not-exist.jks not found
at com.mulesoft.connectors.rosettanet.extension.internal.rnif.MimeMessageBuilder.<init>(MimeMessageBuilder.java:137)
at com.mulesoft.connectors.rosettanet.extension.internal.rnif.MimeMessageBuilder.<init>(MimeMessageBuilder.java:76)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:402)
Thrown when the expected alias is missing from the keystore. Partner alias failures are logged as warnings in DEDICATED mode and prevent startup in SHARED mode. Self-alias validation errors are propagated.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException:
Certificate alias '<selfDuns>:<selfLocation>' for self (Mule) not found in keystore: <keystorePath>.
Please verify the alias matches an entry in your keystore.
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateCertificateAliasInKeystore(...)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateCommonConfig(...)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateConfiguration(...)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(...)
Thrown when the keystore exists but can’t be read or validated. Common causes include an incorrect password, wrong keystore type, corrupt file, or provider/FIPS mismatch.
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: Error validating certificate alias '999999999:hub' for self (Mule) in keystore crypto-multipartner/hub.jks: keystore password was incorrect
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateCertificateAliasInKeystore(RosettaNetConfig.java:609)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.validateCommonConfig(RosettaNetConfig.java:436)
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:369)
Thrown when privatePass is set but keystorePath or keystorePass is missing:
java.lang.IllegalArgumentException: Incomplete keystore configuration in RosettaNet configuration - null
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:398)
Thrown after validateConfiguration() if listenerConfigName is null:
com.mulesoft.connectors.rosettanet.extension.internal.exception.ConfigurationException: Missing required HTTP listener reference
at com.mulesoft.connectors.rosettanet.extension.internal.config.RosettaNetConfig.initialise(RosettaNetConfig.java:377)
Thrown when the Send action operation uses a configuration with listenerMode=SHARED. Both PIP roles are supported in shared listener mode, but Send action requires a DEDICATED configuration for outbound actions.
com.mulesoft.connectors.rosettanet.extension.internal.exception.WriteException: send-action is not supported for SHARED listener mode. Use a DEDICATED configuration for outbound actions.
at com.mulesoft.connectors.rosettanet.extension.internal.operation.RosettaNetOperations.sendAction(RosettaNetOperations.java:57)