Este problema me ha dado la lata un buen rato. Me animo con este post porque no he encontrado prácticamente ninguna información sobre cómo hacer esto. El problema que queremos solucionar es sencillo de explicar:
Tenemos una entidad llamada FooData. Queremos recuperar n objetos fooData aleatorios.
Suponiendo que la tabla correspondiente a FooData es foo, en mysql podemos resolver nuestro problema con una query tal que así:
select * from foo order by rand() limit n;En Oracle 9 la query es un poco más compleja, sobre todo por la parte de limitar el número de registros a devolver, que se resuelve con una subquery:
select * from ( select * from rolleruser order by dbms_random.value) where rownum < nUna vez que sabemos resolver nuestro problema en SQL y que ya hemos visto que no hay una solución estándar, vamos a tratar de implementarlo mediante HQL.
La parte de obtener únicamente n resultados es trivial, ya que disponemos del método org.hibernate.Query.setMaxResults(int arg0). El esqueleto de nuestro código sería parecido a:
Session session = ((HibernatePersistenceStrategy)this.strategy).getSession(); Dialect currentDialect = ((SessionFactoryImplementor) session.getSessionFactory()).getDialect(); String queryString = null; if (currentDialect instanceof Oracle9Dialect) { // Oracle 9 specific queryString = "CUSTOM_QUERY_1"; } else { // MYSQL specific queryString = "CUSTOM_QUERY_2"; } Query query = session.createQuery(queryString); query.setMaxResults(amount);Donde será necesario sustituir CUSTOM_QUERY_1 y CUSTOM_QUERY_2 por los valores adecuados en cada una de las ramas del if.
HQL para obtener n registros aleatorios con MySQLPara hacer esta consulta con HQL "sobre" mysql, la traducción es casi directa. Eliminamos el limit, pues ya limitamos el número de resultados con setMaxResults() y cambiamos el nombre de la tabla por el nombre de la entidad, de modo que en el ejemplo anterior donde teníamos CUSTOM_QUERY_1, ahora tendremos:.
from FooEntry foo order by rand(); HQL para obtener n registros aleatorios con Oracle 9Esta traducción es casi tan trivial como la anterior, pero con matices. Utilizando la misma lógica que en el apartado anterior llegamos a una query más o menos así:
from FooEntry foo order by dbms_random.value;Esta query no funciona, pues nuestro amigo Hibernate trata de buscar el atributo value de la entidad dbms_random. Y no encuentra el mapping, porque no lo hay. Solo tenemos que buscar la manera de que la BD reciba la query adecuada. Tras un buen rato de ensayo-error, llegamos a la siguiente solución:
from FooEntry foo order by dbms_random.random() Ahora nuestro driver si que es capaz de "saber" que dbms_random.random() no es cosa suya y que lo único que tiene que hacer es dejar pasar ese trocito de query para que Oracle juegue con el.
Sustituyendo CUSTOM_QUERY_2 por esta última query, ya tendremos el puzzle completo.
Groovy language support becomes a little bit better in Maia with the support for named parameters completion. Maia is now capable of displaying all named parameters ever used in method bodies.

Hello everybody.
I'm a little bit confused with the partition sizing under vmware via Kickstart script. I created a script with following parameters.
# Partitioning
part /boot --fstype ext3 --size 251 --ondisk sda --asprimary
part swap --size 2047 --ondisk sda --asprimary
part / --fstype ext3 --size 5122 --ondisk sda --asprimary
part /var/log --fstype ext3 --size 4095 --ondisk sda
part /tmp --fstype ext3 --size 1020 --ondisk sda
part None --fstype vmfs3 --size 126590 --ondisk sda
part None --fstype vmkcore --size 110 --ondisk sda
After installation i checked the size with the Infrastructure Client and saw that the partition size is not the same as in the script. As example the partition size of the VMware Diagnostic is 101.98 MB and should be 110 MB. I thought that the size parameter is in MB? The same is for all the other partitions (see attachment).
Any idea?
ron999
Es algo normal que estemos muy interesado en saber los pormenores fiscales de nuestros ingresos, hoy gracias a la calculadora de sueldo bruto, podremos a partir de la cantidad que recibimos por nuestra nómina cada mes, saber otros datos como la cantidad de retenciones tanto en conceptos de IRPF, de Seguridad Social y como no el sueldo bruto anual.
Esta calculadora puede ayudarnos de forma muy clara para ser capaces de tener nuestros gastos un poco más ajustados, si es que estamos sufriendo un poco con esta crisis. Por ejemplo si vamos a intentar cambiarnos de trabajo a otro mejor y nos ofrecen 1.600 euros mensuales, sabiendo nuestro sueldo bruto actual, podremos gracias a esta calculadora hallar el nuevo y así compararlos de forma real.
No es muy complicado, simplemente debemos rellenar los datos más sencillos respecto a nuestra persona y nuestra realidad jurídico laboral que es la que nos ayudará a conocer cual es el tratamiento fiscal que se le da a nuestro sueldo bruto.
Para usar esta calculadora primeros debemos rellenar nuestro estado civil, la cuantía que recibimos cada mes en nuestra entidad bancaria en concepto de nómina, así como el número de pagas con las que contamos según nuestro convenio colectivo o contrato laboral sin olvidar si estamos llevando a cabo algún tipo de reducción por vivienda habitual.
En segundo lugar y para calcular el nivel de retenciones de la Seguridad Social debemos marcar nuestra categoría profesional. En muchas ocasiones debemos estar atentos a esto, ya que no siempre se corresponde la que tenemos realmente y la que tenemos suscrita en al seguridad social cuando nuestra empresa nos ha dado de alta.
A continuación rellenaremos unos pequeños datos personales que son los que nos ayudan a conseguir reducciones en las bases de las retenciones que afectan a nuestro sueldo bruto. Los datos que debemos rellenar son: fecha de nacimiento, si tenemos descendientes y su edad, así como si tenemos ascendientes y su edad. Estos últimos datos son los más importantes si queremos pagar lo menos posible y podemos hacerlo gracias a contar con algún hijo menor de 25 años o un ascendiente mayor de 65.
Los resultados son inmediatos y podemos gracias a ellos saber:
Si contamos con pagas extras, cual será el importe de las mismas.
Cuánto nos han retenido en cuanto a IRPF de forma anual
Cuánto nos ha retenido la Seguridad Social.
Por último, cuales son las cifras de nuestra retribución neta y brutal anual.
En definitiva una forma muy sencilla de calcular cuanto ha de ser nuestro sueldo mensual para que no sólo nos salgan las cuentas de nuestra economía familiar sino para que además podamos hallar nuestro bruto anual para poder pedir un aumento a dicha cifra o quizá buscar otro tipo de opciones laborales que no ayuden a llegar a ella.
Más Información | Calculadora sueldo bruto
En Actibva | Calcula tu sueldo neto
Miguel Lopez, editor de Pymes y Autónomos y El Blog Salmón
El titulo de este truco puede sonar "wow" pero simplemente les diré que se trata de un curioso y engañoso truco que juega con nuestros más obvios sentidos?
A veces nuestra vista nos puede hacer una mala jugada al momento de percibir algunas cosas como por ejemplo: "Una botella de vidrio".
quien no conoce una botella de vidrio????
Este tipo se quiso aprovechar del conocimiento que tenemos todos acerca de una clásica y normal botella tratando de manipular nuestros sentidos. No es una novedad cuando los magos o ilusionistas tratan de jugar con las percepciones que tiene la gente sobre las cosas.. Pues hace tiempo también mencione el truco de como hacer levitar una moneda hecha por Criss Angel, muy obvio pero efectivo? Yo lo hice y me resulto?
Les dejo el vídeo después del salto..
El vídeo: Miren el 1:18?
Un gran vídeo, pero no me sorprende?
Como Lo hizo? Pues la verdad del asunto es que la botella siempre fue plana cuando la coloca en la bolsa de papel, lo que me pregunto es: De donde diablos saco una botella así???
Etiquetas de Technorati: bar tricks,trucos con botellas,trucos de bares,magia gratisHow much of a tax cut could you get for $97 billion in federal fiscal stimulus spending? Alex Robson does the sums. Of course, from a Ricardian standpoint, a temporary and unfunded tax cut should be no more effective in stimulating activity than a temporary and unfunded increase in government spending. However, it does have the advantage that whatever spending does occur out of the tax cut is on things people actually want, rather than projects the government thinks we need, while the private sector also gets to allocate any increase in saving.
basehttp://www.institutional-economics.com/index.php/section/rss_2.0/I read a suggestion on a blog that Win32 timer queues should be used instead of timeSetEvent(), so I decided to investigate.
First, a review of what timer queues do. A timer queue is used when you have a bunch of events that need to run at various times. What the timer queue does is maintain a sorted list of timers and repeatedly handles the timer with the nearest deadline. Not only is this more efficient when you have a bunch of timers because you don't have a bunch of pieces of code all maintaining their own timing, but it's also a powerful technique because it can allow you to multiplex a limited timing resource. It's especially good when you have a bunch of low-priority, long-duration timers like UI timers, where you don't want to spend a lot of system resources and precise timing is not necessary.
The classic timer queue API in Windows is SetTimer(). This is mainly intended for UI purposes, and as a result it's both cheap and imprecise. If you're trying to do multimedia timing, SetTimer() is not what you want. It's also a bit annoying to use because you need a message loop and there's no way to pass a (void *) cookie to the callback routine (a common infraction which makes C++ programmers see red). The newer timer API, however, is CreateTimerQueue(). This allows you to create your own timer queue without having to tie it to a message loop, and looks like it would be a good replacement for timeSetEvent().
Unfortunately, if you're in a high-performance timing scenario like multimedia, Win32 timer queues suck.
The first problem is the interface. CreateTimerQueueTimer() takes a parameter called DueTime, which specifies the delay until the timer fires for the first time. Delay relative to what? Well, when you call the CreateTimerQueueTimer() function. Or rather, some undetermined time between when you call the function and it returns. The problem with an interface like this is that you have no idea if something sneaks in between and stalls your thread for a while, like another thread or a page fault. Therefore, you get a random amount of jitter in your start time. Another problem is that if you are creating a repeating timer, you can only set the period in milliseconds. That's not precise enough for a lot of applications. If you're trying to lock to a beam position on a 60Hz display, for instance, this forces you to take a third of a second error per frame, or a 2% error.
That's not the worst part, though. Let's say we just want a regular 100ms beat. That shouldn't be hard for a modern CPU to do. Well, here are the results:
0 0 109 109 219 110 328 109 437 109 547 110 656 109 766 110 875 109The first number is the time offset in milliseconds, measured by timeGetTime(), which has approx. 1ms accuracy and precision. The second number is the delta from the last timer event. Notice a problem? The period is consistently longer than requested. In this case, we're 10% slower than intended. If you request a lower period, it gets much worse. Here's the results for a 47ms periodic timer:
0 0 63 63 125 62 188 63 250 62 313 63 375 62 438 63 500 62 563 63The average period is about 63ms, which is about 30% off from our requested period. That's terrible!
There's another factor, by the way: the timer queue API shares the same characteristic as many timing APIs in Windows of being dependent upon the resolution of the system timer interrupt and is thus also affected by timeBeginPeriod(). The reason I know is that the first time I tried this, I got results that still weren't great, but were a lot better than what you see above. The 47ms timer, for instance, turned in deltas of 48-49ms. Then I realized that I was playing a song in WinAmp in the background, and had to redo the test again.
After being somewhat depressed at the mediocre performance of the timer queue API, I remembered the CreateWaitableTimer() API. This is a different API where you create a timer object directly instead of part of a timer queue, and it also runs the timer in your thread instead of a thread pool thread, which is much easier to deal with if you're trying to time work that requires APIs that must be called on a specific thread, particularly most DirectX APIs. As it turns out, the waitable timer API doesn't fare any better than the timer queue API for periodic timers, as it still takes the period in milliseconds and still has the same problems of significant, consistent error in period and sensitivity to the timer interrupt rate. However, the good side is that you specify the initial delay in 100ns units instead of milliseconds, and more importantly, you can specify an absolute deadline. This is very advantageous, because it means that you can compute timer deadlines internally in high precision off of a consistent time base, and although each individual timer may be imprecise, you can precisely control the average period.
Caveat: I've only tried this in Windows XP, so I don't know if the situation has improved in Windows Vista or Windows 7.
In current versions of VirtualDub, I don't use any of these methods for frame timing in preview mode. Instead, I have my own timer queue thread that uses timeGetTime() coupled with a Sleep() loop, with precision boosted by timeBeginPeriod() and with thread priority raised. You might think this is a bit barbaric, and it is, but it was the best way I could think of to get a reliable, precise timer on all versions of Windows. The trick to making this work is putting in feedback and adjusting the delay passed to Sleep() so that you don't accumulate error. As a result, I can do what I couldn't do with timeSetEvent(), which is to have a timer that has an average period of 33.367 ms. I suppose I could rewrite it on top of the waitable timer API, but it didn't seem worth the effort.
Update:
Here is the test program output from Windows 7 RC for a 50ms timer:
0 0 47 47 94 47 140 46 203 63 250 47 296 46 343 47 390 47 452 62 499 47 546 47 593 47 640 47 702 62 749 47 796 47 842 46 889 47 952 63It seems that Windows 7 does use a method that prevents accumulated error, thus giving an accurate period on average at the cost of consistency.
More interesting is when you give it a very short period, one that is shorter than that of the timing source:
0 0 16 16 16 0 16 0 31 15 31 0 31 0 47 16 47 0 47 0 63 16 63 0 63 0 78 15 78 0 78 0 94 16 94 0 94 0In this case, the timer fires multiple times back to back.
basehttp://virtualdub.org/blog/pivot/entry.php?id=272Hi Cluster Fans,
Resources can be hard to find, so every few months we will be publishing an updated list of useful documents, guides and information to this blog (http://blogs.msdn.com/clustering/).
If there is any other useful Microsoft content which you feel is missing, let us know by clicking the 'email' link in the upper right corner of the page and send us the resource and URL.
Thanks,
Symon Perriman
Program Manager
Clustering & HA
Microsoft
Useful Sources
· Blog: Cluster Team: http://blogs.msdn.com/clustering/
· Blog: Ask Core: Clustering
· Training: Course 6423a: Implementing and Managing WS08 Clustering
· Website: Cluster Technical Resources
· Website: Cluster Information Portal
· Website: Clustering Forum (2008)
· Website: Clustering Forum (2008 R2)
· Website: Clustering Newsgroup
Windows Server 2008 R2
· Blog Guide: Deploying Cluster Shared Volumes (CSV)
· Blog Guide: Cluster Shared Volumes (CSV): Disk Ownership
· Blog Guide: PowerShell for Network Load Balancing (NLB) in Windows Server 2008 R2
· Blog Guide: PowerShell for Failover Clustering in Windows Server 2008 R2
· Blog Guide: Live Migration Traffic
· Blog Guide: How to manually defrag or ChkDisk a CSV disk
· TechNet Guide: Using Live Migration in Windows Server 2008 R2
· TechNet Guide: What??s new in R2 Clustering
· Webcast: Innovating High Availability with Cluster Shared Volumes (CSV)
· Webcast: Failover Clustering Feature Roadmap in WS08 R2
· Whitepaper: Windows Server 2008 R2 & Microsoft Hyper-V Server 2008 R2 - Hyper-V Live Migration Overview & Architecture
· Webcast: Windows Server 2008 R2 Live Migration
· Webcast: Clustering in a Virtual World
· Website: Clustering Forum (2008 R2)
Architecture
· Blog Guide: Cluster Virtual Adapter (NetFT)
· Blog Guide: PlumbAllCrossSubnetRoutes
· Whitepaper: Failover Cluster Architecture Overview
Core
· Guide: Server Core
· TechNet: Installation
· Utility: Remote Server Administration Tools (simplifies Server Core configurations)
· Webcast: How Microsoft does IT: Enhancing High Availability with Server Core in Windows Server 2008
Deployment / Migration / Upgrade
· Blog Guide: Migration Options for Hardware
· Blog Guide: PrintBRM Error 0x80070043 workaround
· Blog Guide: DHCP Database migration to Windows Server 2008
· Blog Guide: PrintBRM.exe, 0?80070043 and Print Clusters - A Workaround
· KB Guide: Exchange 2003: Move Mailbox
· KB Article: SQL Server 2008 Rolling Upgrades
· KB Article: Cluster Nodes as Domain Controllers (DCs)
· MSDN Guide: SQL Upgrade Paths
· MSDN Guide: SQL Cluster Upgrade
· TechNet Guide: Migrating Cluster Settings
· TechNet Guide: Failover Clustering Deployment
· TechNet Guide: Validating Hardware for a Failover Cluster
· TechNet Guide: Installing a Failover Cluster
· TechNet Guide: Creating a Failover Cluster
· TechNet Guide: Cluster Requirements
· TechNet Guide: Validating a cluster
o Blog Guide: Validation Warning: Teredo
o Blog Guide: Validation Warning: Patch GUID
· TechNet Guide: Configuring Accounts in Active Directory
· TechNet Guide: Recommended Clustering Hotfixes (2003)
· TechNet Guide: Recommended Clustering Hotfixes (2003 SP2)
· TechNet Guide: Recommended Clustering Hotfixes (2008)
· TechNet Guide: Exchange 2007 Overview
· TechNet Guide: Exchange 2007 Cmdlets
· TechNet Guide: Print Migration Overview
· TechNet Guide: UI: Print Migration Tool/Wizard
· Utility: File Server Migration Toolkit (FSMT) (2008)
Exchange Server
· Lab: TechNet Virtual Lab: Exchange Server 2007 Standby Continuous Replication
· Lab: TechNet Virtual Lab: Using Cluster Continuous Replication (CCR) in Exchange 2007
· TechNet: Installing Cluster Continuous Replication (CCR) on 2008
· TechNet: Deploying Exchange 2003 in a Cluster
· TechNet: Planning for Cluster Continuous Replication (CCR)
· TechNet: Installing CCR on Windows Server 2008
· TechNet: How to create an Exchange SCC Failover Cluster with CMD
· Webcast: How Microsoft IT Implemented New Storage Designs for Exchange Server 2007
· Webcast: Exchange 2007 High Availability Deep Dive
File Server
· Blog Guide: File Share ??Scoping?? in Windows Server 2008 Failover Clusters
· Blog Guide: Share Subdirectories in Windows Server 2008
· TechNet Guide: Configuring a Two-Node File Server Failover Cluster
· TechNet Guide: Creating a Clustered File Server checklist
· TechNet Guide: Create a Shared Folder in a Clustered File Server
· WebCast: TechNet Webcast: Prepare Yourself for Windows Server 2008 (Part 5 of 8): New File Server Features
· WebCast: How Microsoft IT Deploys Windows 2008 Clusters for File Services
· Webcast: New File Server Features of Windows Server 2008 (Level 200)
· Blog Guide: Deploying a HA Virtual Machine (2008)
· Blog Guide: HA Virtual Machine Deployment Considerations (2008)
· Blog Guide: Network Load Balancing (NLB) and Virtual Machines
· Blog Guide: Adding a Pass-Through Disk to a HA VM
· Blog Guide: SCVMM: Intelligent Placement
· Blog Guide: Monitor Network Traffic for a VM on a Cluster
· TechNet Case Study: How Microsoft IT Designs the Virtualization Host & Network Infrastructure
· TechNet Case Study: Best Practices for Deploying VMs using Hyper-V
· TechNet Guide: Getting Started with Hyper-V
· TechNet Guide: High-Availability for a Server Running Hyper-V
· TechNet Guide: Design for a Failover Cluster in Which All Nodes Run Hyper-V
· TechNet Guide: Requirements and Recommendations for Failover Clusters in Which All Nodes Run Hyper-V
· TechNet Guide: Failover Cluster in which the Servers run Hyper-V
· TechNet Webcast: 24 Hours of Windows Server 2008 (Part 24 of 24): High Availability with Hyper-V
· TechNet Webcast: Creating Business Continuity Solutions Using Windows Virtualization
· TechNet Webcast: High Availability with Hyper-V
· Webcast: Top 10 VMWare Myths, including CSV and live migration
· Webcast: Hyper-V Quick Migration on a Failover Cluster
· Whitepaper: Quick Migration with Hyper-V
· Whitepaper: Testing Hyper-V and Failover Clustering
Miscellaneous Resources
· Blog Guide: Add a New Disk to a Cluster (2008)
· Blog Guide: Configuring Auditing for a Cluster (2008)
· Blog Guide: Cluster Recovery (2003)
· KB Article: The Microsoft Support Policy for Windows Server 2008 Failover Clusters
· TechNet Guide: Configuring the Quorum in a Failover Cluster
· TechNet Guide: Managing a Failover Cluster
· TechNet Guide: Modifying Settings for a Failover Cluster
· TechNet Guide: The Failover Cluster Management Snap-In
· TechNet Guide: Understanding Backup and Recovery Basics for a Failover Cluster
· TechNet Guide: Support Policy
· TechNet Guide: Windows Server 2008 Itanium / IA64 support
· Webcast: Top 10 Windows Server 2008 Failover Clustering Enhancements over Windows Server 2003 Clustering, Based on Best Practices (Level 300)
· Webcast: Failover Clustering 101
· Webcast: Achieving High Availability with Windows Server ??Longhorn? Clustering (Level 200)
· Whitepaper: Microsoft??s HA Strategy
· Whitepaper: Overview of Failover Clustering
· Whitepaper: HA with Microsoft MPIO (2003, 2008)
· Website: Windows Logo site
· Webcast: Introduction to Failover Clustering
Multi-Site Clustering· Cluster Team Site: http://www.microsoft.com/windowsserver2008/en/us/failover-clustering-multisite.aspx
· KB Article: Deployment Considerations for Windows Server 2008 failover cluster nodes on different, routed subnets
· Webcast: TechNet Webcast: Geographically Dispersed Failover Clustering in Windows Server 2008 Enterprise
· Webcast: How You Can Achieve Greater Availability with Failover Clustering Across Multiple Sites (Level 300)
· Whitepaper: Multi-site Clustering
· Webcast: Multi-Site Clustering in Windows Server 2008
Network Load Balancing
· Blog Guide: Network Load Balancing (NLB) and Virtual Machines
· KB Article: NLB Troubleshooting Overview
· KB Article: Create/manage/destroy NLB clusters via NLB Manager remotely from another server, or from RSAT client (admin pack) on Vista
· Presentation: Server Core: Install the NLB feature
· TechNet Guide: Configuring NLB with Terminal Services
· TechNet Guide: NLB Deployment Guide
· TechNet Guide: Implementing a new NLB Cluster
· TechNet Guide: Verifying the NLB Cluster and Enabling Client Access
· TechNet Guide: Overview of NLB
· TechNet Guide: Creating NLB Clusters
· TechNet Guide: Managing NLB Clusters
· TechNet Guide: Setting NLB Parameters
· TechNet Guide: Controlling Hosts on NLB clusters
· TechNet Guide: Troubleshooting for System Event Messages Related to NLB Cluster
· TechNet Guide: User Interface: NLB Manager
· TechNet Guide: Upgrading a NLB Cluster
· TechNet Guide: Upgrading a Network Load Balancing (NLB) Cluster
· Webcast: 24 Hours of Windows Server 2008 (Part 23 of 24): Failover Clustering and Network Load Balancing z
Other Resources / Workloads
· Blog Guide: Configure Multiple Instances of MSDTC (2008)
· Blog Guide: Installing MSDTC (2003)
· Blog Guide: Optimize Print Cluster (2003)
· Blog Guide: Creating and Configuring a Generic Application Resource
· TechNet Guide: Configuring Generic Resources
· TechNet Guide: Configure a Service or Application for High Availability
Scripting
· Blog Guide: Creating a Cluster using WMI
· Blog Guide: CLI: Cluster Resource Groups
· Blog Guide: CLI: Quorum
· Blog Guide: CLI: Disk Resources
·</fo
[clustering nlb cluster failover wsfc network load balancing windows server 2008 core exchange symon perriman SQL hyper-v file server r2 windows server 2008 r2 deployment multi-site scripting ]
Clustering and High Availability : Microsoft Blog - Microsoft server and infrastructure technology blogs, news and resources
View original post
|Add to del.icio.us| Created 9 months ago
| Share
Muchos son los artilugios que nos han sorprendido en NPC, pero pocos nos han dejado tan boquiabiertos como esta increíble cuerda invisible.
No se qué es más inaudito, si la propia cuerda, o el hecho de que algunos individuos puedan atravesarla como por arte de magia.
Véase también Ahora puedes ser invisible, C-String: Nuevos tangas “ invisibles ”
PART TWO: DNTEL
With that wave of mom and pop record stores closing monthly winding down and completely gutting the support for physical music for people to discover, iPods building closed personal shells running mostly ringtone quality sound thru tiny white earbuds instead of record players playing aloud, and faceless torrents and file sharing sites handing out music like its those frickin’ free Auto Mart gazettes sitting in those bright yellow stands in front of your local closed down Blockbuster’s, i’d like to spend some of the young readers time by sharing how I got into electronic music. For what its worth I want to keep sharing what musicians first turned me from a casual listener to something that involves more time than people are willing to sometimes spend to keep up with something.
This music by Dntel was more emotional than any other electronic music I heard at the time, I feel like it almost paved the way for a ton of new genres to start. I really only listened to it when I worked or was falling asleep but then started sharing it on mixtapes and became a favorite of mine. I needed more and at that time in Detroit there was a flurry of solid record stores filled with enough employees to answer any of your questions happily with great suggestions, can you imagine that? well it was true especially one called Neptune Records which I was happy to drive the 45+ minute drive weekly to see what was new. I’ll prepare a 3rd playlist and share more, hope some of you can relate.
PART: ONE: Caribou
[RSS Readers: See post to listen to audio]
Permalink |
Comment On This Post (15) |
Tweet This Post | Add to
del.icio.us | Stumbleupon
Post tags: Dntel, Electronic Music
Han pasado más de cinco años desde que los Multicines Aguere, una emblemática sala de proyecciones de La Laguna, echaron el cerrojo. Era el último cine de ciudad que permanecía abierto en este municipio.
leer más
REST is a first-class citizen in the Rails world, though most of the hard work is done at the routing level. The controller stack has some niceties revolving around mime type handling with the respond_to facility but, to date, there’s not been a lot built into actionpack to handle the serving of resources. The addition of respond_with (and this follow-up) takes one step towards more robust RESTful support with an easy way to specify how resources are delivered. Here’s how it works:
Basic UsageIn your controller you can specify what resource formats are supported with the class method respond_*to*. Then, within your individual actions, you tell the controller the resource or resources to be delivered using respond_*with*:
| 1 2 3 4 5 6 7 8 9 10 11 12 13 | class UsersController < ApplicationController::Base respond_to :html, :xml, :json def index respond_with(@users = User.all) end def create @user = User.create(params[:user]) respond_with(@user, :location => users_url) end end |
This will match each supported format with an appropriate response. For instance, if the request is for /users.xml then the controller will look for a /users/index.xml.erb view template to render. If such a view template doesn’t exist then it tries to directly render the resource in the :xml format by invoking to_xml (if it exists). Lastly, if respond_with was invoked with a :location option the request will be redirected to that location (as in the case of the create action in the above example).
So here’s the equivalent implementation without the use of respond_with (assuming no index view templates):
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | class UsersController < ApplicationController::Base def index @users = User.all respond_to do |format| format.html format.xml { render :xml => @users } format.json { render :json => @users } end end def create @user = User.create(params[:user]) respond_to do |format| format.html { redirect_to users_url } format.xml { render :xml => @user } format.json { render :json => @user } end end end |
You can see how much boilerplate response handling is now handled for you especially if it’s multiplied over the other default actions. You can pass in :status and :head options to respond_with as well if you need to send these headers back on resources rendered directly (i.e. via to_xml):
| 1 2 3 4 5 6 7 8 | class UsersController < ApplicationController::Base respond_to :html, :xml, :json def index respond_with(@users = User.all, :status => :ok) end end |
It’s also possible to override standard resource handling by passing in a block to respond_with specifying which formats to override for that action:
| 1 2 3 4 5 6 7 8 9 10 11 12 13 | class UsersController < ApplicationController::Base respond_to :html, :xml, :json # Override html format since we want to redirect to a different page, # not just serve back the new resource def create @user = User.create(params[:user]) respond_with(@user) do |format| format.html { redirect_to users_path } end end end |
You can also pass in :except and :only options to only support formats for specific actions (as you do with before_filter):
| 1 2 3 4 5 | class UsersController < ApplicationController::Base respond_to :html, :only => :index respond_to :xml, :json, :except => :show ... end |
If you’re still want to use respond_to within your individual actions this update has also bundled the :any resource format that can be used as a wildcard match against any unspecified formats:
| 1 2 3 4 5 6 7 8 9 10 11 12 | class UsersController < ApplicationController::Base def index @users = User.all respond_to do |format| format.html format.any(:xml, :json) { render request.format.to_sym => @users } end end end |
So all in all this is a small, but meaningful, step towards robust controller-level REST support. I should point out that the contributor of this patch is José Valim who has authored the very robust inherited_resources framework that already has support for respond_with-like functionality and many more goodies. If you’re on the search for a solid RESTful controller framework to accompany Rails’ native RESTful routing support I would suggest you take a look at his fine work.
tags: ruby, rubyonrails
basehttp://ryandaigle.com/REST is a first-class citizen in the Rails world, though most of the hard work is done at the routing level. The controller stack has some niceties revolving around mime type handling with the respond_to facility but, to date, there’s not been a lot built into actionpack to handle the serving of resources. The addition of respond_with (and this follow-up) takes one step towards more robust RESTful support with an easy way to specify how resources are delivered. Here’s how it works:
Basic UsageIn your controller you can specify what resource formats are supported with the class method respond_*to*. Then, within your individual actions, you tell the controller the resource or resources to be delivered using respond_*with*:
| 1 2 3 4 5 6 7 8 9 10 11 12 13 | class UsersController < ApplicationController::Base respond_to :html, :xml, :json def index respond_with(@users = User.all) end def create @user = User.create(params[:user]) respond_with(@user, :location => users_url) end end |
This will match each supported format with an appropriate response. For instance, if the request is for /users.xml then the controller will look for a /users/index.xml.erb view template to render. If such a view template doesn’t exist then it tries to directly render the resource in the :xml format by invoking to_xml (if it exists). Lastly, if respond_with was invoked with a :location option the request will be redirected to that location (as in the case of the create action in the above example).
So here’s the equivalent implementation without the use of respond_with (assuming no index view templates):
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | class UsersController < ApplicationController::Base def index @users = User.all respond_to do |format| format.html format.xml { render :xml => @users } format.json { render :json => @users } end end def create @user = User.create(params[:user]) respond_to do |format| format.html { redirect_to users_url } format.xml { render :xml => @user } format.json { render :json => @user } end end end |
You can see how much boilerplate response handling is now handled for you especially if it’s multiplied over the other default actions. You can pass in :status and :head options to respond_with as well if you need to send these headers back on resources rendered directly (i.e. via to_xml):
| 1 2 3 4 5 6 7 8 | class UsersController < ApplicationController::Base respond_to :html, :xml, :json def index respond_with(@users = User.all, :status => :ok) end end |
It’s also possible to override standard resource handling by passing in a block to respond_with specifying which formats to override for that action:
| 1 2 3 4 5 6 7 8 9 10 11 12 13 | class UsersController < ApplicationController::Base respond_to :html, :xml, :json # Override html format since we want to redirect to a different page, # not just serve back the new resource def create @user = User.create(params[:user]) respond_with(@user) do |format| format.html { redirect_to users_path } end end end |
You can also pass in :except and :only options to only support formats for specific actions (as you do with before_filter):
| 1 2 3 4 5 | class UsersController < ApplicationController::Base respond_to :html, :only => :index respond_to :xml, :json, :except => :show ... end |
If you’re still want to use respond_to within your individual actions this update has also bundled the :any resource format that can be used as a wildcard match against any unspecified formats:
| 1 2 3 4 5 6 7 8 9 10 11 12 | class UsersController < ApplicationController::Base def index @users = User.all respond_to do |format| format.html format.any(:xml, :json) { render request.format.to_sym => @users } end end end |
So all in all this is a small, but meaningful, step towards robust controller-level REST support. I should point out that the contributor of this patch is José Valim who has authored the very robust inherited_resources framework that already has support for respond_with-like functionality and many more goodies. If you’re on the search for a solid RESTful controller framework to accompany Rails’ native RESTful routing support I would suggest you take a look at his fine work.
tags: ruby, rubyonrails
basehttp://ryandaigle.com/
THX!
Hace poco, me jalaba los cabellos buscando instalar un Chat en BlogHogwarts. Traté de todo tipo de chats, Meebo, IRC, Pjirc, y me estaba volviendo loco, hasta que encontré BoWoB.
Algunas de sus novedades son, primero, su fácil instalación, simplemente nos registramos en BoWoB, creamos nuestra sala de chat y descargamos el plugin para WordPress, el cual una vez instalado, nuestros visitantes podrán empezar a entrar el chat. Pueden ver un ejemplo directamente en el chat de BlogHogwarts.
El chat es flash. Podemos enviar mensajes directamente en el chat general o privados a otros usuarios. Tenemos un panel los administradores, para kickear o banear a usuarios que se comporten mal. El Chat no consume recursos de nuestro servidor. Y por supuesto, es creado por un programador hispano llamado Jonatan Linares, quien además, brinda soporte en caso de que el chat no te haya funcionado.
Espero que les sea útil, ya que a mí me ha resultado bastante útil
Regístrate en BoWoB y descarga el plugin.
ESXi:
VMware ESXi 4.0.0 build-164009
VCB:
VMware Consolidated Backup -- Virtual Machine Mount Utility
Version 1.5.0.4948 (build-150805)
on VMFS 3.33
in the Server 2008, there is no AV installed just clean reinstall, even before I setup SQL Server 2008, the VM is failed to back up as well :-|
Kind Regards,
AWT