Skip to content

Commit

Permalink
Merge pull request #32 from lahnaoja/namespace
Browse files Browse the repository at this point in the history
Fix namespace in soap headers of responses
  • Loading branch information
TVolden authored Feb 21, 2018
2 parents 4363bd8 + 27b9d6d commit f8df205
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,9 @@ private Object createMessage(String uniqueId, String action, Document payload, b

createMessageHeader(uniqueId, action, isResponse, message);

if (isResponse)
payload = setNamespace(payload, hostInfo.isClient() ? SOAPHostInfo.NAMESPACE_CENTRALSYSTEM: SOAPHostInfo.NAMESPACE_CHARGEBOX);
if (isResponse) {
payload = setNamespace(payload, hostInfo.isClient() ? SOAPHostInfo.NAMESPACE_CHARGEBOX : SOAPHostInfo.NAMESPACE_CENTRALSYSTEM);
}

message.getSOAPBody().addDocument(payload);
} catch (Exception e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ of this software and associated documentation files (the "Software"), to deal

public class WebServiceListener implements Listener {
private static final Logger logger = LogManager.getLogger(WebServiceListener.class);
private static final String WSDL_CENTRAL_SYSTEM = "eu/chargetime/ocpp/OCPP_CentralSystemService_1.6.wsdl";
private static final String NAMESPACE = "urn://Ocpp/Cp/2015/10";
private static final String WSDL_CENTRAL_SYSTEM = "eu/chargetime/ocpp/OCPP_CentralSystemService_1.6.wsdl";
private final IServerSessionFactory sessionFactory;

private ListenerEvents events;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ of this software and associated documentation files (the "Software"), to deal
*/

public class SOAPHostInfo {
public static final String NAMESPACE_CHARGEBOX = "urn://Ocpp/Cs/2015/10";
public static final String NAMESPACE_CENTRALSYSTEM = "urn://Ocpp/Cp/2015/10";
public static final String NAMESPACE_CHARGEBOX = "urn://Ocpp/Cp/2015/10/";
public static final String NAMESPACE_CENTRALSYSTEM = "urn://Ocpp/Cs/2015/10/";

private String chargeBoxIdentity;
private String fromUrl;
Expand Down

0 comments on commit f8df205

Please sign in to comment.