1 2 Previous Next 29 Replies Latest reply on Jun 26, 2014 12:03 PM by antonid Go to original post
      • 15. Re: restful api modeshape
        antonid

        any suggestions please

        • 16. Re: restful api modeshape
          antonid

          i try to point my config file.(in my web .xml)..... i have the follwoing error

           

          ERROR Cannot load the names of the available repositories.

           

           

          <context-param>

             <param-name>org.modeshape.jcr.URL</param-name>
             <param-value>http://localhost:8080/ModeshapeFrontEnd/resources/my_repository_config.json</param-value>

              </context-param>

           

           

          Your context tag in your web.xml file .modeshape-web-jcr-rest-war that i have downloaded/

           

          <context-param>
              <param-name>org.modeshape.jcr.URL</param-name>
              <param-value>file:/repository-config.json</param-value>
          </context-param

          i struggle a lot.

          advance thanks

          • 17. Re: restful api modeshape
            antonid

             

            i have just applied as shown in the docu. i have file not found error ; so the repository is not loaded

             

            <context-param>
               <param-name>org.modeshape.jcr.URL</param-name>
               <param-value>classpath:resources/my_repository_config.json</param-value>

                </context-param>

             

             

             

            <context-param>
               <param-name>org.modeshape.jcr.URL</param-name>
               <param-value>file://C:/Projet_Gestion_Documents/Projects/FINALVERSION/GESTIONMODESHAPE/src/main/resources/repositoryConfigFile.json</param-value>

                </context-param>

             

            i have this result on my html page.

            {"repositories": []}



            is there any other thing i have to do ??

            • 18. Re: restful api modeshape
              antonid

              hello sir,

              i badly need a help.

              this contect part of web.xml

               

              this is the context part of web.xml :

              <context-param>
              <param-name>org.modeshape.jcr.URL</param-name>
              <param-value>file://C:/Projet_Gestion_Documents/Projects/FINALVERSION/GESTIONMODESHAPE/ModeShapeFrontEnd/target/classes/my_repository_config.json</param-value>

                  </context-param>

               

               

              angular js part(client side) :

               

              var Modeshape = angular.module('ModeShapePortail', []);

              Modeshape.controller('listworkspacesCtrl',function($scope, $http) {

                  alert("before localhost");

                  $http.get('http://localhost:8080/modeshape-rest/Persisted_Repository').success(function(data) {

                              alert(data);

                              $scope.listwspacedata = data;

                          });

                  });

               

              Html :

               

              <!doctype html>

              <html ng-app="ModeShapePortail">

              <head>

              <title>Bienvenu Modeshape</title>

              <script    src="https://ajax.googleapis.com/ajax/libs/angularjs/1.0.8/angular.min.js"></script>

              <script src="js/ModeshapeCtrl.js"></script>

              </head>

              <body>

                  <h1>inside the body</h1>

                  <div ng-controller="listworkspacesCtrl" class="container">

                      <p>{{listwspacedata.id}}</p>

                      <p>{{listwspacedata.content}}</p>

               

                  </div>

              </body>

              </html>

               

               

              i think  context-param is not pointing the config file ?

              could you please tell me things that i'm missing ??

              i send u my pom and web.xml in rar file

              advance thanks

              • 19. Re: restful api modeshape
                rhauch

                this is the context part of web.xml :

                <context-param>
                  <param-name>org.modeshape.jcr.URL</param-name>
                  <param-value>file://C:/Projet_Gestion_Documents/Projects/FINALVERSION/GESTIONMODESHAPE/ModeShapeFrontEnd/target/classes/my_repository_config.json</param-value>

                    </context-param>

                 

                ...


                i think  context-param is not pointing the config file ?

                could you please tell me things that i'm missing ??

                Do you have the configuration file at that location? If so, it's an absolute path and I would *think* the server would find it. But of course not every kind of server is the same, so I can't say for sure. Maybe it requires a relative path to a file within the JAR file???

                • 20. Re: restful api modeshape
                  antonid

                  thanks

                  i use tomcat server.....

                  i use this war depedency in my pom file :

                   

                  <dependency>

                  <groupId>org.modeshape</groupId>

                  <artifactId>modeshape-web-jcr-rest-war</artifactId>

                  <version>3.8.0.Final</version>

                  <type>war</type>

                  </dependency>

                   

                  Maybe it requires a relative path to a file within the JAR file???  how to do it

                   

                  <!DOCTYPE web-app PUBLIC

                  "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"

                  "http://java.sun.com/dtd/web-app_2_3.dtd" >

                  <web-app>

                      <display-name>ModeshapeFrontEnd</display-name>

                      <!-- http://localhost:8080/MoseShapeFrontEnd/src/my_repository_config.json

                          ; file://C:/Projet_Gestion_Documents/Projects/FINALVERSION/GESTIONMODESHAPE/ModeShapeFrontEnd/target/classes/my_repository_config.json -->

                      <context-param>

                          <param-name>org.modeshape.jcr.URL</param-name>

                          <param-value>file:/my_repository_config.json</param-value>

                      </context-param>

                      <context-param>

                          <param-name>javax.ws.rs.Application</param-name>

                          <param-value>org.modeshape.web.jcr.rest.JcrApplication</param-value>

                      </context-param>

                    

                      <!-- Required parameter for RESTEasy - should not be modified -->

                      <listener>

                          <listener-class>org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap</listener-class>

                      </listener>

                   

                      <!-- Required parameter for ModeShape REST - should not be modified -->

                      <listener>

                          <listener-class>org.modeshape.web.jcr.ModeShapeJcrDeployer</listener-class>

                      </listener>

                    

                      <!-- Required parameter for RESTEasy - should not be modified rest-servlet -->

                      <servlet>

                          <!--<servlet-name>rest-servlet</servlet-name> <servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>com.sun.jersey.spi.container.servlet.ServletContainer -->

                          <servlet-name>rest-servlet</servlet-name>

                          <servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>

                          <!-- <init-param> <param-name>com.sun.jersey.config.property.packages</param-name>

                              <param-value>com.evolutionenegy.server</param-value> </init-param> -->

                          <init-param>

                              <param-name>com.sun.jersey.api.json.POJOMappingFeature</param-name>

                              <param-value>true</param-value>

                          </init-param>

                          <load-on-startup>1</load-on-startup>

                      </servlet>

                   

                      <servlet-mapping>

                          <servlet-name>rest-servlet</servlet-name>

                          <url-pattern>/Rest/*</url-pattern>

                      </servlet-mapping>

                   

                      <welcome-file-list>

                          <welcome-file>Portail.html</welcome-file>

                      </welcome-file-list>

                  </web-app>

                   

                  thanks

                  • 21. Re: restful api modeshape
                    antonid

                    is there any other thing that i should verify ?

                    i still have the same problem. i could not point  my repository.

                     

                        <context-param>

                            <param-name>org.modeshape.jcr.URL</param-name>

                            <param-value>file://C:/Projet_Gestion_Documents/Projects/FINALVERSION/GESTIONMODESHAPE/ModeShapeFrontEnd/target/classes/my_repository_config.json</param-value>

                        </context-param>

                        <context-param>


                     

                    • 22. Re: restful api modeshape
                      antonid

                      hello sir,

                       

                      this is my  web.xml

                      i dont know what to do ; if you want i will send u the project zip file. COuld you please help me (no one knows modeshape around me)

                       

                      <!DOCTYPE web-app PUBLIC

                      "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"

                      "http://java.sun.com/dtd/web-app_2_3.dtd" >

                      <web-app>

                          <display-name>ModeshapeFrontEnd</display-name>

                          <!-- http://localhost:8080/MoseShapeFrontEnd/src/my_repository_config.json

                              ; file://C:/Projet_Gestion_Documents/Projects/FINALVERSION/GESTIONMODESHAPE/ModeShapeFrontEnd/target/classes/my_repository_config.json -->

                          <context-param>

                              <param-name>org.modeshape.jcr.URL</param-name>

                              <param-value>file://C:/Projet_Gestion_Documents/Projects/FINALVERSION/GESTIONMODESHAPE/ModeShapeFrontEnd/target/classes/my_repository_config.json</param-value>

                          </context-param>

                          <context-param>

                              <param-name>javax.ws.rs.Application</param-name>

                              <param-value>org.modeshape.web.jcr.rest.JcrApplication</param-value>

                          </context-param>

                         

                          <!-- Required parameter for RESTEasy - should not be modified -->

                          <listener>

                              <listener-class>org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap</listener-class>

                          </listener>

                       

                          <!-- Required parameter for ModeShape REST - should not be modified -->

                          <listener>

                              <listener-class>org.modeshape.web.jcr.ModeShapeJcrDeployer</listener-class>

                          </listener>

                         

                          <!-- Required parameter for RESTEasy - should not be modified rest-servlet -->

                          <servlet>

                              <!--<servlet-name>rest-servlet</servlet-name> <servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>com.sun.jersey.spi.container.servlet.ServletContainer -->

                              <servlet-name>rest-servlet</servlet-name>

                              <servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>

                              <!-- <init-param> <param-name>com.sun.jersey.config.property.packages</param-name>

                                  <param-value>com.evolutionenegy.server</param-value> </init-param> -->

                              <init-param>

                                  <param-name>com.sun.jersey.api.json.POJOMappingFeature</param-name>

                                  <param-value>true</param-value>

                              </init-param>

                              <load-on-startup>1</load-on-startup>

                          </servlet>

                       

                          <servlet-mapping>

                              <servlet-name>rest-servlet</servlet-name>

                              <url-pattern>/Rest/*</url-pattern>

                          </servlet-mapping>

                       

                          <welcome-file-list>

                              <welcome-file>Portail.html</welcome-file>

                          </welcome-file-list>

                      </web-app>

                       

                       

                       

                       

                      angular js part(client side) :

                       

                       

                      var Modeshape = angular.module('ModeShapePortail', []);

                       

                      Modeshape.controller('listworkspacesCtrl',function($scope, $http) {

                       

                          alert("before localhost");

                       

                          $http.get('http://localhost:8080/modeshape-rest/Persisted_Repository').success(function(data) {

                       

                                      alert(data);

                       

                                      $scope.listwspacedata = data;

                       

                                  });

                       

                          });

                       

                       

                      My  POM FILE : (i use the dependency as explained in the document)

                       

                      <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

                          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

                          <modelVersion>4.0.0</modelVersion>

                          <groupId>com.javahorn</groupId>

                          <artifactId>MoseShapeFrontEnd</artifactId>

                          <packaging>war</packaging>

                          <version>0.0.1-SNAPSHOT</version>

                          <name>Modeshape RestFulService Maven Webapp</name>

                          <!-- <url>http://maven.apache.org</url> -->

                          <url>http://www.modeshape.org</url>

                          <!--restful web services pour modeshape begin -->

                          <!-- <parent> <artifactId>modeshape</artifactId> <groupId>org.modeshape</groupId>

                              <version>0.7</version> <relativePath>../..</relativePath> </parent> -->

                          <!-- modeshape debut <url>http://www.modeshape.org</url> modeshape end -->

                          <!--restful web services pour modeshape -->

                          <properties>

                              <!-- Instruct the build to use only UTF-8 encoding for source code -->

                              <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

                              <!-- Global dependency version information -->

                              <modeshape.version>3.7.2.Final</modeshape.version>

                              <c3p0.version>0.9.1.2</c3p0.version>

                              <!-- Maven plugin versions -->

                              <maven.surefire.report.plugin.version>2.4.3</maven.surefire.report.plugin.version>

                              <maven.surefire.plugin.version>2.7.1</maven.surefire.plugin.version>

                              <maven.assembly.plugin.version>2.2</maven.assembly.plugin.version>

                              <maven.install.plugin.version>2.3.1</maven.install.plugin.version>

                              <maven.jar.plugin.version>2.3.1</maven.jar.plugin.version>

                              <maven.compiler.plugin.version>2.3.2</maven.compiler.plugin.version>

                              <maven.source.plugin.version>2.1.2</maven.source.plugin.version>

                              <maven.resources.plugin.version>2.4.3</maven.resources.plugin.version>

                          </properties>

                          <dependencyManagement>

                              <dependencies>

                                  <!-- Import the ModeShape BOM for embedded usage. This adds to the "dependenciesManagement"

                                      section defaults for all of the modules we might need, but we still have

                                      to include in the "dependencies" section the modules we DO need. The benefit

                                      is that we don't have to specify the versions of any of those modules. -->

                                  <dependency>

                                      <groupId>org.modeshape.bom</groupId>

                                      <artifactId>modeshape-bom-embedded</artifactId>

                                      <version>${modeshape.version}</version>

                                      <type>pom</type>

                                      <scope>import</scope>

                                  </dependency>

                              </dependencies>

                          </dependencyManagement>

                          <dependencies>

                              <!-- Modeshape begin -->

                              <dependency>

                                  <groupId>org.modeshape</groupId>

                                  <artifactId>modeshape-jcr-api</artifactId>

                              </dependency>

                              <dependency>

                                  <groupId>org.modeshape</groupId>

                                  <artifactId>modeshape-jcr</artifactId>

                              </dependency>

                              <dependency>

                                  <groupId>org.modeshape</groupId>

                                  <artifactId>modeshape-common</artifactId>

                              </dependency>

                              <dependency>

                                  <groupId>org.infinispan</groupId>

                                  <artifactId>infinispan-cachestore-jdbc</artifactId>

                              </dependency>

                              <dependency>

                                  <groupId>c3p0</groupId>

                                  <artifactId>c3p0</artifactId>

                                  <version>${c3p0.version}</version>

                              </dependency>

                              <!-- <dependency> <groupId>com.h2database</groupId> <artifactId>h2</artifactId>

                                  <version>${jdbc.h2.version}</version> </dependency> -->

                              <dependency>

                                  <groupId>com.microsoft.sqlserver</groupId>

                                  <artifactId>sqljdbc4</artifactId>

                                  <version>4.0</version>

                              </dependency>

                              <dependency>

                                  <groupId>javax.ws.rs</groupId>

                                  <artifactId>jsr311-api</artifactId>

                                  <version>0.11</version>

                              </dependency>

                              <!-- Modeshape end -->

                              <dependency>

                                  <groupId>junit</groupId>

                                  <artifactId>junit</artifactId>

                                  <version>3.8.1</version>

                                  <scope>test</scope>

                              </dependency>

                              <dependency>

                                  <groupId>com.sun.jersey</groupId>

                                  <artifactId>jersey-server</artifactId>

                                  <version>1.8</version>

                              </dependency>

                              <dependency>

                                  <groupId>com.sun.jersey</groupId>

                                  <artifactId>jersey-json</artifactId>

                                  <version>1.8</version>

                              </dependency>

                              <dependency>

                                  <groupId>com.sun.jersey</groupId>

                                  <artifactId>jersey-bundle</artifactId>

                                  <version>1.10-b01</version>

                              </dependency>

                              <dependency>
                                  <groupId>org.modeshape</groupId>
                                  <artifactId>modeshape-web-jcr-rest-war</artifactId>
                                  <version>3.8.0.Final</version>
                                  <type>war</type>
                              </dependency>

                              <!-- convert java to json format begin -->

                              <dependency>

                                  <groupId>com.google.code.gson</groupId>

                                  <artifactId>gson</artifactId>

                                  <version>1.7.1</version>

                              </dependency>

                              <!-- convert java to json format end -->

                       

                              <!-- Modeshape rest web services begin -->

                              <!-- <dependency> <groupId>org.modeshape</groupId> <artifactId>modeshape-web-jcr-rest</artifactId>

                                  <version>0.7</version> </dependency> -->

                              <!-- <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-log4j12</artifactId>

                                  <version>1.5.8</version> <scope>runtime</scope> </dependency> -->

                              <!-- <dependency> <groupId>org.jboss.resteasy</groupId> <artifactId>resteasy-client</artifactId>

                                  <version>1.1.GA</version> </dependency> -->

                              <!--Modeshape rest web services end -->

                          </dependencies>

                          <build>

                              <finalName>MoseShapeFrontEnd</finalName>

                              <!-- Added for modesahpe begin -->

                              <resources>

                                  <resource>

                                      <directory>src/main/resources</directory>

                                  </resource>

                                  <resource>

                                      <directory>src/main/java</directory>

                                      <includes>

                                          <include>**</include>

                                      </includes>

                                      <excludes>

                                          <exclude>**/*.java</exclude>

                                      </excludes>

                                  </resource>

                              </resources>

                              <!-- Added for modesahpe end -->

                              <pluginManagement>

                                  <plugins>

                                      <plugin>

                                          <groupId>org.apache.maven.plugins</groupId>

                                          <artifactId>maven-surefire-plugin</artifactId>

                                          <configuration>

                                              <includes>

                                                  <include>**/*Test.java</include>

                                              </includes>

                                          </configuration>

                                      </plugin>

                                  </plugins>

                              </pluginManagement>

                              <plugins>

                                  <!-- Specify the compiler options and settings -->

                                  <plugin>

                                      <groupId>org.apache.maven.plugins</groupId>

                                      <artifactId>maven-compiler-plugin</artifactId>

                                      <version>${maven.compiler.plugin.version}</version>

                                      <configuration>

                                          <source>1.6</source>

                                          <target>1.6</target>

                                          <showDeprecation>false</showDeprecation>

                                          <showWarnings>false</showWarnings>

                                      </configuration>

                                  </plugin>

                                  <plugin>

                                      <artifactId>maven-surefire-plugin</artifactId>

                                      <version>${maven.surefire.plugin.version}</version>

                                      <configuration>

                                          <includes>

                                              <include>**/*TestCase.java</include>

                                              <include>**/*Test.java</include>

                                          </includes>

                                      </configuration>

                                  </plugin>

                                  <!-- Produce source jars during the 'verify' phase -->

                                  <plugin>

                                      <groupId>org.apache.maven.plugins</groupId>

                                      <artifactId>maven-source-plugin</artifactId>

                                      <version>${maven.source.plugin.version}</version>

                                      <executions>

                                          <execution>

                                              <id>attach-sources</id>

                                              <phase>verify</phase>

                                              <goals>

                                                  <goal>jar</goal>

                                              </goals>

                                          </execution>

                                      </executions>

                                  </plugin>

                                  <!-- Build a test-jar for each project, so that src/test/* resources and

                                      classes can be used in other projects. Also customize how the jar files are

                                      assembled. -->

                                  <plugin>

                                      <groupId>org.apache.maven.plugins</groupId>

                                      <artifactId>maven-jar-plugin</artifactId>

                                      <version>${maven.jar.plugin.version}</version>

                                      <executions>

                                          <execution>

                                              <id>test-jar</id>

                                              <goals>

                                                  <goal>test-jar</goal>

                                              </goals>

                                          </execution>

                                      </executions>

                                  </plugin>

                              </plugins>

                          </build>

                          <!-- Added for modeshape begin -->

                          <repositories>

                              <repository>

                                  <id>JBoss-Releases</id>

                                  <url>https://repository.jboss.org/nexus/content/repositories/releases/</url>

                              </repository>

                          </repositories>

                          <!-- Added for modesahpe end -->

                      </project>

                       

                       

                       

                       

                       

                       

                       

                       

                      Html :

                       

                       

                      <!doctype html>

                       

                      <html ng-app="ModeShapePortail">

                       

                      <head>

                       

                      <title>Bienvenu Modeshape</title>

                       

                      <script    src="https://ajax.googleapis.com/ajax/libs/angularjs/1.0.8/angular.min.js"></script>

                       

                      <script src="js/ModeshapeCtrl.js"></script>

                       

                      </head>

                       

                      <body>

                       

                          <h1>inside the body</h1>

                       

                          <div ng-controller="listworkspacesCtrl" class="container">

                       

                              <p>{{listwspacedata.id}}</p>

                       

                              <p>{{listwspacedata.content}}</p>

                       

                       

                       

                          </div>

                       

                      </body>

                       

                      </html>

                       

                       

                       

                       

                       

                       

                       

                      could you please tell me things that i'm missing ??

                       

                      advance thanks

                      • 23. Re: restful api modeshape
                        antonid

                        by changing the servelet in my web xml

                         

                        <servlet-mapping>
                          <servlet-name>rest-servlet</servlet-name>
                          <url-pattern>/*</url-pattern>

                            </servlet-mapping>

                         

                         

                        12:30:49,293  WARN JMX bean "org.modeshape:name=Persisted_Repository,type=RepositoryStatistics" has already been registered

                        12:30:49,331 ERROR Node types were read from the system content, and appear to be inconsistent or invalid: Persisted_Repository

                        java.lang.NullPointerException

                        12:24:36,316 ERROR Cannot load the names of the available repositories.

                        javax.jcr.RepositoryException: org.modeshape.jcr.cache.NodeNotFoundException: d00d047317f1e7/jcr:system/jcr:nodeTypes/nt:unstructured/?/undefined/*

                         

                         

                         

                        but in html page i get this output (google chrome)

                         

                        {"repositories": [{  "name": "Persisted_Repository",  "workspaces": "http://localhost:8080/ModeShapeFrontEnd/Persisted_Repository",  "activeSessionsCount": 0,  "metadata": {    "custom.rep.name": "Persisted_Repository",    "identifier.stability": "identifier.stability.indefinite.duration",    "jcr.repository.name": "ModeShape",    "jcr.repository.vendor": "JBoss, a division of Red Hat",    "jcr.repository.vendor.url": "http://www.modeshape.org",    "jcr.repository.version": "3.7.2.Final",    "jcr.specification.name": "Content Repository for Java Technology API",    "jcr.specification.version": "2.0",    "level.1.supported": "true",    "level.2.supported": "true",    "node.type.management.autocreated.definitions.supported": "true",    "node.type.management.inheritance": "node.type.management.inheritance.multiple",    "node.type.management.multiple.binary.properties.supported": "true",    "node.type.management.multivalued.properties.supported": "true",    "node.type.management.orderable.child.nodes.supported": "true",    "node.type.management.overrides.supported": "true",    "node.type.management.primary.item.name.supported": "true",    "node.type.management.property.types": "true",    "node.type.management.residual.definitions.supported": "true",    "node.type.management.same.name.siblings.supported": "true",    "node.type.management.update.in.use.suported": "true",    "node.type.management.value.constraints.supported": "true",    "option.access.control.supported": "true",    "option.activities.supported": "false",    "option.baselines.supported": "false",    "option.journaled.observation.supported": "false",    "option.lifecycle.supported": "false",    "option.locking.supported": "true",    "option.node.and.property.with.same.name.supported": "true",    "option.node.type.management.supported": "true",    "option.observation.supported": "true",    "option.query.sql.supported": "true",    "option.retention.supported": "false",    "option.shareable.nodes.supported": "true",    "option.simple.versioning.supported": "false",    "option.transactions.supported": "true",    "option.unfiled.content.supported": "false",    "option.update.mixin.node.types.supported": "true",    "option.update.primary.node.type.supported": "true",    "option.versioning.supported": "true",    "option.workspace.management.supported": "true",    "option.xml.export.supported": "true",    "option.xml.import.supported": "true",    "query.full.text.search.supported": "true",    "query.joins": "query.joins.inner.outer",    "query.languages": [      "xpath",      "JCR-SQL2",      "sql",      "JCR-JQOM"    ],    "query.stored.queries.supported": "true",    "query.xpath.doc.order": "false",    "query.xpath.pos.index": "false",    "write.supported": "true"  }}]}

                         

                         

                         

                        am i going in the correct path please ; i j ust want to display and add one node and delete one nothing more .......

                        advance thanks

                        • 24. Re: restful api modeshape
                          rhauch

                          Frankly, I don't think the problem is with ModeShape, but with how your app is configured and deployed within your server. The only thing I can do is point you to the source code for our existing web services and other code/examples so you can see how they work. Sorry, but I don't have time to load up an environment like yours and debug your application.

                          • 25. Re: restful api modeshape
                            antonid

                            sorry to disurb you

                             

                            when i use this uri

                             

                            http://localhost:8080/ModeShapeFrontEnd/Persisted_Repository

                            it is supposed to give the liste of workspaces in a repository

                            whan i click on items link i get the following item. ie http://localhost:8080/MoseShapeFrontEnd/Persisted_Repository/otherWorkspace/items

                             

                             

                            Actually i have stored 3 nodes

                            new FileInputStream("C:\\test_modeshape\\modeshape_logo.jpg")

                            new FileInputStream("C:\\test_modeshape\\Introducing_ModeShape_3.0.pdf")

                            new FileInputStream("C:\\test_modeshape\\test.txt")

                             

                            is it possible get the exact names modeshape_logo ; Introducing_ModeShape_3.0.; test.txt ????

                             

                            advance thanks

                            • 26. Re: restful api modeshape
                              rhauch

                              The "http://localhost:8080/MoseShapeFrontEnd/Persisted_Repository/otherWorkspace/items" endpoint will provide a JSON representation of the root node in the repository workspace named "otherWorkspace". That JSON representation will contain under the "children" field a nested document with a field for each child. The output you pasted above shows that there is just one child: the node named "jcr:system" node. The "self" field for the child provide links that your clients can use to get to that child, whereas the "up" field contains a link to the parent of that child (which is in this case the same link from which you've gotten this response; this same format is used for all node summaries, so there are times when "up" is more useful).

                               

                              To me this says that you've not actually uploaded (and saved) any nodes or files into that workspace. Perhaps you uploaded it to the "defaulttest" workspace, which is also visible in the output from http://localhost:8080/ModeShapeFrontEnd/Persisted_Repository. If you think you have, check that your code that uploads it is correctly creating the nodes in the right location and then successfully saving the session.

                              • 27. Re: restful api modeshape
                                antonid

                                hello,

                                once again sorry to disurb you.

                                i have downloaded the program from github ModeShape/modeshape-examples · GitHub

                                and when i import into eclipse i have the following error in POM FIle.

                                 

                                 

                                please guide me

                                • 28. Re: restful api modeshape
                                  antonid

                                  Description    Resource    Path    Location    Type

                                  The container 'Maven Dependencies' references non existing library 'C:\Users\dev\.m2\repository\org\modeshape\modeshape-jcr\3.7-SNAPSHOT\modeshape-jcr-3.7-SNAPSHOT.jar'    modeshape-web-explorer-war        Build path    Build Path Problem

                                  • 29. Re: restful api modeshape
                                    antonid

                                    is there any suggestions

                                    1 2 Previous Next