Error number 4001 in 4: Error while parsing velocity page Wrapped Exception: Failed to evaluate content with id [] com.xpn.xwiki.XWikiException: Error number 4001 in 4: Error while parsing velocity page Wrapped Exception: Failed to evaluate content with id [] at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:122) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1911) at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1856) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1833) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:860) at sun.reflect.GeneratedMethodAccessor134.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:389) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:378) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:270) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:252) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:332) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:212) at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:247) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:175) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:196) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:161) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:116) at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1895) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1833) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:860) at sun.reflect.GeneratedMethodAccessor134.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:389) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:378) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:270) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:252) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:332) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:212) at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:247) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:175) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:106) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:196) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:161) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:116) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1911) at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1856) at com.xpn.xwiki.web.Utils.parseTemplate(Utils.java:154) at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:226) at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:117) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414) at javax.servlet.http.HttpServlet.service(HttpServlet.java:617) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.xpn.xwiki.web.ActionFilter.doFilter(ActionFilter.java:129) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.xpn.xwiki.wysiwyg.server.filter.ConversionFilter.doFilter(ConversionFilter.java:152) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.xpn.xwiki.plugin.webdav.XWikiDavFilter.doFilter(XWikiDavFilter.java:68) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.xwiki.container.servlet.filters.internal.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:218) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.xwiki.container.servlet.filters.internal.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:112) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:776) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:705) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:898) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:595) Wrapped Exception: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'includeForm' in class com.xpn.xwiki.api.XWiki threw exception com.xpn.xwiki.XWikiException: Error number 3205 in 3: Version 54.1 does not exist while reading document XWiki.MenuBar at <unknown template>[line 21, column 8] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:284) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:252) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:332) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:196) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:161) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:116) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1911) at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1856) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1833) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:860) at sun.reflect.GeneratedMethodAccessor134.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:389) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:378) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:270) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:252) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:332) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:212) at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:247) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:175) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:196) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:161) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:116) at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1895) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1833) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:860) at sun.reflect.GeneratedMethodAccessor134.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:389) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:378) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:270) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:252) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:332) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:212) at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:247) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:175) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:106) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:196) at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:161) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:116) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1911) at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1856) at com.xpn.xwiki.web.Utils.parseTemplate(Utils.java:154) at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:226) at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:117) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414) at javax.servlet.http.HttpServlet.service(HttpServlet.java:617) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.xpn.xwiki.web.ActionFilter.doFilter(ActionFilter.java:129) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.xpn.xwiki.wysiwyg.server.filter.ConversionFilter.doFilter(ConversionFilter.java:152) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.xpn.xwiki.plugin.webdav.XWikiDavFilter.doFilter(XWikiDavFilter.java:68) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.xwiki.container.servlet.filters.internal.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:218) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.xwiki.container.servlet.filters.internal.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:112) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:776) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:705) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:898) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:595) Caused by: com.xpn.xwiki.XWikiException: Error number 3205 in 3: Version 54.1 does not exist while reading document XWiki.MenuBar at com.xpn.xwiki.store.XWikiHibernateVersioningStore.loadXWikiDoc(XWikiHibernateVersioningStore.java:220) at com.xpn.xwiki.XWiki.getDocument(XWiki.java:1524) at com.xpn.xwiki.doc.XWikiDocument.getTranslatedContent(XWikiDocument.java:5221) at com.xpn.xwiki.doc.XWikiDocument.getTranslatedContent(XWikiDocument.java:5210) at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:794) at com.xpn.xwiki.XWiki.getRenderedContent(XWiki.java:4324) at com.xpn.xwiki.XWiki.include(XWiki.java:4239) at com.xpn.xwiki.api.XWiki.includeForm(XWiki.java:1609) at sun.reflect.GeneratedMethodAccessor211.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:389) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:378) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:270) ... 89 more
Software developed by CompatibleOne is gradually made available on the OW2 Gitorious repository.
The lattest version of CompatibleOne can be found here.
| CORDS : CompatibleOne Resource Description Schema |
| |||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Introduction | ||||||||||||||||||||||||||||||||||||||||||||||
This document describes CORDS the CompatibleOne Request Description Schema, an application of XML. The schema describing the namespace of CORDS can be found at http://www.compatibleone.fr/schemes/cords.xsd">http://www.compatibleone.fr/schemes/cords.xsd and should be used to validate documents prior to their submission for processing.
| ||||||||||||||||||||||||||||||||||||||||||||||
| Overview of CORDS | ||||||||||||||||||||||||||||||||||||||||||||||
This table gives a synthetic view of the relationships between the different OCCI categories involved.
| ||||||||||||||||||||||||||||||||||||||||||||||
| CORDS-PARSER : CompatibleOne CORDS Parser |
| |
|---|---|---|
| Introduction | ||
This document describes the public functional interface and operations of the CompatibleOne CORDS Request Parser. This tool performs the conversion and resolution of CompatibleOne Provisioning Requests. Requests are described using CORDS ( CompatibleOne Resource Description Schema ). This is an application of XML and the namespace is described by the schema that can be found at http://www.compatibleone.fr/schemes/cords.xsd">http://www.compatibleone.fr/schemes/cords.xsd and should be used to validate documents prior to their submission for processing.
| ||
| Operation | ||
|
The Cords Manifest to Plan parsing algorithm is the primary operational work horse of ACCORDS and processing will involve a three phase operation.
During the parsing operation any error conditions encountered will be reported by appending an error element as first child element of the offending element.
| ||
| Example Trace of Cords Parsing Operation | ||
| ||
| Example of POC XWIKI XML Plan | ||
| ||
|
http://creativecommons.org/licenses/by-nc-nd/3.0/">
Ce(tte) http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">oeuvre de http://creativecommons.org/ns#" property="cc:attributionName">Iain James Marshall est mise à disposition selon les termes de la http://creativecommons.org/licenses/by-nc-nd/3.0/"> licence Creative Commons Paternité - Pas dUtilisation Commerciale - Pas de Modification 3.0 non transcrit. | ||
| CORDS-BROKER : CompatibleOne CORDS Broker |
| |
|---|---|---|
| Introduction | ||
|
This document describes the operation of the cords broker which produces an
operational provisioning instance, refered to as a
This provisioning The CORDS Broker must create a graph of CORDS OCCI instances and identifiers for the control and management of the actual resources required for the delivery of the provisioned system configuration. The algorithm of the broker is as follows:
| ||
| Example of Cords Instancing Operation Output | ||
| ||
| Example of Cords Broker Instance Report | ||
This file is produced by the
| ||
|
http://creativecommons.org/licenses/by-nc-nd/3.0/">
Ce(tte) http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">oeuvre de http://creativecommons.org/ns#" property="cc:attributionName">Iain James Marshall est mise à disposition selon les termes de la http://creativecommons.org/licenses/by-nc-nd/3.0/">licence Creative Commons Paternité - Pas dUtilisation Commerciale - Pas de Modification 3.0 non transcrit. | ||
| CO-REST : Compatible One REST Server Library |
| |
|---|---|---|
| Introduction | ||
This document describes the public functional interface of
the Compatible One REST Server Library which provides a basic building block for the construction of
Compatible One Service components. This is a standard The library has been used in the construction of the Compatible One Service Publication Platform and will also be employed in both the construction of the Compatible One Resource Description Schema Parsing Service and of the Compatible One OCCI Interfaces to the open source infrastructure providers OpenStack and OpenNebula. The library will be extended in the near future to provide HTTP/REST Client functionalities to complement the currently available functions required for the construction of the REST Servers.
| ||
| rest_server | ||
| returns | int
| |
| parameter | char * nptr | the name string to be used to identify the REST server |
| parameter | int port | port number on which the REST server will listen |
| parameter | int tls | require transport layer security for this connection |
| parameter | int max | maximum number of clients to alllow waiting for connect |
| parameter | struct rest_interface * iptr | table of REST interface methods |
This function will build and operate a fully functional HTTP/REST Server using TCP. The provided parameters will describe the server in terms of its listening port and its host identity. The final parameter will provide the collection of user function pointers that are to be invoked for the different REST/CRUD operational verbs ( GET, POST, PUT, DELETE, HEAD). These function relays allow the actual behaviour of the server to be defined outside of the library and will be invoked by passing the client connection structure and the request description structure for processing. The function relay is to return a valid response structure pointer describing the details of the response to be returned to the client request.
The Only the collection of methods required for a particular application use are required to be defined in the function interface table prior to the invocation of this function, need to be specified in the NULL values will be directed to the standard unsupported method response function of the REST library. The The structures
The
The
The functions referenced by the function pointers in the method interface description table The following code extract provides an example of the use of this function
| ||
| rest_response_body | ||
| returns | void | |
| parameter | struct rest_response * aptr | a REST response structure |
| parameter | char * body | the body parameter, either a filename or a string |
| parameter | int type | indicates the type of the body parameter 0:file, 1:string |
This function is to be called to establish the response body to be returned. The response body may be specified as a filename or as a string of response body text. The third parameter type will differentiate between the two body types. When type is zero the body type is a filename that will be read and returned as the body content. When type is set to one then the body content will be contained in the string value of the second parameter.
| ||
| rest_response_status | ||
| returns | struct rest_response *
| |
| parameter | struct rest_response* aptr | a REST response structure |
| parameter | int status | the HTTP status code to establish in the response |
| parameter | char * message | the human readable message describing the status code |
This function simply allows the status code and status message fields of the REST response structure to be set with the provided values.
| ||
| rest_response_header | ||
| returns | struct rest_header *
| |
| parameter | struct rest_response * aptr | a REST response structure |
| parameter | char * nptr | an HTTP header field name string |
| parameter | char * vptr | an HTTP header field value string |
This function adds an HTTP header field to the indicated response structure using the provided field name and field value strings. The header structure will be added to the end of the current list of headers and will be returned to the caller.
The parent field will only be set for headers which belong to a REST request structure.
| ||
| rest_allocate_response | ||
| returns | struct rest_response *
| |
| parameter | struct rest_client * cptr | a REST client connection structure |
This function simply allocates a REST response structure for the indicated client connection.
| ||
| rest_drop_client | ||
| returns | struct rest_client *
| |
| parameter | struct rest_client * cptr | a REST client connection structure |
This function simply releases a client structure and disconnects its eventual open connection.
| ||
| rest_html_response | ||
| returns | struct rest_response *
| |
| parameter | struct rest_response * aptr | a REST response structure |
| parameter | int status | the HTTP status code to establish in the response |
| parameter | char * message | the human readable message describing the status code |
This function establishs the response status and message fields and sets the response body to contain a string of HTML data describing the tatus message.
| ||
| rest_response_failure | ||
| returns | struct rest_response *
| |
| parameter | struct rest_client * cptr | a REST client connection structure |
| parameter | int status | the HTTP status code to establish in the response |
| parameter | char * message | the human readable message describing the status code |
This function allocates a response structure and prepares the status and message fields with the provided error code and message.
| ||
| rest_resolve_header | ||
| returns | struct rest_header *
| |
| parameter | struct rest_header * hptr | the list of HTTP header fields to scan |
| parameter | char * name | an HTTP header field name string to be located in the list |
This function will search the provided list of HTTP header fields to locate the header field name provided as the second parameter. The HTTP header structure will be returned if the search is succesful otherwise a NULL pointer will be returned.
| ||
| rest_add_extension | ||
| returns | struct rest_extension *
| |
| parameter | struct rest_server * sptr
| the REST server structure to which the extension is to be added. |
This function allows network protocol extensions to be added to the REST server in order that their socket activity be detected during the REST server operational loop and dispatched for processing by the appropriate extension handling interface.
| ||
| rest_drop_extension | ||
| returns | struct rest_extension *
| |
| parameter | struct rest_server * sptr
| the REST server structure to which the extension is to be added. |
| parameter | struct rest_extension * xptr
| the REST server extension structure to be removed. |
This function allows a network protocol extension handler to be removed from the REST server in order that socket activity no longer be detected during the REST server operational loop.
| ||
|
http://creativecommons.org/licenses/by-nc-nd/3.0/">
Ce(tte) http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">oeuvre de http://creativecommons.org/ns#" property="cc:attributionName">Iain James Marshall est mise à disposition selon les termes de la http://creativecommons.org/licenses/by-nc-nd/3.0/">licence Creative Commons Paternité - Pas dUtilisation Commerciale - Pas de Modification 3.0 non transcrit. | ||
| CO-OCCI : CompatibleOne OCCI Server Library |
| ||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Disclaimer | |||||||||||||||||||||||||||||||||||||
|
THIS DOCUMENT AND THE SOFTWARE THAT IT DESCRIBES IS PROVIDED BY IAIN JAMES MARSHALL "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | |||||||||||||||||||||||||||||||||||||
| Table of Contents | |||||||||||||||||||||||||||||||||||||
|
| |||||||||||||||||||||||||||||||||||||
| Introduction | |||||||||||||||||||||||||||||||||||||
|
This document describes the CompatibleOne OCCI Server Library which provides the basic building block for the construction of CompatibleOne OCCI Service components comprising the Accords platform.
This library is a standard This OCCI server package provides all the functions required to build the OCCI category structures needed for the description of the behaviour of the OCCI server. The list of categories is passed to the OCCI server on startup and provides the tables of interface methods to be called back as required to satisfy the service requests received through the underlying HTTP/REST server. The concepts and terminology required for the correct understanding of the information provided in this document may be aquired using the specifications published on the http://occi-wg.org">Open Cloud Computing Interface (OCCI) web site. The overall architecture of the use of this library can be seen in the following table.
From the above it should be understood that:
| |||||||||||||||||||||||||||||||||||||
| Application Programming Interface | |||||||||||||||||||||||||||||||||||||
|
This section of this document describes the public functional interface of the CompatibleOne OCCI Server Library which provides a basic building block for the construction of the CompatibleOne OCCI Accords platform and tools.
| |||||||||||||||||||||||||||||||||||||
| occi_server | Create and Operate an OCCI Server | ||||||||||||||||||||||||||||||||||||
|
Syntax
Description The OCCI Server Library is built on top of the functionalities provided by the REST Server library and delegates responsibility for the processing of all aspects of the low level HTTP communication, message reception and response transmission. Each of the categories in the category list will provide their own functional interface table for each of the REST operational verbs ( GET, POST, PUT, DELETE, HEAD).
Actions defined for individual categories will provide the function pointer to the application function implementing their particular behaviour. These function relays allow the actual behaviour of the server to be defined outside of the library and will be invoked passing the concerned OCCI category object, the client connection structure and the request description structure as parameters. Each The function relay is to return a valid REST response structure pointer describing the details of the response to be produced and returned to the client by the REST server. Parameters
Example
An example of the
| |||||||||||||||||||||||||||||||||||||
| occi_remove_category | Removal of an OCCI Category | ||||||||||||||||||||||||||||||||||||
Syntax
Description This function allows the removal of a complete OCCI category representation structure including its underlying attribute and action lists. All memory associated with the category control structure will be released. Parameters
Example An example of the use of this function is provided in the example demonstrating the category list builder. | |||||||||||||||||||||||||||||||||||||
| occi_add_attribute | Addition of an Attribute to a Category | ||||||||||||||||||||||||||||||||||||
Syntax Description This library function is to be used for the addition of an OCCI Attribute control structure to an OCCI Category control structure. The parameters provided at the call will be used to describe the attribute. Parameters
Example An example of the use of this function can be found here. | |||||||||||||||||||||||||||||||||||||
| occi_add_action | Addition of an Action to a Category | ||||||||||||||||||||||||||||||||||||
Syntax Description This library function is to be used for the addition of an OCCI Action control structure to an OCCI Category control structure. The parameters provided at the call will be used to describe the action. Parameters
Example An example of the use of this function can be found here. | |||||||||||||||||||||||||||||||||||||
| occi_create_category | Creation of an OCCI Category | ||||||||||||||||||||||||||||||||||||
Syntax Description This function allows the creation of an OCCI category control structure. It will be used to provide the description of an OCCI category during the operation of an OCCI Server Instance. The structure will be used as the parameter to the appropriate functions for tha addition of OCCI Attribute and Action descriptons. Parameters
Here we have a example implementation of the function
Clearly, in the above example only one category instance is created and returned to the caller. Further
instances may be appended via the double linked list pointers provided within the
| |||||||||||||||||||||||||||||||||||||
| Structures and Data Types | |||||||||||||||||||||||||||||||||||||
| struct occi_category | The OCCI Category Structure definition | ||||||||||||||||||||||||||||||||||||
|
This structure contains the information needed to both represent and operate an OCCI category
within this C implementation of an OCCI Server. In all functional interface descriptions above
the term The structure contains fields required for the management of the category with in the server, other fields necessary for the description of the category and finally fields needed for its flexible operation within an abstract processing tool chain.
| |||||||||||||||||||||||||||||||||||||
| struct occi_attribute | The OCCI Attribute Structure definition | ||||||||||||||||||||||||||||||||||||
|
This structure contains the information needed to both represent and operate an attribute of
an OCCI category within this C implementation of an OCCI Server. In all functional interface
descriptions above the term
| |||||||||||||||||||||||||||||||||||||
| struct occi_action | The OCCI Action Structure definition | ||||||||||||||||||||||||||||||||||||
|
This structure contains the information needed to both represent and operate an action of
an OCCI category within this C implementation of an OCCI Server. In all functional interface
descriptions above the term
| |||||||||||||||||||||||||||||||||||||
| Reference Material | |||||||||||||||||||||||||||||||||||||
|
| |||||||||||||||||||||||||||||||||||||
| Publication and Licensing Information | |||||||||||||||||||||||||||||||||||||
| The sources of this work are published under the terms of the LGPL by Iain James Marshall of Prologue at http://gitorious.ow2.org/ow2-compatibleone/accords"> http://gitorious.ow2.org/ow2-compatibleone/accords | |||||||||||||||||||||||||||||||||||||
|
http://creativecommons.org/licenses/by-nc-nd/3.0/">
Ce(tte) http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">oeuvre de http://creativecommons.org/ns#" property="cc:attributionName">Iain James Marshall est mise à disposition selon les termes de la http://creativecommons.org/licenses/by-nc-nd/3.0/">licence Creative Commons Paternité - Pas dUtilisation Commerciale - Pas de Modification 3.0 non transcrit. | |||||||||||||||||||||||||||||||||||||
| CompatibleOne Accords Open Source Distribution |
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Information | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
This document provides important information describing the CompatibleOne Accords Open Source Distribution published by Iain James Marshall for Prologue for the OW2 Open Source Comunity in September 2011. These sources are provided in accordance with the CreativeCommons Open Source Software License as expresed at the foot of this page, and all roghts are currently reserved. The following table summarises the libraries and executable programs that may be built from this source distribution.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
http://creativecommons.org/licenses/by-nc-nd/3.0/">
Ce(tte) http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">oeuvre de http://creativecommons.org/ns#" property="cc:attributionName">Iain James Marshall est mise à disposition selon les termes de la http://creativecommons.org/licenses/by-nc-nd/3.0/">licence Creative Commons Paternité - Pas dUtilisation Commerciale - Pas de Modification 3.0 non transcrit. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||