Script Runner Http Post to splunk

Hi All,

I am following this article on version 5.8.10 of Confluence and also version 6.2 but am not able to get it working. I keep getting errors.

http://www.mos-eisley.dk/display/ATLASSIAN/Logging+PageEvents+to+Splunk

Current errors are below:

 

post2splunk.groovy

  • Script38.groovy:44 [Static type checking] - Cannot find matching method java.net.URLConnection#setRequestMethod(java.lang.String). Please check if the declared type is right and if the method exists. @ line 44, column 1.
  • Script38.groovy:71 [Static type checking] - Cannot find matching method java.net.URLConnection#getResponseCode(). Please check if the declared type is right and if the method exists. @ line 71, column 15.
  • Script38.groovy:72 [Static type checking] - Cannot find matching method java.net.URLConnection#getResponseMessage(). Please check if the declared type is right and if the method exists. @ line 72, column 16.

1 answer

This widget could not be displayed.

Hi,

The post should happend anyway (?) Its my script and all places in JIRA i get the:

  • Script1231.groovy:85 [Static type checking] - Cannot find matching method java.net.URLConnection#setRequestMethod(java.lang.String). Please check if the declared type is right and if the method exists. @ line 85, column 7.
  • Script1231.groovy:97 [Static type checking] - Cannot find matching method java.net.URLConnection#getResponseCode(). Please check if the declared type is right and if the method exists. @ line 97, column 126.
  • Script1231.groovy:97 [Static type checking] - Cannot find matching method java.net.URLConnection#getResponseMessage(). Please check if the declared type is right and if the method exists. @ line 97, column 179.
  • Script1231.groovy:101 [Static type checking] - Cannot find matching method java.net.URLConnection#getResponseCode(). Please check if the declared type is right and if the method exists. @ line 101, column 15.
  • Script1231.groovy:106 [Static type checking] - Cannot find matching method java.net.URLConnection#getResponseCode(). Please check if the declared type is right and if the method exists. @ line 106, column 128.
  • Script1231.groovy:106 [Static type checking] - Cannot find matching method java.net.URLConnection#getResponseMessage(). Please check if the declared type is right and if the method exists. @ line 106, column 181.
  • Script1231.groovy:110

But thing do work fine anyway

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Why start from scratch? Introducing four new templates for Confluence Cloud

Hi my Community friends!  For those who don't know me, I'm a product marketer on the Confluence Cloud team - nice to meet you! For those of you who do, you know that I've been all up in your Co...

361 views 2 5
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you