xwork-plugin doesn't find package

While trying to develop a PLugin with velocity input and output my the Plugin always generates this error:

2012-09-07 12:38:04,301 ERROR [pool-8-thread-3] [confluence.plugin.descriptor.XWorkModuleDescriptor] getPackages Could not add package: {PackageConfig Name:examples namespace: abstract:false parents:[{PackageConfig Name:default namespace: abstract:false parents:[]}]} because: com.opensymphony.xwork.config.ConfigurationException: Action class [com.atlassian.example.ExampleAction] not found, skipping action [hello]
    with nested exception 
java.lang.ClassNotFoundException: com.atlassian.example.ExampleAction
 -- url: /IDSInsight/rest/plugins/1.0/ | userName: confluence | referer: https://smucx076.muc.allianz:4443/IDSInsight/plugins/servlet/upm
com.opensymphony.xwork.config.ConfigurationException: Action class [com.atlassian.example.ExampleAction] not found, skipping action [hello]
    with nested exception

Whats the reason for this?

2 answers

This widget could not be displayed.
David Simpson Community Champion Sep 06, 2012

Difficult to say without you sharing code.

Make sure that you use atlas-create-jira-plugin-module to generate the stubs for your modules -- it reduces the number of typos that you'll produce.

I'm developing for confluence, but that shouldn't be the Problem, I think...

here's my atalssian-plugin.xml

<atlassian-plugin key="confluence-peoplesearch-test"
                  name="Confluence Peoplesearch Test" plugins-version="2">
    <plugin-info>
        <description>A PLugin for testing Peolplesearch with Velocity Input and Output</description>
        <version>1.0</version>
        <vendor name="Atlassian" url="http://www.atlassian.com" />
    </plugin-info>
 
    <!-- Registers the macro in a plugin module. -->
<xwork name="My Example Action" key="example-action">
        <description>Shows a simple "Hello, World!" Action</description>
        <package name="examples" extends="default">
            <default-interceptor-ref name="validatingStack" />

            <action name="hello" class="com.atlassian.example.ExampleAction">
                <result name="success" type="velocity">/templates/livesearchaction.vm</result>
            </action>
        </package>
    </xwork>
</atlassian-plugin>

It says, that it can't find com.atlassian.example.ExampleAction...

But why?

This widget could not be displayed.

It gives me a UnknownHostException when I try to run the command atlas-create-confluence-plugin-module! This is independent from the module-type I choose..

Here's the error:

[INFO] Sending event to Google Analytics: AMPS:confluence - Create Plugin Module
 - confluence:Web Section
Enter Plugin Module Name [My Web Section]: 31 [AnalyticsThread-1] ERROR com.dmur
ph.tracking.JGoogleAnalyticsTracker - Error making tracking request
java.net.UnknownHostException: www.google-analytics.com
        at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177)
        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
        at java.net.Socket.connect(Socket.java:525)
        at java.net.Socket.connect(Socket.java:475)
        at sun.net.NetworkClient.doConnect(NetworkClient.java:163)
        at sun.net.www.http.HttpClient.openServer(HttpClient.java:394)
        at sun.net.www.http.HttpClient.openServer(HttpClient.java:529)
        at sun.net.www.http.HttpClient.<init>(HttpClient.java:233)
        at sun.net.www.http.HttpClient.New(HttpClient.java:306)
        at sun.net.www.http.HttpClient.New(HttpClient.java:323)
        at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLC
onnection.java:860)
        at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConne
ction.java:839)
        at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection
.java:726)
        at com.dmurph.tracking.JGoogleAnalyticsTracker.dispatchRequest(JGoogleAn
alyticsTracker.java:463)
        at com.dmurph.tracking.JGoogleAnalyticsTracker.access$100(JGoogleAnalyti
csTracker.java:76)
        at com.dmurph.tracking.JGoogleAnalyticsTracker$1.run(JGoogleAnalyticsTra
cker.java:431)

btw. I can't choose webWork or XWork...

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Thursday in United States

Local Atlassian Research Workshop opportunity on Sep. 28th

We're looking for participants for another workshop at Atlassian! We need Jira admins who have interesting custom workflows, issue views, or boards. Think you have a story to sh...

78 views 0 0
View post

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