[Glass] Zinc and REST on 3.1.0.X

Ken Treis ken at miriamtech.com
Tue Jul 2 12:14:30 PDT 2013


Hi Sebastian,

I can't offer too many details on the project itself, but it's built in Seaside and uses Seaside-REST in addition to regular Seaside components. We're migrating from Seaside 2.8 on VisualWorks to Seaside 3 on GLASS, but we're doing it incrementally. Right now, we're using a custom RESTful synchronization protocol that we use to move data between VW and GemStone. That same protocol is used to sync with about 50 desktop clients.

To keep GemStone responsive when you get a big request, you should consider running multiple Zinc backends. We currently proxy to 4 backends using Apache with mod_proxy_balancer and lbmethod=bybusyness. This routes incoming HTTP requests to the least-busy backend.

--
Ken Treis
Miriam Technologies, Inc.
(866) 652-2040 x221

On Jul 2, 2013, at 10:20 AM, Sebastian Heidbrink wrote:

> Hi Ken,
> 
> Thank you for al lthe vital information.
> Well, I know my project,... but I jsut started with Gemstone ;-)
> 
> I would like to have my API-Layer as small as possible. I'll have more GET than POST API Calls.
> POST interface methods will send big chucnks of data,... that's the next issue,... having a still responding Gemstone once some user loads up a lot of data.... 
> 
> But I think I am on a good way. Currently the Programmers Guido is my best friend ;-)
> 
> What are you using Gemstone for? Are only having a Webfrontend based on Seaside? I need to migrate some stuff from VAST to my web app and since some parts are very calculation intense I decided to move some stuff to the client and it seems to me like Amber is a better choice for that...
> 
> We will see. I need to get going, the business case won't last for ever and in the beginning of next year I need to be online...
> 
> Thanks for you advice again!
> Sebastian
> 
> Am 02.07.2013 09:21, schrieb Ken Treis:
>> I've never used Zinc in GemStone without the Seaside adaptors, but it shouldn't be too difficult to get Zinc running. To see the basic pattern, look at the startSeaside30_Adaptor script (in $GEMSTONE/seaside/bin), WAGemStoneRunSeasideGems class>>startGemServerOn:, and the Zinc adaptor class.
>> 
>> You'll be launching a topaz process for every Zinc backend that you want to run, and within topaz you'll instantiate your Zinc server and start it. While it runs (in its own thread), you'll keep the main thread busy with an infinite loop.
>> 
>> You'll also need to manage transactions yourself, which can be a little tricky. The Seaside code uses a big lock to make sure that only one thread can be in a transaction at a time, since GemStone's transactions are per-session and not per-thread. This alone might argue for using Seaside-REST over Zinc-REST, but you know your project and your needs better than I do. :)
>> 
>> --
>> Ken Treis
>> Miriam Technologies, Inc.
>> (866) 652-2040 x221
>> 
>> On Jul 2, 2013, at 7:44 AM, Sebastian Heidbrink wrote:
>> 
>>> Hi Ken,
>>> 
>>> thank you for the feedback!
>>> 
>>> So, you are using the SeasideAdaptors,.... do you also have experience using Zinc without any Seaside parts at all?
>>> I have trouble firing a ZnServer up.
>>> 
>>> I'll have a look at your surces and analize that script. Maybe I can go one from there now!
>>> 
>>> Thanks a lot again!
>>> Sebastian
>>> 
>>> Am 02.07.2013 07:35, schrieb Ken Treis:
>>>> Hi Sebastian,
>>>> 
>>>> We're using Zinc on 3.1.0.1 (hopefully upgrading to 3.1.0.4 this week). I don't remember everything I had to do to get it working, but I know it involved at least:
>>>> 
>>>> * Using a 3.1.0.X port of Zinc. Feel free to use my hacked versions here:
>>>> 
>>>>  http://mc.miriamtech.com/zinc
>>>> 
>>>> * Configuring WAGemStoneRunSeasideGems to use Zinc adaptors. Something like:
>>>> 
>>>>  WAGemStoneRunSeasideGems default
>>>>  name: 'Zinc';
>>>>  adaptorClass: WAGsZincAdaptor;
>>>>  ports: #(9001 9002 9003).
>>>> 
>>>> Hope that helps,
>>>> 
>>>> --
>>>> Ken Treis
>>>> Miriam Technologies, Inc.
>>>> (866) 652-2040 x221
>>>> 
>>>> On Jul 1, 2013, at 2:01 PM, Sebastian Heidbrink wrote:
>>>> 
>>>>> Hi All!
>>>>> 
>>>>> I finally started to port one of my prototypes to Gemstone/Web.
>>>>> 
>>>>> My Pharo portotype uses Seaside and Seaside-REST and Amber as a frontend.
>>>>> 
>>>>> I used the most current 3.1.0.4 version of Gemstone and I was wondering if somebody can give me some tips on how to startup Zinc.
>>>>> I do not really need Seaside and I would prefer to use Zinc-Rest for my kind of application....
>>>>> 
>>>>> I know that there are test failing currently but I'm not too sure if my loaded code base is the right one anyways.
>>>>> 
>>>>> Is there somebody how has at least managed to start a Zinc Server on 3.1.0.X and if so,... what did you load and how do you start it ;-)
>>>>> 
>>>>> Thanks for you help!
>>>>> Sebastian
>>>>> 
>>>>> _______________________________________________
>>>>> Glass mailing list
>>>>> Glass at lists.gemtalksystems.com
>>>>> http://lists.gemtalksystems.com/mailman/listinfo/glass
>>>> 
>>> 
>> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gemtalksystems.com/mailman/private/glass/attachments/20130702/590de8cf/attachment-0001.html>


More information about the Glass mailing list