I have a builder C++ application. I need to know how to use Solr with my C++ Application.
Solr is written in Java and runs as a standalone full-text search server within a servlet container such as Apache Tomcat or Jetty.
I need solr for indexing and search.
is there any way to use Solr with my C++ application?
Thank you!
You'll interact with Solr through HTTP, so using libcurl or POCO to make the request and then parse the resulting XML or JSON is a possible (and easy) solution.
The only client I've seen mentioned is SolrCPP, although I don't think that is maintained or available in any decent form any longer (It's the only one mentioned on the Integrating Solr list).
Related
Two weeks ago I'm having trouble finding the Internet a way for my solution. I need to integrate a web application with Apache Solr and Apache tika, to be made faceted search PDF's that are in the database of the system. The configuration of solr and tika on my server everything is ok, but as I am new with these two tools, I'm not sure how to integrate one another and also with the application.
Solr 6.2 ships with files example in the example/files that is configured specifically to index and browse rich-content files (like PDF).
Start by using that and try to understand how it is put together.
In Laravel 4 framework, how to create a SOAP based web service. I would like to build a SOA based web application in laravel. Please clarify with an example how to use web service with some step by step examples or links as i am completely new to laravel
Thanks in advance..
You can use "php-wsdl-creator" (also supports SOAP). They have a great tutorial and many demo php files to get you started. It can also easily be implemented in laravel or any other framework for that matter. :)
You can find more information on Google Code: https://code.google.com/p/php-wsdl-creator/
Also note that SOAP requires an extension to be loaded in PHP.
For more recent needs, you should use a Project such as wsdl2phpgenerator or PackageGenerator from WsdlToPhp. This sort of projects, requirable with composer, use an OOP approach and allows to build a SOAP request easily with PHP objects then handle the response just as the request with PHP objects.
We have a wsdl for which we need to create a server implementation. In previous projects we used wsdl2java from Apache CXF, but now we want to keep it all in Groovy. Is there a way in which we can create a server implementation and keep it all in Groovy? Or are there any other ways we can achieve this?
The ultimate goal would be that we can hook this implementation into a Grails application that will serve as the server for clients.
Yes. You can either use the plugin or use cxf directly.
If you follow that tutorial, you can always use wsdl2java and just rename the generated files to be .groovy files and update the syntax to be more groovified. They will still work like normal. Also, as you may or may not know, you don't have to copy the jars directly to your lib directory as it says in the tutorial, you can just use normal Grails dependency management.
I think a better fit for you would be Groovy WS Lite. Spring-ws is also an option, it is a powerful library and reasonably well documented, since grails is spring at the end of day, this may integrate very well with grails. Shameless plug: This is web service integration testing tool I created which uses groovy and spring-ws. You can see the code to get a "working example".
for one of my applications I'd like to provide a minimal web interface. This core application is written in C++ and uses Qt4 as a framework. Since I'm also using some libraries I wrote to calculate some things and do some complex data management, I'd like to use this existing code as a backend to the web interface.
Idea 1: Using an embedded web server
The first thing I tried (and which worked to some degree) was using an embedded web server (mongoose). As you can imagine, it is just a very thin library and you have to implement a lot of things yourself (like session management, cookies, etc.).
Idea 2: Using a normal web server and adding a fcgi/cgi/scgi backend to my application
The next thing that came to my head was using a mature but compact web server (for instance, lighttpd) and simple provide a fcgi/scgi/cgi backend to it. I could write the web application using a good framework, like Pylons, PHP, or RoR, (...) and simply have an URL prefix, like /a/... which allows me to directly talk to the backend.
I tried to implement the libfcgi into my application, but it looks messier than needed (for instance you'd have to implement your own TCP/IP sockets to pass on data between your app and the web server and tunnel it through the FCGI library, meh)
Idea 3: Creating a command line version of my application which does the most basic things and use a normal web server and framework to do the rest
This is the third idea that came to my head. It is basically about creating a web application using a traditional way (PHP, RoR, etc.) and using a command line version of my application to process data and return it when needed.
I've got some experience with creating web applications, but I never had to do something like this, so I'd like to hear some ideas or suggestions. I'd like to use JavaScript on the browsers (AJAX, that is) and pass some JSON constructs between web browser and server to make the user experience a bit smoother.
So what are your suggestions, ideas on this? I don't want to re-invent the wheel, honestly.
I would never expose a custom written application to the net as front-end, for that servers like apache or lighthttp are build. They give you some serious security out of the box.
As for interaction of your app with that webserver, it depends a bit on the load and what kind of experience you have with writing software in PHP, python or other languages supported by your web server (via interpreter of course).
A slight load, and a command line tool accessed from PHP might do perfectly well.
A more heavy load and you might wish to implement a simple (SOAP?) server with Qt and access that from a python (or php) script.
That way you don't need to do layout in you app, and you also don't need to implement security all that much.
I'm currently researching a similar situation (custom web app backend using Qt), and the least bad option is FastCGI. Found something you might be interested in. Not production ready without some serious testing, but this might be a good starting point for Qt - FastCGI interop: FastCGIQt
I've used the FastCGI Protocol Driver library for a similar project (also a Qt application), the download link is at the end of that page [Libfastcgi]. Integration with the application turned out actually comparatively easy. Lighttpd + mod_fastcgi was used as web server. Can't say anything about FastCGIQt, though.
You Wt works well to provide a web interface to Qt based applications. Both have a similar programming style, and there's an example that demonstrates the integration with Qt.
Here is example of embedded QML-server: https://github.com/ncp1402/ql-server
both seems to be pretty cool
which is to be in used in what scenario ?
GWT: http://code.google.com/webtoolkit/
Faster AJAX than you'd write by hand
With Google Web Toolkit (GWT), you
write your AJAX front-end in the Java
programming language which GWT then
cross-compiles into optimized
JavaScript that automatically works
across all major browsers.
Django: http://www.djangoproject.com/
a high-level Python Web framework that
encourages rapid development and
clean, pragmatic design.
They have little or nothing to do with each other. Django provides some Javascript; Django can easily handle the server-side of any Ajax conversation.
Django doesn't help you write javascript. It helps you write the server-side of the application.
Django helps you write the HTML pagess (with templates). If the page includes, or relies on Javascript, Django doesn't care very much at all.
pyjamas is a Python port of the GWT, so all the javascript is generated using Python instead of Java.
If you're planning on working with Django it might simplify to make your entire shop code in Python.
It is quite possible to use both in the same project. I've been working on such a project for some time now. Have Django handle the server side and leave the client side to GWT. The only issue I have is that the RPC mechanism in GWT cannot be used because it works with Java servlets. I use JSON for communication instead.
With GWT you write client-side applications, that run inside some browser Javascript engine. You code in Java, and it gets compiled into Javascript.
Django, is different because you write server-side applications: applications will be executed in the server and their result is sent to the client browser. Ah! Django is Python.
Both have libraries to achieve most of the tasks web developer needs, like internationalization, sessions, etc. Django comes with a nice ORM (Object Relational Mapper) and GWT comes with a Tomcat based engine, for the server-side coding and development.
If you need to make a decision just choose the framework based in the language of your choice.
I use xml serialization for communication between django and gwt
http://www.eecho.info/Echo/ajax/requestbuilder-gwt-15/