Hi Tim,
The attachment is my item-submission-XMLUI.xml file.
Thanks,
Ying
Quoting Tim Donohue <[EMAIL PROTECTED]>:
Ying,
If you are getting those same messages over and over in the DSpace log,
that would imply you are somehow hitting an "infinite loop". When you
click the "submit" button, you *should* see an item created in *both*
the workspaceitem and item table. But, it should not be making updates
to that same item over and over again.
Can you send me your entire item-submission-XMLUI.xml configuration
file? Hopefully later today, I'm going to see if I can do a few quick
tests to DSpace 1.5alpha, just to be 100% certain that you're not
encountering some sort of bug.
- Tim
Jin, Ying wrote:
Hi Tim,
Thanks for the help.
I had problem to generate the DSpace log. Somehow variable ${log.dir} in
log4j.properties can't be interpreted correctly and I now hard coded the
path.
I got tons of these messages in DSpace log when I clicked the "submit to
this collection" button.
2007-11-20 12:14:49,787 INFO org.dspace.content.Item @
[EMAIL
PROTECTED]:session_id=7996091CCADE661966DC61371FFDACD2:update_item:item_id=11
2007-11-20 12:14:49,790 INFO org.dspace.content.WorkspaceItem @
[EMAIL
PROTECTED]:session_id=7996091CCADE661966DC61371FFDACD2:update_workspace_item:workspace_item
_id=11
2007-11-20 12:14:49,790 INFO org.dspace.content.Item @
[EMAIL
PROTECTED]:session_id=7996091CCADE661966DC61371FFDACD2:update_item:item_id=11
2007-11-20 12:14:49,793 INFO org.dspace.content.WorkspaceItem @
[EMAIL
PROTECTED]:session_id=7996091CCADE661966DC61371FFDACD2:update_workspace_item:workspace_item
_id=11
2007-11-20 12:14:49,825 INFO org.dspace.content.Item @
[EMAIL
PROTECTED]:session_id=7996091CCADE661966DC61371FFDACD2:update_item:item_id=11
2007-11-20 12:14:49,828 INFO org.dspace.content.WorkspaceItem @
[EMAIL
PROTECTED]:session_id=7996091CCADE661966DC61371FFDACD2:update_workspace_item:workspace_item
_id=11
This explains why DSpace hangs there. The item will be created in
workspaceitem table and in item table. Could you help me on how to fix the
problem?
Thanks very much,
Ying
----- Original Message -----
From: "Tim Donohue" <[EMAIL PROTECTED]>
To: "yinjin" <[EMAIL PROTECTED]>
Cc: <[email protected]>
Sent: Monday, November 19, 2007 10:41 AM
Subject: Re: [Dspace-tech] how to create a non-interative submission step in
manakin
Ying,
To be honest, your code & configuration all look correct. I'm not sure
offhand what the problem could be, unless for some reason DSpace or
Manakin isn't able to find the custom class you created.
Are you getting any errors in any of the following logs when you click
on the "submission" button?
DSpace log @ [dspace]/log/dspace.log
Tomcat logs @ [tomcat]/logs/
Manakin logs @ [tomcat]/webapps/dspace-xmlui/WEB-INF/logs/
If Manakin/DSpace is hanging, it's highly likely it's erroring out
somewhere along the way.
- Tim
yinjin wrote:
Hi Tim,
Thanks for the information. I have tried to create a non-interative step
by
following the instructions. It doesn't seem difficult. However, the
DSpace
will hang there whenever I click the "submission" or "submit to this
collection" button.
Here is what I did. Can you point out where I'm doing wrong?
===============================================
public class NonInteractiveStep extends AbstractProcessingStep
{
/** log4j logger */
private static Logger log =
Logger.getLogger(NonInteractiveStep.class);
/**
* Do any processing of the information input by the user, and/or
perform
* step processing (if no user interaction required)
* <P>
* It is this method's job to save any data to the underlying
database,
as
* necessary, and return error messages (if any) which can then be
processed
* by the appropriate user interface (JSP-UI or XML-UI)
* <P>
* NOTE: If this step is a non-interactive step (i.e. requires no
UI),
then
* it should perform *all* of its processing in this method!
*
* @param context
* current DSpace context
* @param request
* current servlet request object
* @param response
* current servlet response object
* @param subInfo
* submission info object
* @return Status or error flag which will be processed by
* doPostProcessing() below! (if STATUS_COMPLETE or 0 is
returned,
* no errors occurred!)
*/
public int doProcessing(Context context, HttpServletRequest request,
HttpServletResponse response, SubmissionInfo subInfo)
throws ServletException, IOException, SQLException,
AuthorizeException
{
boolean multipleTitles = false;
boolean publishedBefore = true;
boolean multipleFiles = false;
// If step is complete, save the changes
subInfo.getSubmissionItem().setMultipleTitles(multipleTitles);
subInfo.getSubmissionItem().setPublishedBefore(publishedBefore);
subInfo.getSubmissionItem().setMultipleFiles(multipleFiles);
// commit all changes to DB
subInfo.getSubmissionItem().update();
context.commit();
return STATUS_COMPLETE; // no errors!
}
/**
* Retrieves the number of pages that this "step" extends over. This
method
* is used to build the progress bar.
* <P>
* This method may just return 1 for most steps (since most steps
consist of
* a single page). But, it should return a number greater than 1 for
any
* "step" which spans across a number of HTML pages. For example, the
* configurable "Describe" step (configured using input-forms.xml)
overrides
* this method to return the number of pages that are defined by its
* configuration file.
* <P>
* Steps which are non-interactive (i.e. they do not display an
interface to
* the user) should return a value of 1, so that they are only
processed
* once!
*
* @param request
* The HTTP Request
* @param subInfo
* The current submission information object
*
* @return the number of pages in this step
*/
public int getNumberOfPages(HttpServletRequest request,
SubmissionInfo subInfo) throws ServletException
{
// always just one page of initial questions
return 1;
}
}
====================================================
I simply modified the InitialQuestionsStep.java
Here is what I have in item-submission-XMLUI.xml file:
=====================================================
<!-- This is a non-interactive step which has no UI -->
<step>
<heading></heading> <!--can specify heading, if you want it to
appear
in Progress Bar-->
<processing-class>org.dspace.submit.step.NonInteractiveStep</processing-class>
<workflow-editable>false</workflow-editable>
</step>
<!--Step 1 will be to gather initial information-->
<!--
<step>
<heading>xmlui.Submission.general.progress.initial-questions</heading>
<processing-class>org.dspace.submit.step.InitialQuestionsStep</processing-class>
<xml-ui-class>org.dspace.app.xmlui.aspect.submission.submit.InitialQuestionsStep</xml-ui-class>
<workflow-editable>true</workflow-editable>
</step>
-->
=====================================================
Thanks,
Ying
----- Original Message -----
From: "Tim Donohue" <[EMAIL PROTECTED]>
To: "yinjin" <[EMAIL PROTECTED]>
Cc: <[email protected]>
Sent: Thursday, November 15, 2007 12:58 PM
Subject: Re: [Dspace-tech] how to create a non-interative submission step
in
manakin
Ying,
Take a look at the docs/submission.html documentation with DSpace
1.5alpha.
Near the end of that documentation, there are tips on "Creating a new
Submission Step". If you only implement the "required" items (#1 & #4
in that list), you will end up with a non-interactive step. If you
wanted to create an interactive step, you would also need to create the
appropriate interface, whether it be JSPs or a Manakin "Transformer".
If this documentation isn't clear, let me know. If necessary, I can try
and clean it up to clarify any questions/misunderstandings.
- Tim
yinjin wrote:
Hi All,
Is there any instructions on how to create a non-interative submission
step
in manakin? I'm working on Dspace 1.5 and want to remove initial
questions
step.
Thanks,
Ying
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
--
========================================
Tim Donohue
Research Programmer, Illinois Digital Environment for
Access to Learning and Scholarship (IDEALS)
135 Grainger Engineering Library
University of Illinois at Urbana-Champaign
email: [EMAIL PROTECTED]
web: http://www.ideals.uiuc.edu
phone: (217) 333-4648
fax: (217) 244-7764
========================================
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
--
========================================
Tim Donohue
Research Programmer, Illinois Digital Environment for
Access to Learning and Scholarship (IDEALS)
135 Grainger Engineering Library
University of Illinois at Urbana-Champaign
email: [EMAIL PROTECTED]
web: http://www.ideals.uiuc.edu
phone: (217) 333-4648
fax: (217) 244-7764
========================================
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
--
========================================
Tim Donohue
Research Programmer, Illinois Digital Environment for
Access to Learning and Scholarship (IDEALS)
135 Grainger Engineering Library
University of Illinois at Urbana-Champaign
email: [EMAIL PROTECTED]
web: http://www.ideals.uiuc.edu
phone: (217) 333-4648
fax: (217) 244-7764
========================================
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE item-submission SYSTEM "item-submission.dtd">
<!-- XML-UI Configurable Submission configuration file -->
<!-- This XML configuration file allows you to configure the ordering -->
<!-- and number of the steps that occur in the Item Submission Process. -->
<item-submission>
<!-- The process-map maps collection handles to a particular Item -->
<!-- Submission Process. This requires that a collection's name be -->
<!-- unique, even within a community. DSpace does however insure that each-->
<!-- collection's handle is unique. Process-map provides the means to -->
<!-- associate a unique collection name with an Item Submission process. -->
<!-- The process-map also provides the special handle "default" (which is -->
<!-- never a collection), here mapped to "traditional". Any collection -->
<!-- which does not appear in this map will be associated with the mapping-->
<!-- for handle "default". -->
<submission-map>
<name-map collection-handle="default" submission-name="traditional" />
</submission-map>
<!-- The 'step-definitions' allows you to define steps which you may wish -->
<!-- to "share" amongst multiple submission-item definitions. In order to-->
<!-- share the same step definition, you can refer to it by its unique id -->
<!-- defined in this section. EVERY 'step' in this section MUST have a -->
<!-- unique identifier in the 'id' attribute! -->
<!-- -->
<!-- Each <step> REQUIRES the following attributes (@) and properties: -->
<!-- @id - The unique identifier for this step -->
<!-- <processing-class> - The class which will process all information for-->
<!-- this step. The class must extend the -->
<!-- 'org.dspace.submit.AbstractProcessingStep' class! -->
<!-- This property should reference the full path of the class-->
<!-- (e.g. org.dspace.submit.step.MyCustomStep) -->
<!-- -->
<!-- The following properties are OPTIONAL for each <step>: -->
<!-- <heading> - References the message text (from the -->
<!-- Messages.xml file) which will be used as this -->
<!-- step's heading in the progress-bar. If unspecified, -->
<!-- the step does not show up in the Progress Bar. -->
<!-- <xml-ui-class> - The class which acts as the XML-UI Transformer -->
<!-- for this step. This class must extend the -->
<!-- 'org.dspace.app.xmlui.submission.AbstractSubmissionStep'-->
<!-- class. This class must generate the body of a valid -->
<!-- XML DRI document which can be transformed by Manakin. -->
<!-- <workflow-editable> - whether or not this step will appear during the-->
<!-- "Edit Metadata" workflow approval process. This field-->
<!-- defaults to TRUE (which means it can be edited during -->
<!-- the "Edit Metadata" workflow stage) -->
<!-- -->
<!-- -->
<step-definitions>
<!-- The "collection" step is a "special step" which is *REQUIRED* to be-->
<!-- in this section! In DSpace, all submitted items must be -->
<!-- immediately assigned to a collection. This step ensures that a -->
<!-- collection is always selected. If a user is already submitting -->
<!-- from within a Collection (by clicking the "Submit to This -->
<!-- Collection" button) then this step will be automatically skipped. -->
<!-- In all other cases, this step ensures that the user *first* selects-->
<!-- a collection! -->
<!-- Since this is a "special step", it is *automatically* added at the -->
<!-- beginning of each 'submission-process' (therefore it should not be -->
<!-- referenced by any of the below 'submission-process' tags). Also as-->
<!-- a special step, it is currently NEVER editable in a workflow. -->
<step id="collection">
<heading></heading> <!--can specify heading, if you want it to appear in Progress Bar-->
<processing-class>org.dspace.submit.step.SelectCollectionStep</processing-class>
<xml-ui-class>org.dspace.app.xmlui.aspect.submission.submit.SelectCollectionStep</xml-ui-class>
<workflow-editable>false</workflow-editable>
</step>
<!-- The "complete" step is a "special step" which is *REQUIRED* to be -->
<!-- in this section! In DSpace, when a submission is completed, -->
<!-- a workflow is automatically kicked off (if one exists) -->
<!-- This "complete" step performs all backend processing that occurs -->
<!-- immediately upon completing the submission. -->
<!-- Since this is a "special step", it is *automatically* added at the -->
<!-- end of each 'submission-process' (therefore it should not be -->
<!-- referenced by any of the below 'submission-process' tags). Also as-->
<!-- a special step, it is currently NEVER editable in a workflow. -->
<step id="complete">
<heading>xmlui.Submission.general.progress.complete</heading>
<processing-class>org.dspace.submit.step.CompleteStep</processing-class>
<workflow-editable>false</workflow-editable>
</step>
</step-definitions>
<!-- The submission-definitions map lays out the detailed definition of -->
<!-- all the Item Submission Processes (and the ordering of their steps). -->
<!-- Each separate "submission-process" has a unique name as an attribute,-->
<!-- which matches one of the names in the process-map. One named -->
<!-- "submit-process" has the name "traditional"; as this name suggests, -->
<!-- it is the default item submission process, which gets used when -->
<!-- the specified collection has no correspondingly named submit-process.-->
<!-- -->
<!-- Each submit-process contains an ordered set of steps; each step -->
<!-- defines one "step" occurring during the process of submitting an -->
<!-- item. A step can either be reference by 'id' (in which case it must -->
<!-- be defined in <step-definitions> above), or defined completely here. -->
<!-- -->
<!-- If the step is not referred to by 'id', then the <step> REQUIRES the -->
<!-- following properties are defined: -->
<!-- <processing-class> - The class which will process all information for-->
<!-- this step. The class must extend the -->
<!-- 'org.dspace.submit.AbstractProcessingStep' class! -->
<!-- This property should reference the full path of the class-->
<!-- (e.g. org.dspace.submit.step.MyCustomStep) -->
<!-- -->
<!-- The following properties are OPTIONAL for each <step>: -->
<!-- <heading> - References the message text (from the -->
<!-- Messages.xml file) which will be used as this -->
<!-- step's heading in the progress-bar. If unspecified, -->
<!-- the Step does not show up in the Progress Bar. -->
<!-- <xml-ui-class> - The class which acts as the XML-UI Transformer -->
<!-- for this step. This class must extend the -->
<!-- 'org.dspace.app.xmlui.submission.AbstractSubmissionStep'-->
<!-- class. This class must generate the body of a valid -->
<!-- XML DRI document which can be transformed by Manakin. -->
<!-- <workflow-editable> - whether or not this step will appear during the-->
<!-- "Edit Metadata" workflow approval process. This field-->
<!-- defaults to TRUE (which means it can be edited during -->
<!-- the "Edit Metadata" workflow stage). Set to either -->
<!-- "true" or "false". -->
<!-- -->
<submission-definitions>
<!--This "traditional" process defines the DEFAULT item submission process-->
<submission-process name="traditional">
<!-- This is a non-interactive step which has no UI -->
<step>
<heading></heading>
<processing-class>org.dspace.submit.step.NonInteractiveStep</processing-class>
<workflow-editable>false</workflow-editable>
</step>
<!--Step 1 will be to gather initial information-->
<!--
<step>
<heading>xmlui.Submission.general.progress.initial-questions</heading>
<processing-class>org.dspace.submit.step.InitialQuestionsStep</processing-class>
<xml-ui-class>org.dspace.app.xmlui.aspect.submission.submit.InitialQuestionsStep</xml-ui-class>
<workflow-editable>true</workflow-editable>
</step>
-->
<!--Step 2 will be to Describe the item.-->
<step>
<heading>xmlui.Submission.general.progress.describe</heading>
<processing-class>org.dspace.submit.step.DescribeStep</processing-class>
<xml-ui-class>org.dspace.app.xmlui.aspect.submission.submit.DescribeStep</xml-ui-class>
<workflow-editable>true</workflow-editable>
</step>
<!--Step 3 will be to Upload the item-->
<step>
<heading>xmlui.Submission.general.progress.upload</heading>
<processing-class>org.dspace.submit.step.UploadStep</processing-class>
<xml-ui-class>org.dspace.app.xmlui.aspect.submission.submit.UploadStep</xml-ui-class>
<workflow-editable>true</workflow-editable>
</step>
<!--Step 4 will be to Verify everything -->
<step>
<heading>xmlui.Submission.general.progress.review</heading>
<processing-class>org.dspace.submit.step.VerifyStep</processing-class>
<xml-ui-class>org.dspace.app.xmlui.aspect.submission.submit.ReviewStep</xml-ui-class>
<workflow-editable>true</workflow-editable>
</step>
<!--Step 5 will be to Sign off on the License-->
<step>
<heading>xmlui.Submission.general.progress.license</heading>
<processing-class>org.dspace.submit.step.LicenseStep</processing-class>
<xml-ui-class>org.dspace.app.xmlui.aspect.submission.submit.LicenseStep</xml-ui-class>
<workflow-editable>false</workflow-editable>
</step>
</submission-process>
</submission-definitions>
</item-submission>
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech