Search Results

Search found 6 results on 1 pages for 'stel'.

Page 1/1 | 1 

  • Ruby xml rpc error handling

    - by stel
    I have a model class Car @@RPCServer = XMLRPC::Client.new("localhost", "/", 8080) def self.count @@RPCServer.call("cars.count") end end If server is not running on localhost:8080 I've got a Errno::ECONNREFUSED error. I want to display an error message to user, how can a handle this error?

    Read the article

  • Ruby On Rails CMS Framework

    - by stel
    Hi! I want to create a framework fo rails application. It will be a rails application but packed into gem (like a Radiant CMS). It must work like this: gem install cmsframework and then: cmsframework the_app After that we have a sceleton of rails app without any controllers etc.. - all controllers loaded from cmsframework gem. If I want to rewrite some files (for example public/styles.css) I must simply create it in my app (the_app). If I want new functions in my app I can create a plugin. But the main functionalities must be loaded from cmsframework gem. What is the best way to implement this?

    Read the article

  • Ruby xml rpc error handilng

    - by stel
    I have a model class Car @@RPCServer = XMLRPC::Client.new("localhost", "/", 8080) def self.count @@RPCServer.call("cars.count") end end If server is not running on localhost:8080 I've got a Errno::ECONNREFUSED error. I want to display an error message to user, how can a handle this error?

    Read the article

  • Ruby ActiveRecord + Mongrel going slow

    - by stel
    I have a class like this: class Router :: Mongrel::HttpHandler def process(req, res) status, header, body = [200, {"Content-type"="text/html"}, Model.all.to_xml] res.start(status) do |head, out| header.each_pair { |key, value| head[key] = value } out.write body end end end It's an server and I use an ActiveResource front end on the other side. Every 3rd request is very slow (about 5 seconds, 1st and 2nd is ok, about 0.01 sec). The problem in Model.all.to_xml (it is ActiveRecord - SQLite). Why it is too slow? It only happens when I use it in Mongrel::HttpHandler.. This 100.times do a = Time.now Car.all.to_xml puts "#{Time.now - a}" sleep(1) end is always works good.

    Read the article

  • WebCenter Content (WCC) Trace Sections

    - by Kevin Smith
    Kyle has a good post on how to modify the size and number of WebCenter Content (WCC) trace files. His post reminded me I have been meaning to write a post on WCC trace sections for a while. searchcache - Tells you if you query was found in the WCC search cache. searchquery - Shows the processing of the query as it is converted form what the user submitted to the end query that will be sent to the database. Shows conversion from the universal query syntax to the syntax specific to the search solution WCC is configured to use. services (verbose) - Lists the filters that are called for each service. This will let you know what filters are available for each service and will also tell you what filters are used by WCC add-on components and any custom components you have installed. The How To Component Sample has a list of filters, but it has not been updated since 7.5, so it is a little outdated now. With each new release WCC adds more filters. If you have a filter that has no code attached to it you will see output like this: services/6    09.25 06:40:26.270    IdcServer-423    Called filter event computeDocName with no filter plugins registered When a WCC add-on or custom component uses a filter you will see trace output like this: services/6    09.25 06:40:26.275    IdcServer-423    Calling filter event postValidateCheckinData on class collections.CollectionValidateCheckinData with parameter postValidateCheckinDataservices/6    09.25 06:40:26.275    IdcServer-423    Calling filter event postValidateCheckinData on class collections.CollectionFilters with parameter postValidateCheckinData As you can see from this sample output it is possible to have multiple code points using the same filter. systemdatabase - Dumps the database call AFTER it executes. This can be somewhat troublesome if you are trying to track down some weird database problems. We had a problem where WCC was getting into a deadlock situation. We turned on the systemdatabase trace section and thought we had the problem database call, but it turned out since it printed out the database call after it was executed we were looking at the database call BEFORE the one causing the deadlock. We ended up having to turn on tracing at the database level to see the database call WCC was making that was causing the deadlock. socketrequests (verbose) - dumps the actual messages received and sent over the socket connection by WCC for a service. If you have gzip enabled you will see junk on the response coming back from WCC. For debugging disable the gzip of the WCC response.Here is an example of the dump of the request for a GET_SEARCH_RESULTS service call. socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: REMOTE_USER=sysadmin.USER-AGENT=Java;.Stel socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: lent.CIS.11g.CONTENT_TYPE=text/html.HEADER socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: _ENCODING=UTF-8.REQUEST_METHOD=POST.CONTEN socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: T_LENGTH=270.HTTP_HOST=CIS.$$$$.NoHttpHead socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: ers=0.IsJava=1.IdcService=GET_SEARCH_RESUL socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: [email protected] socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: calData.SortField=dDocName.ClientEncoding= socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: UTF-8.IdcService=GET_SEARCH_RESULTS.UserTi socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: meZone=UTC.UserDateFormat=iso8601.SortDesc socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: =ASC.QueryText=dDocType..matches..`Documen socketrequests/6 09.25 06:46:02.501 IdcServer-6 request: t`.@end. userstorage, jps - Provides trace details for user authentication and authorization. Includes information on the determination of what roles and accounts a user has access to. In 11g a new trace section, jps, was added with the addition of the JpsUserProvider to communicate with WebLogic Server. The WCC developers decide when to use the verbose option for their trace output, so sometime you need to try verbose to see what different information you get. One of the things I would always have liked to see if the ability to turn on verbose output selectively for individual trace sections. When you turn on verbose output you get it for all trace sections you have enabled. This can quickly fill up your trace files with a lot of information if you have the socket trace section turned on.

    Read the article

1