Paul Wilcox 4 Posted March 8, 2021 Share Posted March 8, 2021 // In the following java activity, the stream is null. If I run the equivalent code in a regular java project, no problem. package BusinessProcesses.Get_Secret; import java.util.*; import java.io.*; import java.io.InputStream; import com.amazonaws.services.secretsmanager.AWSSecretsManager; import com.amazonaws.services.secretsmanager.AWSSecretsManagerClientBuilder; import com.amazonaws.partitions.PartitionsLoader; public class Get_SecretCall_GetSecret{ /****** START SET/GET METHOD, DO NOT MODIFY *****/ /****** END SET/GET METHOD, DO NOT MODIFY *****/ public Get_SecretCall_GetSecret() { } public void invoke() throws Exception { /* Available Variables: DO NOT MODIFY * Available Variables: DO NOT MODIFY *****/ InputStream stream = PartitionsLoader.class.getResourceAsStream("com/amazonaws/partitions/endpoints.json"); if (stream == null) throw new NullPointerException("stream"); } } Link to comment Share on other sites More sharing options...
Paul Wilcox 4 Posted March 10, 2021 Author Share Posted March 10, 2021 Turns out this was a problem with designer (5.11) and the way it doesn't do a good job with project state ... when loading/changing the alias file, there were mulitple references to the jars, sometimes with .jar1 extensions, etc. Hard to say exactly what state it was in when I was having thia problem, but by completely removing the alias's, closing the project and restarting designer, realoading the alias's I got this to work. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now