Open bzuidgeest opened 2 years ago
I got the example from https://ballardsoftware.com/getting-started-with-the-salesforce-streaming-api-in-net-core/ working combined with https://www.forcetalks.com/blog/how-to-integrate-salesforce-streaming-api-with-net-core-application/
Both use the CometD library from kdcllc that is libray (CometD.NetCore.Salesforce) is based on. So I am missing somthing in this library required to make it connect. Where is the "Connect" function?
I'm trying to use the code in this repo to follow this tutorial: https://developer.salesforce.com/docs/atlas.en-us.api_streaming.meta/api_streaming/code_sample_java_create_pushtopic.htm
But I am at a loss on how to exactly use the library. I have the streamingclient and I do a subscribetopic. But nothing happens. The state on the client seems to be disconnected. I expected to see some events happening. But I cannot find anything to make it connect. There seems to be a disconnect function but not a connect function.
Any help appreciated.
cobbled together stuff ` var host = new HostBuilder() .ConfigureHostConfiguration(configHost => { configHost.SetBasePath(Directory.GetCurrentDirectory()); configHost.AddJsonFile("hostsettings.json", optional: true); configHost.AddEnvironmentVariables(prefix: "TESTAPP_"); configHost.AddCommandLine(args); }) .ConfigureAppConfiguration((hostContext, configBuilder) => { configBuilder.AddJsonFile("appsettings.json", optional: true, reloadOnChange: true); configBuilder.AddJsonFile( $"appsettings.{hostContext.HostingEnvironment.EnvironmentName}.json", optional: true);
`