When I use it in this way, I receive an error (I can post the full stack-trace if needed):
[Fatal Error] :3:11: The end-tag for element type "Response" must end with a '>' delimiter.
…
Caused by: com.inductiveautomation.ignition.client.gateway_interface.GatewayException: Unable to read response from Gateway
And my RPCHandler in the Gateway Scope is defined like this:
public class RPCHandler implements ModuleRPC {
private GatewayContext context;
public RPCHandler(GatewayContext context){
this.context = context;
}
public String helloWorld(){
return "Hello World!";
}
}
And my ModuleRPC in the common package is like this:
public interface ModuleRPC {
String helloWorld();
}
And lastly the Gateway Hook:
public Object getRPCHandler(ClientReqSession session, Long projectId) {
return new RPCHandler(context);
}
Yes, it shows up in the logs. I’ve attached the relevant part of the log because it’s quite long and it’s probably easier to read in a text editor. missingdelimiter.txt (9.34 KB)
<!-- Add the dependencies for each scope -->
<depends scope="D">fpmi</depends>
<!-- Load in our jars for each scope -->
<jar scope="D">alarmbenchmark-designer.jar.pack.gz</jar>
<jar scope="CD">alarmbenchmark-KasaUtils.jar.pack.gz</jar>
<jar scope="CD">alarmbenchmark-client.jar.pack.gz</jar>
<jar scope="G">alarmbenchmark-gateway.jar</jar>
<!-- Tell the Gateway and/or Designer where to find the hooks -->
<hook scope="D">com.alarmbenchmark.AlarmBenchmarkDesignerHook</hook>
<hook scope="G">com.alarmbenchmark.gateway.GatewayHook</hook>
[/code]
I see that the jar scope on KasaUtils is “CD” and I tried to change this to “CDG” however it doesn’t seem to have any effect and I still get the same error.
It doesn’t look like you have a common project, which would be a project whose jar is scoped both CD and G and would be the one that contains the RPC interface.
Thanks, you are correct. I used the skeleton project creator to create a new workspace with a common project inside of it and then I compared the ant build files and module.xml and made changes to my existing workspace to re-purpose KasaUtils as the common project.